From 67f3b92df6b41e27e7601781f28925c9f9721897 Mon Sep 17 00:00:00 2001 From: glassk Date: Mon, 13 May 2024 23:03:05 +0900 Subject: [PATCH] [chore] improve version checking in release workflow --- .github/workflows/release.yml | 14 +++++++------- .vscode/settings.json | 3 --- 2 files changed, 7 insertions(+), 10 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 992b160..c2fdc56 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -14,13 +14,13 @@ jobs: with: fetch-depth: 0 - - name: Extract version from package.json - id: package_version - run: echo "::set-output name=version::$(grep '\"version\"' package.json | cut -d '\"' -f 4)" + - name: Check for version update in package.json + id: check_version + uses: EndBug/version-check@v2 - name: Push Git Tag run: | - TAG="v${{ steps.package_version.outputs.version }}" + TAG="v${{ steps.check_version.outputs.version }}" git tag $TAG git push origin $TAG @@ -29,14 +29,14 @@ jobs: uses: mindsers/changelog-reader-action@v2 with: validation_level: warn - version: ${{ steps.package_version.outputs.version }} + version: ${{ steps.check_version.outputs.version }} path: ./CHANGELOG.md - name: Create/update release uses: ncipollo/release-action@v1 with: - tag: v${{ steps.package_version.outputs.version }} - name: v${{ steps.package_version.outputs.version }} + tag: v${{ steps.check_version.outputs.version }} + name: v${{ steps.check_version.outputs.version }} body: ${{ steps.changelog_reader.outputs.changes }} allowUpdates: true token: ${{ secrets.GITHUB_TOKEN }} diff --git a/.vscode/settings.json b/.vscode/settings.json index 62a99ac..8b195c1 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -9,7 +9,4 @@ // Turn off tsc task auto detection since we have the necessary tasks as npm scripts "typescript.tsc.autoDetect": "off", "YOCO.includeFilePath": true, - "githubPullRequests.ignoredPullRequestBranches": [ - "dev" - ] }