From 55c8da129ef440736045d7c3f043db553142af03 Mon Sep 17 00:00:00 2001 From: Amit Dhamu Date: Fri, 13 Jan 2023 12:01:44 +0000 Subject: [PATCH] Migrate to GITHUB_OUTPUT --- .github/workflows/ci.yml | 16 ++++++++-------- package.json | 2 +- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index bda7989..aa6bcdc 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -16,10 +16,10 @@ jobs: - name: Set Environment Variables run: | - echo ::set-output name=NODE_VERSION::$(cat .nvmrc) - echo ::set-output name=CURRENT_VERSION::$(cat package.json | jq -r '.version') - echo ::set-output name=PUBLISHED_VERSION::$(npm view arge version) - echo ::set-output name=BRANCH::${GITHUB_REF##*/} + echo "NODE_VERSION=$(cat .nvmrc)" >> $GITHUB_OUTPUT + echo "NEW_VERSION=$(cat package.json | jq -r '.version')" >> $GITHUB_OUTPUT + echo "PUBLISHED_VERSION=$(npm view arge version)" >> $GITHUB_OUTPUT + echo "BRANCH=${GITHUB_REF##*/}" >> $GITHUB_OUTPUT id: env_vars - name: Install Node.js ${{ steps.env_vars.outputs.NODE_VERSION }} @@ -63,15 +63,15 @@ jobs: env: GITHUB_TOKEN: ${{ secrets.PAT }} with: - tag_name: ${{ steps.env_vars.outputs.CURRENT_VERSION }} - release_name: ${{ steps.env_vars.outputs.CURRENT_VERSION }} - body: "**Full Changelog**: https://github.com/adhamu/arge/compare/${{ steps.env_vars.outputs.PUBLISHED_VERSION }}...${{ steps.env_vars.outputs.CURRENT_VERSION }}" + tag_name: ${{ steps.env_vars.outputs.NEW_VERSION }} + release_name: ${{ steps.env_vars.outputs.NEW_VERSION }} + body: "**Full Changelog**: https://github.com/adhamu/arge/compare/${{ steps.env_vars.outputs.PUBLISHED_VERSION }}...${{ steps.env_vars.outputs.NEW_VERSION }}" draft: false prerelease: false - name: Publish to Registry run: | - pkg_version=${{ steps.env_vars.outputs.CURRENT_VERSION }} + pkg_version=${{ steps.env_vars.outputs.NEW_VERSION }} branch=${{ steps.env_vars.outputs.BRANCH }} if [[ $branch != "main" ]]; then diff --git a/package.json b/package.json index e65afd6..7e6904b 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "arge", - "version": "1.3.0", + "version": "1.4.0", "description": "A simple utility to parse command line arguments and flags", "keywords": [ "argv",