Skip to content
This repository has been archived by the owner on Sep 20, 2024. It is now read-only.

Add option to disable default startup message #703

Merged

Conversation

JoshuaKlassen
Copy link
Contributor

@JoshuaKlassen JoshuaKlassen commented Mar 12, 2017

This PR is to add the option to disable the Initializing Botkit vXXX message as per #687

To achieve this, CoreBot.js was modified to check for disable_startup_message on the configuration object.
If disable_startup_message=true, the startup message will not be shown.

Example:

var controller = Botkit.slackbot({
    debug: true,
    disable_startup_message: true
});

Upon getting started, I noticed that .vscode files are not in the .gitignore (I am using VSCode)
If this is intentional let me know and I can undo the change.

My VSCode editor generated a settings.json file, I have added that to the .gitignore incase this is something that should be ignored - if not it can be removed.

@jonchurch
Copy link
Contributor

jonchurch commented Mar 12, 2017

I'd suggest changing it from a console.log to a botkit.debug instead of adding a new config option to the growing list.

But having a startup message somewhere is a good idea, with maybe botkit' starter kits starting off in debug mode so you at least see the message on your first run.

@JoshuaKlassen
Copy link
Contributor Author

JoshuaKlassen commented Mar 13, 2017

Sounds good, I'll make the change to a botkit.debug

As for the starter kits, would that be acceptable to make debug enabled by default?

@peterswimm
Copy link
Contributor

Could you explain why setting debug to being on default is preferred behaviour? My gut is that it would be an annoyance for most first time users, and is only really useful for people diagnosing unusual problems.

The initializing message is useful for us, particularly with regards to roadmap plans and supporting problems, and will eventually contain other useful information for developers. but being able to opt-out of receiving them is probably a reasonable request.

@JoshuaKlassen
Copy link
Contributor Author

JoshuaKlassen commented Mar 16, 2017

I just did what @jonchurch suggested
I can switch it back to a config option if that seems most appropriate

@benbrown
Copy link
Contributor

I like @JoshuaKlassen's original idea - allow the message to be disabled independently of debugging. I believe this IS important to be on by default.

@JoshuaKlassen
Copy link
Contributor Author

I reverted back to original idea. I also felt it would be appropriate to make the config option plural, seeing as how we could add more startup messages in the future

@jonchurch
Copy link
Contributor

👍 Sounds good to me.

@peterswimm I agree, that would likely annoy developers. I was suggesting a scenario where the startup is on by default, but dependent on debug mode.

Y'alls solution is cleaner and more predictable though.

@JoshuaKlassen
Copy link
Contributor Author

@peterswimm, @jonchurch, @benbrown: is there anything I am missing, or is this good to go?

@benbrown benbrown merged commit 4b3ff5c into howdyai:master Apr 26, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants