ndb icon indicating copy to clipboard operation
ndb copied to clipboard

Folder exclude option or respect .gitignore

Open duzun opened this issue 6 years ago • 2 comments

Steps to reproduce

Tell us about your environment:

  • ndb version: v1.0.44
  • Platform / OS version: Linux 5.1.1-2-MANJARO x86_64
  • Node.js version: v11.15.0

What steps will reproduce the problem?

Please include code that reproduces the issue.

  1. In dev, I have mongodb with db folder in ./data/db (and some other data stuff in ./data/ folder).
  2. In ./files/ I have some hundreds of thousands of files, trying to be as close to production as possible.

What is the expected result?

When mongodb is running, ./data/db folder is not accessible, and ndb throws an error:

Error: EACCES: permission denied, scandir '{root}/data/db/admin'
    at Object.readdirSync (fs.js:806:3)
    at FileSystemHandler.filePaths (~/.npm-global/lib/node_modules/ndb/services/file_system.js:62:26)

And because of ./files/ folder, ndb is very slow (see #229).

What happens instead?

ndb should ignore both ./data/ and ./files/ folders, because there is no code in those folders, and they both are ignored in .gitignore. Or at least it would be nice to have an option to specify which folders to be ignored.

duzun avatar May 26 '19 10:05 duzun

You can go to Settings > Workspace and edit Folder exclude pattern to add any folders that should be ignored. image

alexkozy avatar Jun 20 '19 05:06 alexkozy

Thanks @ak239 I didn’t know about workspaces... Still, would be nice if ndb respects .gitignore, that would be one thing less to worry about.

duzun avatar Jun 21 '19 04:06 duzun