安装homebrew、nvm、verdaccio搭建私有npm仓库

1. Homebrew国内如何自动安装(国内地址)(Mac & Linux)

自动脚本(全部国内地址)(复制下面一句脚本到终端中粘贴回车)

苹果电脑 常规安装脚本(推荐 完全体 几分钟安装完成):

/bin/zsh -c "$(curl -fsSL https://gitee.com/cunkai/HomebrewCN/raw/master/Homebrew.sh)"

苹果电脑 极速安装脚本(精简版 几秒钟安装完成):

/bin/zsh -c "$(curl -fsSL https://gitee.com/cunkai/HomebrewCN/raw/master/Homebrew.sh)" speed

-> Mac电脑如何打开终端:command+空格 在聚焦搜索中输入terminal回车

苹果电脑 卸载脚本:

/bin/zsh -c "$(curl -fsSL https://gitee.com/cunkai/HomebrewCN/raw/master/HomebrewUninstall.sh)"

常见错误去下方地址查看

https://gitee.com/cunkai/HomebrewCN/blob/master/error.md


Linux电脑 安装脚本:

rm Homebrew.sh ; wget https://gitee.com/cunkai/HomebrewCN/raw/master/Homebrew.sh ; bash Homebrew.sh

Linux电脑 卸载脚本:

rm HomebrewUninstall.sh ; wget https://gitee.com/cunkai/HomebrewCN/raw/master/HomebrewUninstall.sh ; bash HomebrewUninstall.sh

2. nvm安装

代码库: 

https://github.com/nvm-sh/nvm#install--update-script

下载代码库

安装:sh install.sh

profile file (~/.bash_profile, ~/.zshrc, ~/.profile, or ~/.bashrc).

export NVM_DIR="$([ -z "${XDG_CONFIG_HOME-}" ] && printf %s "${HOME}/.nvm" || printf %s "${XDG_CONFIG_HOME}/nvm")"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm


刷新全局配置
bash: source ~/.bashrc
zsh: source ~/.zshrc
ksh: . ~/.profile

安装node
nvm instll 14 

3. verdaccio搭建私有npm仓库

安装
npm install -g verdaccio

运行
verdaccio

打开
http://localhost:4873/


1. Login
npm adduser --registry http://localhost:4873/

2. Publish
npm publish --registry http://localhost:4873/

3. Refresh this page

参考1:Homebrew国内如何自动安装(国内地址)(Mac & Linux) - 知乎

参考2:https://github.com/nvm-sh/nvm

参考3:使用Verdaccio搭建私有npm仓库 - 简书

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

区块链(Web3)开发工程师

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值