I have:
[email protected] postinstall /usr/local/lib/node_modules/pure-prompt
PURE_DEST=/usr/local/share/zsh/site-functions npm run --silent postinstall-link && exit 0; PURE_DEST="$PWD/functions" npm run postinstall-link && npm run postinstall-fail-instructions
ln: impossible de crΓ©er le lien symbolique Β«/usr/local/share/zsh/site-functions/prompt_pure_setupΒ»: Permission non accordΓ©e
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β npm update check failed β
β Try running with sudo or get access β
β to the local update config store via β
β sudo chown -R $USER:$(id -gn $USER) /home/dev/.config β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
[email protected] postinstall-link /usr/local/lib/node_modules/pure-prompt
mkdir -p "$PURE_DEST" && ln -sf "$PWD/pure.zsh" "$PURE_DEST/prompt_pure_setup" && ln -sf "$PWD/async.zsh" "$PURE_DEST/async"
mkdir: impossible de crΓ©er le rΓ©pertoire Β«/usr/local/lib/node_modules/pure-prompt/functionsΒ»: Permission non accordΓ©e
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] postinstall-link: mkdir -p "$PURE_DEST" && ln -sf "$PWD/pure.zsh" "$PURE_DEST/prompt_pure_setup" && ln -sf "$PWD/async.zsh" "$PURE_DEST/async"
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] postinstall-link script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β npm update check failed β
β Try running with sudo or get access β
β to the local update config store via β
β sudo chown -R $USER:$(id -gn $USER) /home/dev/.config β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
npm ERR! A complete log of this run can be found in:
npm ERR! /home/dev/.npm/_logs/2017-08-25T11_11_25_184Z-debug.log
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] postinstall: PURE_DEST=/usr/local/share/zsh/site-functions npm run --silent postinstall-link && exit 0; PURE_DEST="$PWD/functions" npm run postinstall-link && npm run postinstall-fail-instructions
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /home/dev/.npm/_logs/2017-08-25T11_11_25_270Z-debug.log
launch the npm install command
.zshrc:autoload -U promptinit; promptinit
prompt pure
This seems similar to #341. No idea why it's failing.
Can you post the full output of: ls -lha /usr/local/lib/node_modules/pure-prompt ?
I have the same issue.
The full output of ls -lha /usr/local/lib/node_modules/pure-prompt is:
ls: cannot access '/usr/local/lib/node_modules/pure-prompt': No such file or directory
@LitoMore was your error identical to what @hyphaene had (e.g. same folders, etc)?
The current installation script relies on $PWD being the directory where pure was installed.
Sorry, my mistake, I forgot my node_modules is in the /usr/lib. NOT /usr/local/lib.
The full output of ls -lha /usr/lib/node_modules/pure-prompt is:
ls: cannot access '/usr/lib/node_modules/pure-prompt': No such file or directory
Where is npm installing pure for you?
/usr/lib/node_modules/pure-prompt
echo $PWD: /rootThis is my output of npm i -g pure-prompt:
> [email protected] postinstall /usr/lib/node_modules/pure-prompt
> PURE_DEST=/usr/local/share/zsh/site-functions npm run --silent postinstall-link && exit 0; PURE_DEST="$PWD/functions" npm run postinstall-link && npm run postinstall-fail-instructions
glob error { Error: EACCES: permission denied, scandir '/root/.npm/_logs'
stack: 'Error: EACCES: permission denied, scandir \'/root/.npm/_logs\'',
errno: -13,
code: 'EACCES',
syscall: 'scandir',
path: '/root/.npm/_logs' }
βββββββββββββββββββββββββββββββββββββββββββββββββββββ
β npm update check failed β
β Try running with sudo or get access β
β to the local update config store via β
β sudo chown -R $USER:$(id -gn $USER) /root/.config β
βββββββββββββββββββββββββββββββββββββββββββββββββββββ
npm ERR! path /root/.npm/_logs
npm ERR! code EACCES
npm ERR! errno -13
npm ERR! syscall scandir
npm ERR! Error: EACCES: permission denied, scandir '/root/.npm/_logs'
npm ERR! { Error: EACCES: permission denied, scandir '/root/.npm/_logs'
npm ERR! stack: 'Error: EACCES: permission denied, scandir \'/root/.npm/_logs\'',
npm ERR! errno: -13,
npm ERR! code: 'EACCES',
npm ERR! syscall: 'scandir',
npm ERR! path: '/root/.npm/_logs' }
npm ERR!
npm ERR! Please try running this command again as root/Administrator.
glob error { Error: EACCES: permission denied, scandir '/root/.npm/_logs'
stack: 'Error: EACCES: permission denied, scandir \'/root/.npm/_logs\'',
errno: -13,
code: 'EACCES',
syscall: 'scandir',
path: '/root/.npm/_logs' }
> [email protected] postinstall-link /usr/lib/node_modules/pure-prompt
> mkdir -p "$PURE_DEST" && ln -sf "$PWD/pure.zsh" "$PURE_DEST/prompt_pure_setup" && ln -sf "$PWD/async.zsh" "$PURE_DEST/async"
mkdir: cannot create directory β/usr/lib/node_modules/pure-prompt/functionsβ: Permission denied
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] postinstall-link: `mkdir -p "$PURE_DEST" && ln -sf "$PWD/pure.zsh" "$PURE_DEST/prompt_pure_setup" && ln -sf "$PWD/async.zsh" "$PURE_DEST/async"`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] postinstall-link script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
βββββββββββββββββββββββββββββββββββββββββββββββββββββ
β npm update check failed β
β Try running with sudo or get access β
β to the local update config store via β
β sudo chown -R $USER:$(id -gn $USER) /root/.config β
βββββββββββββββββββββββββββββββββββββββββββββββββββββ
npm ERR! code ELIFECYCLE
npm ERR! errno 243
npm ERR! [email protected] postinstall: `PURE_DEST=/usr/local/share/zsh/site-functions npm run --silent postinstall-link && exit 0; PURE_DEST="$PWD/functions" npm run postinstall-link && npm run postinstall-fail-instructions`
npm ERR! Exit status 243
npm ERR!
npm ERR! Failed at the [email protected] postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2017-08-31T11_31_47_991Z-debug.log
@LitoMore are you installing as root (e.g. via sudo)? If so, that's probably the issue. Take a look at the issues I've linked to here: https://github.com/sindresorhus/pure/issues/341#issuecomment-326000184.
@mafredri Yes, is root.
Thanks.
Any update on this?
try this
npm install --global pure-prompt --allow-root --unsafe-perm=true
Closing due to age.
Most helpful comment
try this
npm install --global pure-prompt --allow-root --unsafe-perm=true