An example script package for Hubot
Last updated 6 years ago by spruce .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install hubot-deploy-custom 
SYNC missed versions from official npm registry.


Hubot Script for providing deploy ability with custom scripts

Adds a new command to hubot: Currently only supporting deploying to one target (prod) (name of hubot) deploy <target> <ref to deploy> (name of hubot) deploy <target> makes the default action defined in deploy.conf (name of hubot) deploy defaults to (name of hubot) deploy stage


Save your deploy.conf somewhere outside the node_modules folder


renaming deploy.conf.example -> deploy.conf

Added a new filed to the config where you can put the repo name from gitlab so it knows which config to use to deploy on commit deployhook web-repo-name web-repo-name should be the name of the repositoriy add as a push hook on your repo

HUBOT_DEPLOY_CUSTOM_CHANNEL put this into your environment so hubot knows where to post things to

Workflow for working with this addon

  1. commit all things
  2. (test it)
  3. Increase Version and commit a new tag
  4. push to server git push origin
  5. chat with hubot hubot deploy <target>


Save your deploy.conf to another location than node_modules

##From before 0.0.9 to 0.0.9 or after: Add HUBOT_DEPLOY_CUSTOM_CHANNEL to your environment

Work based on following people

Uses nice deploy script from visionmedia

Matt Pegler for the inspiration

Directory Structure

Using the common directory structure for hubot script packages it will be easy to manage and allow others to easily contribute to your package.


This directory is home to a couple of development scripts; bootstrap and test they're used to bootstrap the development environment and run tests respectively.


This directory is home to the actual hubot scripts in the package. Your entry point will load the scripts from this directory.


This directory is home to any tests you write for your scripts. This example package uses Mocha, Chai and Sinon to manage writing tests.

Advantages of Building a Package

Some of the advantages of building an npm package for your hubot script(s) are:

  • You don't need to rely on when hubot-scripts package is released.
  • You can specify dependencies in the package.json rather than have users manually specify them
  • You can easily add tests using your favourite frameworks and libraries

Current Tags

  • 0.1.0                                ...           latest (6 years ago)

10 Versions

  • 0.1.0                                ...           6 years ago
  • 0.0.9                                ...           6 years ago
  • 0.0.8                                ...           6 years ago
  • 0.0.7                                ...           6 years ago
  • 0.0.6                                ...           6 years ago
  • 0.0.5                                ...           6 years ago
  • 0.0.4                                ...           6 years ago
  • 0.0.3                                ...           6 years ago
  • 0.0.2                                ...           6 years ago
  • 0.0.1                                ...           6 years ago
Maintainers (1)
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 0
Dependencies (2)
Dev Dependencies (4)
Dependents (0)

Copyright 2014 - 2016 © |