-
Notifications
You must be signed in to change notification settings - Fork 9
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
Add a config file to enable/disable various features #511
Comments
What's wrong with using the existing config file? |
local.js? That also works. I suppose it would be good if there was default config file that was part of the repo, and specific options could optionally be overridden in local.js. |
There actually is. The local.example.js is actually included On Tue, 12 Jan 2016, 07:33 not-an-aardvark [email protected] wrote:
|
Right, but I mean a separate default that actually gets used. So we would have the default config in a separate file, as: module.exports = {
option1: true,
option2: true,
option3: true
}; Then in local.js, one could override the default parameters like this: module.exports = {
/* ... (password stuff, etc.) ... */
config: {
option2: false // Override the default value of option2, but use the default values for option1 and option3
}
}; |
The local.example.js actually does get used. On Tue, 12 Jan 2016, 07:45 not-an-aardvark [email protected] wrote:
|
Oh, so it does. Never mind, then. |
This should make it easier to toggle optional features, and to change specific rules (e.g. whether or not to archive modmails, whether to count a specific trade type for flair, etc.), or without having to change a bunch of code. The config file should be on gitignore, with a second "default" config file included in the repo.
This will require cleaning up the code to make features easily toggleable, which is probably a good idea anyway.
The text was updated successfully, but these errors were encountered: