npm & config settings

how to check npm config settings

https://docs.npmjs.com/cli/config


$ npm config list $ npm config list --json
$ npm config list -l
$ npm config list -l --json
$ npm config list --json

{
"json": true,
"user-agent": "npm/6.4.1 node/v10.15.3 win32 x64",
"metrics-registry": "https://registry.npmjs.org/",
"scope": "",
"prefix": "C:\\Users\\xgqfrms\AppData\\Roaming\\npm",
"access": null,
"allow-same-version": false,
"always-auth": false,
"also": null,
"audit": true,
"audit-level": "low",
"auth-type": "legacy",
"bin-links": true,
"browser": null,
"ca": null,
"cache": "C:\\Users\\xgqfrms\\AppData\\Roaming\\npm-cache",
"cache-lock-stale": 60000,
"cache-lock-retries": 10,
"cache-lock-wait": 10000,
"cache-max": null,
"cache-min": 10,
"cert": null,
"cidr": null,
"color": true,
"depth": null,
"description": true,
"dev": false,
"dry-run": false,
"editor": "notepad.exe",
"engine-strict": false,
"force": false,
"fetch-retries": 2,
"fetch-retry-factor": 10,
"fetch-retry-mintimeout": 10000,
"fetch-retry-maxtimeout": 60000,
"git": "git",
"git-tag-version": true,
"commit-hooks": true,
"global": false,
"globalconfig": "C:\\Users\\xgqfrms\\AppData\\Roaming\\npm\\etc\\npmrc",
"global-style": false,
"group": 0,
"ham-it-up": false,
"heading": "npm",
"if-present": false,
"ignore-prepublish": false,
"ignore-scripts": false,
"init-module": "C:\\Users\\xgqfrms\\.npm-init.js",
"init-author-name": "",
"init-author-email": "",
"init-author-url": "",
"init-version": "1.0.0",
"init-license": "ISC",
"key": null,
"legacy-bundling": false,
"link": false,
"loglevel": "notice",
"logs-max": 10,
"long": false,
"maxsockets": 50,
"message": "%s",
"node-options": null,
"node-version": "10.15.3",
"offline": false,
"onload-script": null,
"only": null,
"optional": true,
"otp": null,
"package-lock": true,
"package-lock-only": false,
"parseable": false,
"prefer-offline": false,
"prefer-online": false,
"preid": "",
"production": false,
"progress": true,
"proxy": null,
"https-proxy": null,
"noproxy": null,
"read-only": false,
"rebuild-bundle": true,
"registry": "https://registry.npmjs.org/",
"rollback": true,
"save": true,
"save-bundle": false,
"save-dev": false,
"save-exact": false,
"save-optional": false,
"save-prefix": "^",
"save-prod": false,
"script-shell": null,
"scripts-prepend-node-path": "warn-only",
"searchopts": "",
"searchexclude": null,
"searchlimit": 20,
"searchstaleness": 900,
"send-metrics": false,
"shell": "C:\\WINDOWS\\system32\\cmd.exe",
"shrinkwrap": true,
"sign-git-commit": false,
"sign-git-tag": false,
"sso-poll-frequency": 500,
"sso-type": "oauth",
"strict-ssl": true,
"tag": "latest",
"tag-version-prefix": "v",
"timing": false,
"tmp": "C:\\Users\\xgqfrms\\AppData\\Local\\Temp",
"unicode": false,
"unsafe-perm": true,
"update-notifier": true,
"usage": false,
"user": 0,
"userconfig": "C:\\Users\\xgqfrms\\.npmrc",
"umask": 0,
"version": false,
"versions": false,
"viewer": "browser",
"globalignorefile": "C:\\Users\\xgqfrms\\AppData\\Roaming\\npm\\etc\\npmignore"
}

$ npm config set <key> <value> [-g|--global]
$ npm config get <key>
$ npm config delete <key>
$ npm config list [-l] [--json]
$ npm config edit
$ npm get <key>
$ npm set <key> <value> [-g|--global] # aliases: c

https://docs.npmjs.com/misc/config

https://docs.npmjs.com/cli/config

https://docs.npmjs.com/files/npmrc

https://docs.npmjs.com/managing-your-profile-settings

https://stackoverflow.com/questions/42137329/npm-config-list-environment-configs-registry


npm install -d

holy shit

https://docs.npmjs.com/cli/install

https://www.npmjs.com.cn/cli/install/

这个 -d --save 啥意思,要么 -D / --save-dev , 要么 -S / --save

