fix(updateScript): don't replace version if null
All checks were successful
Discord / discord commits (push) Has been skipped
All checks were successful
Discord / discord commits (push) Has been skipped
This commit is contained in:
parent
3039f823c9
commit
781177c396
1 changed files with 6 additions and 6 deletions
|
@ -4,13 +4,13 @@
|
|||
|
||||
latest=$(npm outdated --json | jq -r '.["some-sass-language-server"]["latest"]' || true)
|
||||
|
||||
echo "$latest"
|
||||
if [[ "$latest" != "null" ]]; then
|
||||
sed -i "s#\"some-sass-language-server\": \"[^\"]*\"#\"some-sass-language-server\": \"$latest\"#" ./package.json
|
||||
|
||||
sed -i "s#\"some-sass-language-server\": \"[^\"]*\"#\"some-sass-language-server\": \"$latest\"#" ./package.json
|
||||
npm update
|
||||
|
||||
npm update
|
||||
npm_hash="$(prefetch-npm-deps ./package-lock.json)"
|
||||
|
||||
npm_hash="$(prefetch-npm-deps ./package-lock.json)"
|
||||
|
||||
sed -i "s#npmDepsHash = .*#npmDepsHash = \"$npm_hash\";#" ./default.nix
|
||||
sed -i "s#npmDepsHash = .*#npmDepsHash = \"$npm_hash\";#" ./default.nix
|
||||
fi
|
||||
''
|
||||
|
|
Loading…
Reference in a new issue