nokxs/iobroker-javascript-vs-code-extension

Exclude files from the script explorer

Closed this issue · 3 comments

Is your feature request related to a problem? Please describe.
Adding files and folders for development (node_modules, tests, etc.) leads to them showing up in the script explorer as "only local".

Describe the solution you'd like
I'd like to define these files in a .iobrokerignore or similar to ignore them from the explorer view.

nokxs commented

This could be a useful feature. Would you rather like a separte file like proposed (eg. .iobrokerignore) or would it be better to have it in the existing config file, in order to not polute the workspace root folder? If I do this I'd like to use the same patterns as supported in .gitignore.

Workaround for this problem

Have you tried to sync your scripts in a subdirectory like in the example config:

{
  "ioBrokerUrl": "http://iobroker",
  "socketIoPort": 8081,
  "scriptRoot": "/scripts",
  "adminVersion": "admin5"
}

This way the script explorer shows only the content of the script folder. You could have the node_moules folder or tests in parallel.

Would you rather like a separte file like proposed (eg. .iobrokerignore) or would it be better to have it in the existing config file, in order to not polute the workspace root folder?

I'd be happy with any of the two solutions. Both are fine, I guess.

Have you tried to sync your scripts in a subdirectory

Ah yes, that would work fine. I thought scriptRoot would be the remote folder. Thank you!

nokxs commented

I thought about the proposal and I will reject it. The initial problem can be solved by already supported features and an additional .iobrokerignore-file would complicate the extension.