Every time I create new npm project, there is wrong author name, can I change it?
package name: (template) template
version: (1.0.0)
description:
entry point: (index.js) bot.js
test command:
git repository:
keywords:
license: (ISC)
About to write to:
{
"name": "template",
"version": "1.0.0",
"description": "",
"main": "bot.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"author": "*wrong author*",
"license": "ISC"
}
Just type nvm alias default v10. 16.3 in your terminal and then type nvm use default . This command will make v10. 16.3 available in any shell you open — you just have to restart your terminal to make sure it works.
The default is typically set to the public npm registry at https://registry.npmjs.org/ . For more information about npm configuration files, see the npm config file documentation.
npm install saves any specified packages into dependencies by default. Additionally, you can control where and how they get saved with some additional flags: -P, --save-prod : Package will appear in your dependencies .
You can run following Commond
npm config set init.author.name "your name"
or go to package.json file and edit the auther name.
package name: (template) template
version: (1.0.0)
description:
entry point: (index.js) bot.js
test command:
git repository:
keywords:
license: (ISC)
About to write to:
{
"name": "template",
"version": "1.0.0",
"description": "",
"main": "bot.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"author": "Rajneesh Shukla",
"license": "ISC"
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With