How can I add a .npmrc file?

后端 未结 4 1719
一向
一向 2020-12-12 14:10

I installed node on my Mac OS Sierra. I use Windows at my work so there I have a .npmrc file in the node folder but I don\'t seem to find that in mac. The problem is I want

4条回答
  •  情话喂你
    2020-12-12 14:51

    In MacOS Catalina 10.15.5 the .npmrc file path can be found at

    /Users//.npmrc
    

    Open in it in (for first time users, create a new file) any editor and copy-paste your token. Save it.

    You are ready to go.

    Note: As mentioned by @oligofren, the command npm config ls -l will npm configurations. You will get the .npmrc file from config parameter userconfig

提交回复
热议问题