Skip to content

Commit e8f11ea

Browse files
fix(download): add Windows support for fnm (#9252)
Signed-off-by: bmuenzenmeyer <brian.muenzenmeyer@gmail.com>
1 parent 53d777b commit e8f11ea

2 files changed

Lines changed: 8 additions & 2 deletions

File tree

‎apps/site/snippets/en/download/fnm.bash‎

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,11 @@ ${props.os === 'WIN' ?
44
'curl -o- https://fnm.vercel.app/install | bash'
55
}
66

7+
# In lieu of restarting the shell
8+
${props.os === 'WIN' ?
9+
'fnm env --use-on-cd --shell powershell | Out-String | Invoke-Expression' :
10+
'export PATH="$HOME/.local/share/fnm:$PATH"\neval "$(fnm env)"'
11+
}
12+
713
# Download and install Node.js:
8-
fnm install ${props.release.major}
14+
fnm install --use ${props.release.major}

‎apps/site/util/download/constants.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@
140140
"icon": "FNM",
141141
"name": "fnm",
142142
"compatibility": {
143-
"os": ["MAC", "LINUX"]
143+
"os": ["MAC", "LINUX", "WIN"]
144144
},
145145
"recommended": true,
146146
"url": "https://github.com/Schniz/fnm",

0 commit comments

Comments
 (0)