Browse Source

exports before installing git-ssb

Bob Mottram 7 years ago
parent
commit
0ce090ab8b
2 changed files with 5 additions and 0 deletions
  1. 4
    0
      src/freedombone-app-scuttlebot
  2. 1
    0
      src/freedombone-utils-nodejs

+ 4
- 0
src/freedombone-app-scuttlebot View File

@@ -409,6 +409,10 @@ EOF
409 409
 
410 410
     cat <<EOF > "$rootdir/usr/bin/install_git_ssb"
411 411
 #!/bin/bash
412
+npm config set prefix '~/.npm-global'
413
+export PATH=~/.npm-global/bin:$PATH
414
+export NPM_CONFIG_PREFIX=~/.npm-global
415
+source ~/.profile
412 416
 if ! npm install --arch=$NPM_ARCH -g git-ssb; then
413 417
     exit 1
414 418
 fi

+ 1
- 0
src/freedombone-utils-nodejs View File

@@ -256,6 +256,7 @@ if [[ "$PATH" != *'~/.npm-global/bin'* ]]; then
256 256
     echo 'export PATH=~/.npm-global/bin:$PATH' >> ~/.bashrc
257 257
 fi
258 258
 export NPM_CONFIG_PREFIX=~/.npm-global
259
+echo 'export NPM_CONFIG_PREFIX=~/.npm-global' >> ~/.bashrc
259 260
 source ~/.profile
260 261
 EOF
261 262
     chroot "$rootdir" /bin/chmod +x /usr/bin/install_npm_global