File tree 3 files changed +23
-13
lines changed
3 files changed +23
-13
lines changed Original file line number Diff line number Diff line change
1
+ {
2
+ "tabWidth": 2,
3
+ "prettier.singleQuote": true
4
+ }
Original file line number Diff line number Diff line change 1
1
---
2
2
# tasks file for nodejs
3
3
- name : clone nvm into ~/.nvm
4
- git :
4
+ git :
5
5
repo : https://github.com/nvm-sh/nvm.git
6
- dest : ~/.nvm
6
+ dest : ~/.nvm
7
7
- name : Add NVM initialization to startup files
8
8
blockinfile :
9
9
marker : " ### {mark} INTIALIZE NVM"
18
18
with_items :
19
19
- " ~/.zshrc"
20
20
- name : Install Node {{ wanted_node_version }}
21
- command :
21
+ command :
22
22
cmd : bash -c '. ~/.nvm/nvm.sh; nvm install {{ wanted_node_version }};'
23
- creates :
23
+ creates :
24
24
- ~/.nvm/versions/node/*{{ wanted_node_version }}*/bin/node
25
25
- name : Set Node {{ wanted_node_version }} to be the default
26
26
command :
36
36
command :
37
37
cmd : bash -c '. ~/.nvm/nvm.sh; nvm use --silent default; which npm'
38
38
register : npm_path
39
- - name : Add node and npm to path
40
- shell : export PATH="$HOME/.nvm/versions/node/v18.14.0/bin:$PATH"
41
- - name : Add the path to .zshrc
39
+ # - name: Add node and npm to path
40
+ # shell: export PATH="$HOME/.nvm/versions/node/v18.14.0/bin:$PATH"
41
+ - name : Add the path to .zshrc
42
42
lineinfile :
43
+ marker : " ### {mark} Add Node directory to the PATH"
43
44
dest : ~/.zshrc
44
- line : export PATH="$HOME/.nvm/versions/node/v18.14.0/bin :$PATH"
45
+ line : export PATH="$HOME/.nvm/versions/node:$PATH"
45
46
- name : Print Node version
46
- debug :
47
+ debug :
47
48
msg : " {{ node_version.stdout }}"
48
49
- name : Print Node version
49
- debug :
50
- msg : " {{ npm_path.stdout }}"
50
+ debug :
51
+ msg : " {{ npm_path.stdout }}"
Original file line number Diff line number Diff line change 3
3
update_homebrew : yes
4
4
name : postgresql@15
5
5
state : present
6
- - name : Add PATH for postgresql@15
7
- command : echo 'export PATH="/opt/homebrew/opt/postgresql@15/bin:$PATH"' >> ~/.zshrc && source ~/.zshrc
6
+ # - name: Add PATH for postgresql@15
7
+ # command: echo 'export PATH="/opt/homebrew/opt/postgresql@15/bin:$PATH"' >> ~/.zshrc && source ~/.zshrc
8
+ - name : Add postgres directory to the PATH
9
+ lineinfile :
10
+ marker : " ### {mark} Add postgresql@15 directory to the PATH"
11
+ dest : ~/.zshrc
12
+ line : export PATH="/opt/homebrew/opt/postgresql@15/bin:$PATH"
8
13
- name : Start postgresl
9
14
command : brew services start postgresql@15
10
15
- name : Check for default database
You can’t perform that action at this time.
0 commit comments