standard/deglob

Enable useage without package.json present

j-medland opened this issue · 3 comments

The current method of determining the 'root' directory means that if you don't have a package.json file somewhere sensible then the gitignoreFile option is not respected.

Depending on your preference either:

  1. the root could be explicitly specified in the options
  2. If no package.json is found then cwd would be taken as root and the gitIgnoreFile value (user specified or a default like /.gitignore) could be used

I would be happy to provide a PR for either option.

Cheers

Flet commented

Hmm. I think number 1 makes sense.

nuest commented

We have done something similar, but I think with number 3: add flag to disable the search for the root file, use cwd then, see master...o2r-project:master

Happy to add some tests and a PR if you would welcome this.

We're not using this package in standard anymore, so this issue won't be fixed.