Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- {
- "name": "npm",
- "permissions": "NONE",
- "restriction": "4",
- "_id": "UwRCF",
- "actions": [
- {
- "info": "0",
- "infoIndex": "1",
- "storage": "1",
- "varName": "moduleName",
- "name": "Store Command Params"
- },
- {
- "channel": "0",
- "varName": "",
- "message": "Attempting to install node module: ${tempVars(\"moduleName\")}",
- "storage": "0",
- "varName2": "",
- "name": "Send Message"
- },
- {
- "behavior": "1",
- "interpretation": "0",
- "code": "\nvar moduleName = tempVars(\"moduleName\");\n\ntry{ \nrequire.resolve(moduleName)\nmsg.channel.send(\"Module '\"+ moduleName + \"' is already installed!\"); \n\n}catch(err){\nmsg.channel.send(\"Installing/Updating node module '\"+ moduleName + \"'\"); \n\nvar theModule = this.getWrexMods().require(moduleName);\n\nif(theModule){\n msg.channel.send(\"\"+ moduleName + \" was installed to the bot!\"); \n}else{\n msg.channel.send(\"Error! Module NOT \"+ moduleName + \" installed to the bot!\"); \n}\n\n}\n\n\n\n \n",
- "storage": "0",
- "varName": "",
- "name": "Run Script"
- },
- {
- "channel": "0",
- "varName": "",
- "message": "**NPM_INSTALL**: ${tempVars(\"installMessage\")}",
- "storage": "0",
- "varName2": "",
- "name": "Send Message"
- }
- ],
- "comType": "0",
- "_aliases": []
- }
Add Comment
Please, Sign In to add comment