所以你这个 -d --save 不存在的呀;要么 -D / --save-dev , 要么 -S / --save

-d 不认识,直接被 npm 忽略了, 所以 --save 才会生效

refs



xgqfrms 2012-2020

www.cnblogs.com 发布文章使用:只允许注册用户才可以访问!


npm & config settings的更多相关文章

  1. [NPM] Use custom config settings in your npm scripts

    In addition to package.json level variables (such as name and version), you can have custom conf set ...

  2. npm config

    在公司为了不再用 npm --registry=http://r.cnpmjs.org install -(g) xxx 就设置了内部的镜像文件地址为默认的代理地址 npm config set re ...

  3. npm config 删除变量

    问题 安装npm时,使用npm config set 命令重新设置了变量,但是设置变量时少了个空格,设置错了.使用npm config ls -l 查看环境变量 添加错的这一个,应该如何删除? 解决 ...

  4. .net Core Abp See config settings - "CustomSchemaIds" for a workaround

    Swagger  See config settings - "CustomSchemaIds" for a workaround System.InvalidOperationE ...

  5. npm 取消代理 npm config delete proxy

    今天在安装electron时设置了代理,发现再npm install 安装别的总是装不上,只好取消代理. npm 取消代理 npm config delete proxy

  6. npm & npm config

    npm command show npm config https://docs.npmjs.com/cli/config https://docs.npmjs.com/cli/ls https:// ...

  7. 56.如何清除已经设置的npm config配置

    npm config delete registry npm config delete disturl 或者 npm config edit 找到淘宝那两行,删除

  8. npm config set registry 与 cnpm的区别

    一直以为这2个事没有区别的: npm config set registry http://registry.npm.taobao.org 后使用npm命令. npm install -g cnpm ...

  9. npm config set registry

    npm config set registry $ npm config set registry $ npm config set registry https://registry.your-re ...

随机推荐

  1. Redis集群拆分原则之AKF

    当我们搭建集群的时候,首先要想明白需要解决哪些问题,搞清楚这个之前,想想单节点.单实例.单机有哪些问题? 单点故障 容量有限 可支持的连接有限(性能不足) ...... 为了解决这些问题,我们需要对服 ...

  2. 如何手动封装Promise函数

    第一步:Promise构造函数接受一个函数作为参数,该函数的两个参数分别是:resolve和reject; function Promise(task) { // 缓存this let that = ...

  3. SparkStreaming算子操作,Output操作

    SparkStreaming练习之StreamingTest,UpdateStateByKey,WindowOperator 一.SparkStreaming算子操作 1.1 foreachRDD 1 ...

  4. linux shell判断文件,目录是否存在或者具有权限

    在linux中判断文件,目录是否存在或则具有的权限,根据最近的学习以及网上的资料,进行了以下的总结: #!/bin/sh myPath="/var/log/httpd/" myFi ...

  5. 分布式-springboot基础入门

    B站播放地址:https://www.bilibili.com/video/BV1PE411i7CV?t=51 博客地址:https://www.cnblogs.com/hellokuangshen/ ...

  6. 痞子衡嵌入式:恩智浦MCUX SDK在GitHub上线了

    大家好,我是痞子衡,是正经搞技术的痞子.今天痞子衡给大家讲的是恩智浦MCUX SDK 在GitHub上线一事. 其实在差不多一个月前(2021年1月6日),恩智浦MCUX SDK就在GitHub悄悄上 ...

  7. 使用eclipse写第一个Java_web的hello_world项目

    1.先创建一个Java_web项目 如果你没有下载过Tomcat服务器,不会配置,建议看一下我得这一篇博客:https://www.cnblogs.com/kongbursi-2292702937/p ...

  8. VJ train1 O-统计问题 题解

    原谅我缺少设备,只能手写图解 题目:           在一无限大的二维平面中,我们做如下假设:             1.  每次只能移动一格:             2.  不能向后走(假设 ...

  9. Codeforces Round #307 (Div. 2) B. ZgukistringZ

    Professor GukiZ doesn't accept string as they are. He likes to swap some letters in string to obtain ...

  10. AtCoder Beginner Contest 182 D - Wandering (前缀和)

    题意:在\(x\)轴上,你刚开始在\(0\)的位置,第\(i\)次操作需要走\(A_1,...,A_i\)个单位,如果\(A_i\)为正向右走,否则向左走,求你所能走到的最大坐标. 题解:我们一步一步 ...