Skip to content

Commit 4a4b619

Browse files
authored
fix: Mac node install (#47 by @vonovak)
1 parent 6318496 commit 4a4b619

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

src/commands/setup_macos_executor.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -24,14 +24,14 @@ steps:
2424
2525
- run:
2626
name: Install node@<<parameters.node_version>>
27+
# after `curl`, bashrc contains the script to load nvm, we need to source it to use it
2728
command: |
28-
set +e
29-
touch $BASH_ENV
30-
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.5/install.sh | bash
31-
echo 'export NVM_DIR="$HOME/.nvm"' >> $BASH_ENV
32-
echo '[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"' >> $BASH_ENV
33-
echo nvm install <<parameters.node_version>> >> $BASH_ENV
34-
echo nvm alias default <<parameters.node_version>> >> $BASH_ENV
29+
set +e
30+
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.35.3/install.sh | bash
31+
source ~/.bashrc
32+
command -v nvm
33+
nvm install <<parameters.node_version>>
34+
nvm alias default <<parameters.node_version>>
3535
- run:
3636
name: Verify node version
3737
command: node --version

0 commit comments

Comments
 (0)