flood icon indicating copy to clipboard operation
flood copied to clipboard

Read values from config.template.js as a fallback for config.js

Open jfurrow opened this issue 8 years ago • 4 comments

Let's just always merge these files (preferring values in config.js of course) so nobody has to worry about copying anything over to config.js.

jfurrow avatar Aug 04 '17 05:08 jfurrow

I don't understand what do you mean @jfurrow? Is it still up to date?

noraj avatar May 20 '18 13:05 noraj

So let's say a new configuration option is added to config.template.js, but users don't notice when they update, so they don't copy this option to their customized config.js. If Flood were to treat any value in config.template.js as a default, users wouldn't need to copy any new configuration options, and Flood would continue working as expected.

It's a really simple change, I just don't want to forget about it.

jfurrow avatar May 20 '18 22:05 jfurrow

Ah sure, great idea. First I thought you were suggesting to remove the template file and just use config.js .

noraj avatar May 21 '18 17:05 noraj

You mean:

  • Read values in config.js
  • if the value don't exist in config.js so read it in config.template.js as a fallback

noraj avatar Sep 03 '19 00:09 noraj