据我所知,hubot help
命令应该根据每个脚本开头的注释列出所有命令。由于某些原因,它没有列出我的文件的帮助,任何人都可以发现错误吗?
# Description:
# Hubot interface to octopus deploy
#
# Commands:
# hubot octo promote <project> from <env1> to <env2> - Hubot deploys the latest release of <project> on <env1> to <env2>
# hubot octo deploy <project> version <version> to <env> - Hubot deploys the specified version of <project> to <env>
# hubot octo status - Hubot prints a dashboard of environments and currently deployed versions.
#
# Author:
# kneumei
_ = require('underscore')._
q = require('q')
util = require('util')
....
完整的脚本在这里:https://github.com/mastoj/hubot-octopus/blob/master/src/octopus.coffee
答案 0 :(得分:0)
你有没有得到这个工作?我正在努力解决同样的问题。推送到heroku之后,看起来hubot-octopus模块构建得很好,我将它与其他模块一起包含在external-scripts.json中,但是hubot没有在帮助中列出octo命令并且不响应octo命令。
remote: -----> Build succeeded!
remote: ├── hubot@2.16.0
remote: ├── hubot-diagnostics@0.0.1
remote: ├── hubot-google-images@0.2.2
remote: ├── hubot-google-translate@0.2.0
remote: ├── hubot-help@0.1.2
remote: ├── hubot-heroku-keepalive@1.0.0
remote: ├── hubot-maps@0.0.2
remote: ├── hubot-octopus@0.0.1 <----
remote: ├── hubot-pugme@0.1.0
remote: ├── hubot-redis-brain@0.0.3
remote: ├── hubot-rules@0.1.1
remote: ├── hubot-scripts@2.16.2
remote: ├── hubot-shipit@0.2.0
remote: └── hubot-slack@3.4.1
更新:事实证明我的问题实际上是Octopus API Key的环境变量是错误的。如果没有正确设置它,它只是默默地失败..我使用文档中所述的OCTOPUS_API_KEY,但实际的实现需要OCTOPUS_KEY。向hubot-octopus添加了拉取请求以修复文档。