npm - .npmrc file permission are not stored by git -
in project want use .npmrc file point private repository. documentation npmrc read:
note: because local (per-project or per-user)
.npmrcfiles can contain sensitive credentials, must readable , writable user account (i.e. must have mode of 0600), otherwise ignored npm!
unfortunately git not honouring file permission 0600.
so: how store .npmrc file in git?
as found out right.
git doesn't care file permissions.
git stores 2 permissions (
755&644), need of600not "recognized" git.
to override im using manual script this site or this
umask
umask process attribute containing permission bits removed newly created files.
git creates directories , executable files mode 777, , non-executable files 666, , umask turns off of bits.
if want default permissions 644 , 755, set umask 022:
umask 022
Comments
Post a Comment