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

Ignore words #31

Open
phillc opened this issue May 8, 2019 · 0 comments
Open

Ignore words #31

phillc opened this issue May 8, 2019 · 0 comments

Comments

@phillc
Copy link

phillc commented May 8, 2019

Hello,

I'd like to contribute a patch that ignores messages that contain a regex. However, I can't figure out how to test this package.

I want to provide a list of regexes like /lol/,/\@/ in I guess an env var like HUBOT_MARKOV_REJECTLIST. I believe I would iterate over them and check them right after the username ignorelist https://github.com/smashwilson/hubot-markov/blob/master/src/default-listeners.coffee#L81.

Let's say I have a local copy of hubot running, perhaps a symlink from the node_modules directory to my local copy of hubot markov? Also with my env var set. Do I just type in some words and see if it catches them or do you have another mechanism?

My primary motivation is to reject messages with # or @ in them, in slack the # references other channels which makes weird sentences, and the @ notifies people, and when markov repeats them it actually notifies them (we've had a couple @channel's).

Thanks

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

1 participant