A Hubot script that spawns new Hubot scripts on the fly. Yo dawg.
npm install hubot-newbotA Hubot script that spawns new Hubot scripts on the fly. Yo dawg.
- Add hubot-newbot to your Hubot's package.json
- Add hubot-newbot to your Hubot's external-scripts.json
- Run npm install
````
hubot newbot FooBot /foo/i (msg) -> msg.send "bar" # Creates a NewBot named FooBot that responds "bar" to the command "hubot foo".
hubot listenbot FooBot /foo/i (msg) -> msg.send "bar" # Creates a NewBot named FooBot that sends "bar" whenever a message includes "foo".
hubot killbot FooBot # Deletes FooBot by name.
hubot list newbots # Lists names of running newbots.
hubot showbot FooBot # Shows the regex and CoffeeScript body of FooBot.
hubot showbot FooBot --debug # Debug mode: Shows the regex and compiled JavaScript for FooBot.
- GitHub project: https://github.com/JustinMorgan/hubot-newbot
- Author: Justin Morgan (https://github.com/JustinMorgan)
- License: NewBot is licensed under the [MIT][mit] license.
[mit]: http://opensource.org/licenses/mit-license.php