You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
MurakamiShinyu
changed the title
Generated directory has .npmignore file instead of the .gitignore
Generated directory has no .gitignore file
Apr 21, 2022
npm create book <directory>
の実行によって生成されるディレクトリに.gitignore
ファイルが存在しないで、代わりに.gitignore
が存在するという現象があります。yarn を使った場合には発生しないようです。npmを使ったときにも必ずしそうなるわけではないようです(条件が特定できていません)。問題が起きたときのログ:
↑
.npmignore
が存在して.gitignore
が存在しない。これではgitにコミットする前に
mv .npmignore .gitignore
によりファイル名の変更が必要です。npmでの .gitignore ファイルの扱いの問題のようです。Stackoverflow に関係しそうな情報がありました:
https://stackoverflow.com/questions/24976950/how-do-i-include-a-gitignore-file-as-part-of-my-npm-module
npmの次のissueが関連するようです:
npm/npm#1862
The text was updated successfully, but these errors were encountered: