lucified/github-deploy-notify

Name: github-deploy-notify

Owner: Lucify

Description: Simple utility for sending a notification of a deployment to GitHub Deployment API.

Created: 2016-06-16 11:18:07.0

Updated: 2016-07-20 10:29:28.0

Pushed: 2016-06-16 13:34:00.0

Homepage:

Size: 10

Language: JavaScript

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

Send notification to GitHub deployment API

Simple utility for sending a notification to GitHub deployment API of a deployment.

Install
install github-deploy-notify -g
Example usage
Usage via command line

Create file github-deploy-notify.config.js

le.exports = {
thubToken: 'df89s7af89ds0a7daa',
oject: 'my-project-name',
g: 'my-org-name',
dy: {
// insert options according to 
// https://developer.github.com/v3/repos/deployments/#create-a-deployment


Then run

ub-deploy-notify --verbose

The tool looks by default for a configuration object from ./github-deploy-notify.config.js. You can also specify an alternative path for the configuration object with the --config option.

Usage via Javascript API
githubDeployNotify = require('github-deploy-notify');
oyNotify({
thubToken: 'df89s7af89ds0a7daa',
oject: 'my-project-name',
g: 'my-org-name',
dy: {
// insert options according to 
// https://developer.github.com/v3/repos/deployments/#create-a-deployment

unction(err) {
if (err) {
  console.log('Failed to send notification to GitHub deployment API');
} else {
  console.log('Notification delivered to GitHub deployment API');
}

Options
Required
Optional
Only available via command line
Test

Make sure you have the right node version

use

As the tests are sending actual notifications to the Flowdock API, you will need have a FLOW_TOKEN environment variable defined for tests to work.

UB_TOKEN=your_test_flow_token npm test

This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.