TASIOMIND.DEV — OPERATIONAL▸▸▸FULL STACK DEVELOPER @ GWQ SERVICEPLUS AG▸▸▸FOUNDER — K8SGPT.AI▸▸▸OPEN SOURCE: ACTIVE▸▸▸DISTRIBUTED SYSTEMS / KUBERNETES / AI▸▸▸RUST + GO + PYTHON▸▸▸FIELD TESTED / STATUS — NOMINAL▸▸▸LOCATION: EUROPE/BERLIN▸▸▸TASIOMIND.DEV — OPERATIONAL▸▸▸FULL STACK DEVELOPER @ GWQ SERVICEPLUS AG▸▸▸FOUNDER — K8SGPT.AI▸▸▸OPEN SOURCE: ACTIVE▸▸▸DISTRIBUTED SYSTEMS / KUBERNETES / AI▸▸▸RUST + GO + PYTHON▸▸▸FIELD TESTED / STATUS — NOMINAL▸▸▸LOCATION: EUROPE/BERLIN▸▸▸

Set `npm init` defaults globally

February 20, 2017

You can either edit the global configuration file for npm:

code
npm config edit --global

(it'll open the file in your default editor, usually Vim)

Or, you can set the defaults one by one:

code
# npm config set <key> <value> [-g|--global]
npm config set -g init-author-name 'tasiomind'
npm config set -g init-author-email 'hello@tasiomind.com'
npm config set -g init-author-url 'http://tasiomind.com'
npm config set -g init-license 'CC-BY-SA-4.0'
npm config set -g init-version '0.0.1'

You can also use the npm init command with the y flag to initiate a project with the default values without prompting you for details.

code
npm init -y

To list all config values

code
npm config list