Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ヘルプコマンドを用意する #18

Open
katorie opened this issue Dec 25, 2017 · 2 comments
Open

ヘルプコマンドを用意する #18

katorie opened this issue Dec 25, 2017 · 2 comments

Comments

@katorie
Copy link
Member

katorie commented Dec 25, 2017

No description provided.

@risacan
Copy link
Member

risacan commented Dec 26, 2017

https://github.com/ikejirirb/ruboty-ehon/blob/master/lib/ruboty/handlers/ehon.rb#L6
短い内容なら、Rubotyのdescriptionに書いてもいいかも!
そうすると、ruboty helpってした時に、正規表現とdescriptionが出る👍

https://ikejirirb.slack.com/archives/C7MBBPP9B/p1508998350000151

@risacan
Copy link
Member

risacan commented Dec 26, 2017

こんな感じに!

konure /(?<body>.+)/ - Talk with you if given message didn't match any other handlers
konure /(harahe|はらへ|ハラへ|ハラヘ|ハラヘ)/ - Gives you some snacks
konure /お腹(?<status>.+)/ - Gives you some snacks
konure /ahoj/i - チェコ語の挨拶をする
konure /hello/i - Return Hello in French
konure /help( me)?(?: (?<filter>.+))?\z/i - Show this help message
konure /ping\z/i - Return PONG to PING
konure /who am i\?/i - Answer who you are

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants