From b91dfdbbf4064dfc1fb2b10b2f4360ac1ba9837f Mon Sep 17 00:00:00 2001 From: Gianmarco Pettinato Date: Sat, 25 Dec 2021 18:52:02 +0100 Subject: [PATCH] update nvm --- local.yml | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/local.yml b/local.yml index 9e78476..f24be88 100644 --- a/local.yml +++ b/local.yml @@ -58,4 +58,14 @@ shell: > curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.1/install.sh | bash args: - creates: "{{ ansible_env.HOME }}/.nvm/nvm.sh" \ No newline at end of file + creates: "{{ ansible_env.HOME }}/.nvm/nvm.sh" + + - name: install nvm env + lineinfile: + path: /home/gianm/.zshrc + line: 'export NVM_DIR="$HOME/.nvm" + [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" + [ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion"' + + - name: install node + shell: zsh && source /home/gianm/.zshrc && nvm install --lts \ No newline at end of file