Create initial config automatically
Automatically create a config and refer users to the readme for further instructions.
This commit is contained in:
parent
4630cefd47
commit
6371d43358
2 changed files with 23 additions and 0 deletions
18
util/createInitialConfig.js
Normal file
18
util/createInitialConfig.js
Normal file
|
@ -0,0 +1,18 @@
|
|||
module.exports = function () {
|
||||
let fs = require('fs')
|
||||
let config = {
|
||||
"globalPrefix": "+",
|
||||
"token": "",
|
||||
"enableLoginMessage": false,
|
||||
"loginChannel" : "",
|
||||
"loginMessage" : "Bot is online!",
|
||||
"owners": [],
|
||||
"allowNetload" : false
|
||||
}
|
||||
fs.mkdirSync("./data");
|
||||
|
||||
fs.writeFileSync('./data/config.json', JSON.stringify(config, null, 4))
|
||||
|
||||
console.log("Enter the token as described in the README.md file");
|
||||
process.exit();
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue