安装命令:/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
结果发现报错了:unable to access 'https://github.com/Homebrew/brew/': Could not resolve host: github.com
然后在百度了找到了解决方案:
修改/etc/hosts文件,在底部添加 192.30.253.112 github.com (sudo打开,不然没权限)
使用brew安装node
brew install node
想安装谷歌浏览器,发现并不能安装需要安装工具扩展
brew install caskroom/cask/brew-cask 接下来可以安装浏览器了
安装谷歌浏览器,只需在brew后面加一个cask
brew cask install google-chrome
完成