From b279d930c46af8be22ed7cf9ffca6488c094ff88 Mon Sep 17 00:00:00 2001 From: yalh76 Date: Wed, 30 Jan 2019 18:31:23 +0100 Subject: [PATCH] Fix sudo user npm --- scripts/install | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/scripts/install b/scripts/install index 7977ed7..383b80b 100644 --- a/scripts/install +++ b/scripts/install @@ -176,14 +176,13 @@ chown -R $app: $final_path pushd $final_path ynh_use_nodejs -sudo env PATH=$PATH:$nodejs_path npm -u $app -sudo env PATH=$PATH:$nodejs_path npm install "graphql@^0.13.1" -u $app -sudo env PATH=$PATH:$nodejs_path npm install "acorn@^6.0.0" -u $app -sudo env PATH=$PATH:$nodejs_path npm install "babel-core@>=6.0.20" -u $app -sudo env PATH=$PATH:$nodejs_path npm install "eslint@>=5.0.0" -u $app -sudo env PATH=$PATH:$nodejs_path npm install -u $app -sudo env PATH=$PATH:$nodejs_path npm audit fix -u $app -sudo env PATH=$PATH:$nodejs_path npm run build -u $app +sudo -u $app env PATH=$PATH:$nodejs_path npm install "graphql@^0.13.1" +sudo -u $app env PATH=$PATH:$nodejs_path npm install "acorn@^6.0.0" +sudo -u $app env PATH=$PATH:$nodejs_path npm install "babel-core@>=6.0.20" +sudo -u $app env PATH=$PATH:$nodejs_path npm install "eslint@>=5.0.0" +sudo -u $app env PATH=$PATH:$nodejs_path npm install +sudo -u $app env PATH=$PATH:$nodejs_path npm audit fix +sudo -u $app env PATH=$PATH:$nodejs_path npm run build popd