hubot-config

1.0.1 • Public • Published

hubot-config

A configuration management library for Hubot

Installation

$ npm install --save hubot-config

Usage

parseConfig = require 'hubot-config'
 
config = parseConfig 'hello',       # 'hello' is script name ( hubot-hello ) 
  message: 'world'                  # process.env.HUBOT_HELLO_MESSAGE ? 'world' 
  friendlyMessage: null             # process.env.HUBOT_HELLO_FRIENDLY_MESSAGE ? null 
 
module.exports = (robot) ->
  robot.respond /hello/(msg) ->
    msg.send config.message
 
  robot.respond /hi/(msg) ->
    msg.send config.friendlyMessage

License

MIT

Author

bouzuya <m@bouzuya.net> (http://bouzuya.net)

Badges

Build Status Dependencies status Coverage Status

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 1.0.1
    0
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 1.0.1
    0
  • 1.0.0
    0

Package Sidebar

Install

npm i hubot-config

Weekly Downloads

0

Version

1.0.1

License

MIT

Last publish

Collaborators

  • bouzuya