generator-polymer-init-custom-build
generator-polymer-init-custom-build copied to clipboard
[support] .gitignore in 1.0.0 (PSK2)?
New to Polymer here. I used polymer init custom-build
and I did not get a resulting .gitignore file that excluded /bower and /node_modules. I do see that I am using 1.0.0 of custom-build which points to the 2.0 tag of the Polymer Starter Kit. That tag does have the correct .gitignore file.
Why do I not automatically get the .gitignore in PSK 2.0?
Actually, it seems as if maybe it was intentional not to ship with a .gitignore since many will want to have their own overrides to that.
Even so I think maybe a .gitignore-suggested would be good if that's the case. Some confirmation on this would still be awesome!
This is not intentional. For some reason Polymer CLI is not copying it. PSK2 has .gitignore
included.
.gitignore (should include at least these lines)
bower_components/
build/
node_modules/
I wonder if we should move this to https://github.com/Polymer/polymer-cli.
Also, I am using v0.16.0 of polymer-cli.
It may be related to this: https://github.com/yeoman/generator-polymer/blob/master/app/index.js#L60
I think when you npm install something with a .gitignore
it renames it to .npmignore
. Need to double check that's the case.
It is still related to npm bug that renames .gitignore
to .npmignore
. See below.
As @robdodson was saying .gitignore
does get renamed to .npmignore
. There is a good conversation here https://github.com/npm/npm/issues/7252 but ultimately would need a work around from the sounds of it.