diff --git a/bin/probot-run.js b/bin/probot-run.js index 0da4ed1b..c4f17613 100755 --- a/bin/probot-run.js +++ b/bin/probot-run.js @@ -9,12 +9,12 @@ const {findPrivateKey} = require('../lib/private-key') program .usage('[options] ') + .option('-p, --port ', 'Port to start the server on', process.env.PORT || 3000) + .option('-t, --tunnel ', 'Expose your local bot to the internet', process.env.SUBDOMAIN || process.env.NODE_ENV !== 'production') + .option('-w, --webhook-path ', 'URL path which receives webhooks. Ex: `/webhook`', process.env.WEBHOOK_PATH) .option('-a, --app ', 'ID of the GitHub App', process.env.APP_ID) .option('-s, --secret ', 'Webhook secret of the GitHub App', process.env.WEBHOOK_SECRET) - .option('-p, --port ', 'Port to start the server on', process.env.PORT || 3000) .option('-P, --private-key ', 'Path to certificate of the GitHub App', findPrivateKey) - .option('-w, --webhook-path ', 'URL path which receives webhooks. Ex: `/webhook`', process.env.WEBHOOK_PATH) - .option('-t, --tunnel ', 'Expose your local bot to the internet', process.env.SUBDOMAIN || process.env.NODE_ENV !== 'production') .parse(process.argv) if (!program.app) { diff --git a/lib/robot.js b/lib/robot.js index 50e36be4..d29c4388 100644 --- a/lib/robot.js +++ b/lib/robot.js @@ -177,21 +177,21 @@ function rateLimitedClient (github) { module.exports = (...args) => new Robot(...args) /** -* Do the thing -* @callback Robot~webhookCallback -* @param {Context} context - the context of the event that was triggered, -* including `context.payload`, and helpers for extracting information from -* the payload, which can be passed to GitHub API calls. -* -* ```js -* module.exports = robot => { -* robot.on('push', context => { -* // Code was pushed to the repo, what should we do with it? -* robot.log(context); -* }); -* }; -* ``` -*/ + * Do the thing + * @callback Robot~webhookCallback + * @param {Context} context - the context of the event that was triggered, + * including `context.payload`, and helpers for extracting information from + * the payload, which can be passed to GitHub API calls. + * + * ```js + * module.exports = robot => { + * robot.on('push', context => { + * // Code was pushed to the repo, what should we do with it? + * robot.log(context); + * }); + * }; + * ``` + */ /** * A [GitHub webhook event](https://developer.github.com/webhooks/#events) payload