目的
MACにnode.jsとnpmをinstallする
環境
MAC OS Catalina 10.15.2で実施
作業ログ
bash
# xcodeのinstall (gccのinstallに必要)$ xcode-select --install# gccのinstall (nodebrewのinstallに必要)$ brew install gcc
# nodebrewのinstall$ brew install nodebrew
# nodebrewでinstallされるファイルが格納されるdirectoryを作成$ mkdir-p ~/.nodebrew/src
$ nodebrew install-binary stable
# currentの表示されるのが使うversion$ nodebrew list
v12.14.0
current: none
# stableを使うと指定$ nodebrew use stable
use v12.14.0
# node.jsのversion確認$ node -v
v12.14.0
# npmのversion確認$ npm -v
6.13.4