-
Notifications
You must be signed in to change notification settings - Fork 213
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Why a .vscodeignore file? Use the files property instead #12
Comments
We'll just support both. |
That would be great! |
Yes, blacklisting is error prone: whenever I add another file to my project that should not end up in the extension, I have to add it to the |
There is also |
Should the |
Put my thoughts here and hope it help :) Even though Bower is somewhat dead already, I do like how it does component referencing in old days. When you try to install bower packages, it will save the package in
This way you can specific which file is the main file for each component if you don't like the default one bower picks for you. If we can similar experience, I don't need to write any glob expressions in the vscodeignore file as it's always difficult to say which files are necessary and which are not in each npm_component folder. Another thing is, we can always put debugger, code snippet or linters together in one extension, which means there might be multiple entry points for a single extension. In this case, we can't merge all javascript code to one file. Above is just my draft idea and it should be carefully reconsidered, but I think a workable solution for now adding some grunt/gulp sample to the yeoman generator? |
Neither vsce nor its source code look like the I prefer whitelists to blacklists too, as they explicitly state what is being included and what not. |
This might be incredibly ignorant or shortsighted of me, but would ignoring everything and unignoring what you want, accomplish the same thing? VS Code Ignore
|
@selvinortiz yes, that approach works fine. I'm using it here: https://github.com/Microsoft/vscode-mono-debug/blob/master/.vscodeignore |
@weinand Cool. I guess most people would say that it's not the most elegant solution?! |
@selvinortiz Semantics are different from .gitignore. You need the following for the ignore part:
|
This iteration we focus on issue grooming. This issue is being closed to keep the number of issues in our inbox on a manageable level, we are closing issues that are not going to be addressed in the foreseeable future: We look at the number of votes the issue has received and the number of duplicate issues filed. More details here. If you disagree and feel that this issue is crucial: We are happy to listen and to reconsider. If you wonder what we are up to, please see our roadmap and issue reporting guidelines. Thanks for your understanding and happy coding! |
@weinand wrote:
I just discovered that 1.92 broke this technique. See #576 Seems it's not going to be reinstated 😞 |
@joaomoreno So why does the
To clarify, @SamVerschueren @weinand @selvinortiz @adamvoss @gjsjohnmurray, and for anyone else running into this… The following # Ignore everything
**
# Whitelist
!*.js |
if I understand correctly,
.vscodeignore
is meant for files that should be ignored when the extension is installed.In
npm
, this is already done by thefiles
property inpackage.json
. More information can be found under thefiles
section https://docs.npmjs.com/files/package.json#files.Where
.vscodeignore
is a blacklist of files that should not be installed, thefiles
property is a whitelist of files that should be installed.In my opinion, it would be way better to use the
files
property. Node package developers (should) already know about this setting and no extra file is used.Originally posted at https://github.com/Microsoft/vscode-extensionbuilders/issues/35#event-438763500
The text was updated successfully, but these errors were encountered: