install.fairie/home/dot_config/npm/private_npmrc.tmpl
Brian Zalewski 33495f6bc5 Latest
2024-04-02 08:18:09 +00:00

15 lines
829 B
Cheetah

cache={{ .chezmoi.homeDir }}/.cache/npm
{{ if (stat (joinPath "etc" "ssl" "cert.pem")) -}}
cafile=/etc/ssl/cert.pem
{{ end -}}
init-author-email={{ .user.email }}
init-author-name={{ .user.name }} <{{ .user.email }}> ({{ .user.domain }})
init-author-url=https://{{ .user.domain }}/
init-license=MIT
init-module={{ .chezmoi.homeDir }}/.config/npm/config/npm-init.js
init-version=0.0.1
loglevel=error
network-concurrency=32
prefix={{ .chezmoi.homeDir }}/.local/share/npm
strict-peer-dependencies=false
//registry.npmjs.org/:_authToken={{ if and (stat (joinPath .host.home ".config" "age" "chezmoi.txt")) (stat (joinPath .chezmoi.sourceDir ".chezmoitemplates" "secrets" "NPM_TOKEN")) }}{{- includeTemplate "secrets/NPM_TOKEN" | decrypt | trim -}}{{ else if (env "NPM_TOKEN") }}{{- env "NPM_TOKEN" -}}{{ else }}${NPM_TOKEN}{{ end }}