File tree 1 file changed +13
-0
lines changed
1 file changed +13
-0
lines changed Original file line number Diff line number Diff line change @@ -79,6 +79,17 @@ echo_latest_version() {
79
79
echo " $version "
80
80
}
81
81
82
+ echo_npm_postinstall () {
83
+ echoh
84
+ cath << EOF
85
+ The npm package has been installed successfully!
86
+ Please extend your path to use code-server:
87
+ PATH="$NPM_BIN_DIR :\$ PATH"
88
+ Please run with:
89
+ code-server
90
+ EOF
91
+ }
92
+
82
93
echo_standalone_postinstall () {
83
94
echoh
84
95
cath << EOF
@@ -392,6 +403,7 @@ install_npm() {
392
403
echoh " Installing with yarn."
393
404
echoh
394
405
" $sh_c " yarn global add code-server --unsafe-perm
406
+ NPM_BIN_DIR=" $( yarn global bin) " echo_npm_postinstall
395
407
return
396
408
elif command_exists npm; then
397
409
sh_c=" sh_c"
@@ -401,6 +413,7 @@ install_npm() {
401
413
echoh " Installing with npm."
402
414
echoh
403
415
" $sh_c " npm install -g code-server --unsafe-perm
416
+ NPM_BIN_DIR=" $( npm bin -g) " echo_npm_postinstall
404
417
return
405
418
fi
406
419
echoh
You can’t perform that action at this time.
0 commit comments