Skip to content

Commit 0d61264

Browse files
authored
Merge pull request #7 from CPPAlliance/help_syntax
revise help text (and add search everything)
2 parents 72896cc + f4dad6a commit 0d61264

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

index.js

+4-2
Original file line numberDiff line numberDiff line change
@@ -228,6 +228,8 @@ app.message(/.*/, async ({ context, event, say }) => {
228228
text = search({ query: words.slice(2).join(' '), type: "paper" });
229229
} else if (words[1] === 'issues') {
230230
text = search({ query: words.slice(2).join(' '), type: "issue" });
231+
} else if (words[1] === 'everything') {
232+
text = search({ query: words.slice(2).join(' ')});
231233
} else {
232234
text = search({ query: words.slice(1).join(' ') });
233235
}
@@ -243,8 +245,8 @@ app.message(/.*/, async ({ context, event, say }) => {
243245

244246
if (words[0] === 'help') {
245247
await say({
246-
text: 'Usage: "@npaperbot search [papers|issues|everything]: <keywords>"'
247-
+ ' or "@npaperbot {Nxxxx|Pxxxx|PxxxxRx|Dxxxx|DxxxxRx|CWGxxx|EWGxxx|LWGxxx|LEWGxxx|FSxxx}..."',
248+
text: 'Usage: "@npaperbot search [papers|issues|everything] <keywords>"'
249+
+ ' or "@npaperbot {Nxxxx|Pxxxx|PxxxxRx|Dxxxx|DxxxxRx|CWGxxx|EWGxxx|LWGxxx|LEWGxxx|FSxxx}"',
248250
unfurl_links: false,
249251
unfurl_media: false,
250252
thread_ts: event.thread_ts

0 commit comments

Comments
 (0)