From 31cd4af29bf3a04fa91aa0435899ba41b27fd83f Mon Sep 17 00:00:00 2001 From: Luis Antonio Obis Aparicio Date: Tue, 4 Jul 2023 13:16:20 +0200 Subject: [PATCH] update package-lock.json automatically --- .github/workflows/publish.yml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 36cd7ac..cc31dd5 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -14,6 +14,10 @@ jobs: fetch-depth: 0 token: ${{ secrets.PUSH_GITHUB_TOKEN }} + - uses: actions/setup-node@v3 + with: + node-version: 18 + - name: Update Version to Release Tag run: | # Extract the release tag number @@ -29,10 +33,13 @@ jobs: sed -i "s/\"version\": \".*\"/\"version\": \"$TAG\"/" bindings/nodejs/nodered/package.json sed -i "s/\"hvps\": \".*\"/\"hvps\": \"$TAG\"/" bindings/nodejs/nodered/package.json + # Update the package.lock for the nodered node + npm install --prefix bindings/nodejs/nodered + # Commit and push changes git config --local user.name "Luis Antonio Obis Aparicio" git config --local user.email "luis.antonio.obis@gmail.com" - git add src/hvps/version.py bindings/nodejs/hvps/package.json bindings/nodejs/nodered/package.json + git add src/hvps/version.py bindings/nodejs/hvps/package.json bindings/nodejs/nodered/package.json bindings/nodejs/nodered/package-lock.json git commit -m "Update version to $TAG" git push origin HEAD:main