nodeswitch 1.9.1 → 1.9.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/LICENSE CHANGED
@@ -1,21 +1,21 @@
1
- MIT License
2
-
3
- Copyright (c) 2024 alexsch01
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in all
13
- copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
- SOFTWARE.
1
+ MIT License
2
+
3
+ Copyright (c) 2024 alexsch01
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -1,48 +1,48 @@
1
- # nodeswitch
2
-
3
- Node version switcher for Microsoft Windows x64
4
-
5
- https://github.com/alexsch01/nodeswitch
6
-
7
- <br>
8
-
9
- #### How To Install
10
-
11
- ```
12
- npm install -g nodeswitch
13
-
14
- *****
15
- Node versions installed by this tool are in the "C:\Users\YOUR_USERNAME\AppData\Roaming\nodeswitch" folder
16
- *****
17
- ```
18
-
19
- #### Examples
20
-
21
- ```
22
- nodeswitch add 12.16.3
23
- nodeswitch add 18.13.0
24
-
25
- nodeswitch remove 12.16.3
26
- nodeswitch remove 18.13.0
27
-
28
- nodeswitch use 12.16.3
29
- nodeswitch use 18.13.0
30
-
31
- nodeswitch use default
32
-
33
- nodeswitch list
34
-
35
- nodeswitch path
36
- nodeswitch pathopen
37
- ```
38
-
39
- #### How To Uninstall
40
-
41
- ```
42
- npm uninstall -g nodeswitch
43
-
44
- *****
45
- In the "C:\Users\YOUR_USERNAME\AppData\Roaming\npm" folder, delete 4 files: nodeswitch, nodeswitch.cmd, nodeswitch.ps1, and nodeswitch.sh
46
- In the "C:\Users\YOUR_USERNAME\.bash_profile" file, remove the line [alias nodeswitch="source nodeswitch"]
47
- *****
48
- ```
1
+ # nodeswitch
2
+
3
+ Node version switcher for Microsoft Windows x64
4
+
5
+ https://github.com/alexsch01/nodeswitch
6
+
7
+ <br>
8
+
9
+ #### How To Install
10
+
11
+ ```
12
+ npm install -g nodeswitch
13
+
14
+ *****
15
+ Node versions installed by this tool are in the "C:\Users\YOUR_USERNAME\AppData\Roaming\nodeswitch" folder
16
+ *****
17
+ ```
18
+
19
+ #### Examples
20
+
21
+ ```
22
+ nodeswitch add 12.16.3
23
+ nodeswitch add 18.13.0
24
+
25
+ nodeswitch remove 12.16.3
26
+ nodeswitch remove 18.13.0
27
+
28
+ nodeswitch use 12.16.3
29
+ nodeswitch use 18.13.0
30
+
31
+ nodeswitch use default
32
+
33
+ nodeswitch list
34
+
35
+ nodeswitch path
36
+ nodeswitch pathopen
37
+ ```
38
+
39
+ #### How To Uninstall
40
+
41
+ ```
42
+ npm uninstall -g nodeswitch
43
+
44
+ *****
45
+ In the "C:\Users\YOUR_USERNAME\AppData\Roaming\npm" folder, delete 4 files: nodeswitch, nodeswitch.cmd, nodeswitch.ps1, and nodeswitch.sh
46
+ In the "C:\Users\YOUR_USERNAME\.bash_profile" file, remove the line [alias nodeswitch="source nodeswitch"]
47
+ *****
48
+ ```
package/bin/nodeswitch CHANGED
@@ -1 +1 @@
1
- (return 0 2>/dev/null) && source nodeswitch.sh "$@" || echo "You need to relaunch Git Bash in order to use nodeswitch"
1
+ (return 0 2>/dev/null) && source nodeswitch.sh "$@" || echo "You need to relaunch Git Bash in order to use nodeswitch"
@@ -30,7 +30,7 @@ if not "%1" == "" (
30
30
  )
31
31
  ) else if "%1" == "add" (
32
32
  if not exist %AppData%\nodeswitch\%2 (
33
- curl -f https://nodejs.org/download/release/v%2 > nul 2>&1
33
+ curl -f https://nodejs.org/download/release/v%2/ > nul 2>&1
34
34
  if %ERRORLEVEL% equ 0 (
35
35
  curl -s -o %AppData%\nodeswitch\%2.zip https://nodejs.org/download/release/v%2/node-v%2-win-x64.zip > nul
36
36
 
@@ -31,7 +31,7 @@ if ( $nodeswitch1stParameter -ne $null ) {
31
31
  }
32
32
  } elseif ( $nodeswitch1stParameter -eq "add" ) {
33
33
  if ( -not ( Test-Path -Path $env:AppData\nodeswitch\$nodeswitch2ndParameter ) ) {
34
- cmd /c "curl -f https://nodejs.org/download/release/v$nodeswitch2ndParameter > nul 2>&1"
34
+ cmd /c "curl -f https://nodejs.org/download/release/v$nodeswitch2ndParameter/ > nul 2>&1"
35
35
  if ( $LASTEXITCODE -eq 0 ) {
36
36
  cmd /c "curl -s -o $env:AppData\nodeswitch\$nodeswitch2ndParameter.zip https://nodejs.org/download/release/v$nodeswitch2ndParameter/node-v$nodeswitch2ndParameter-win-x64.zip > nul"
37
37
 
package/bin/nodeswitch.sh CHANGED
@@ -40,7 +40,7 @@ then
40
40
  then
41
41
  if [ ! -d "$APPDATA/nodeswitch/$2" ]
42
42
  then
43
- curl -f https://nodejs.org/download/release/v$2 &>/dev/null
43
+ curl -f https://nodejs.org/download/release/v$2/ &>/dev/null
44
44
  if [ $? -eq 0 ]
45
45
  then
46
46
  curl -s -o $APPDATA/nodeswitch/$2.zip https://nodejs.org/download/release/v$2/node-v$2-win-x64.zip > /dev/null
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "nodeswitch",
3
- "version": "1.9.1",
3
+ "version": "1.9.2",
4
4
  "description": "Node version switcher for Microsoft Windows x64",
5
5
  "scripts": {
6
6
  "preinstall": "node scripts/preinstall.js",