markis/watchman-processor

Feature Request: option to search current working directory for watchman config file

Closed this issue · 5 comments

Would be great to either search for the config file in the current working directory or to be explicitly specify the path to the watchman config to use ...

Here is what I am thinking, let me know if this works for you:

1.) If no parameters are supplied, load ~/.watchman-processor.config.js (exactly what it does now)
2.) If -c is provided without a file name immediately following, then load /.watchman-processor.config.js from current working directory (similar to how rollup works)
3.) If -c <filename> is provided then load the specified file.

That sounds like the perfect behavior to me!

(Whoops -- editing on phone -- did not mean to close). And just to call out -- I'm assuming you meant in above that -c without argument will load ./.watchman-processor.config.js

Yes, correct. ./.watchman-processor.config.js. The watchman-processor.config.js file from the current working directory

I published v2.2.0-alpha.0 with these proposed changes. You can run npm install watchman-processor@2.2.0-alpha.0 -g and try it out.

Let me know if it works.