From f97a4078d80bca790cd68e93a88da11a056ac0a3 Mon Sep 17 00:00:00 2001 From: Peter Murray <681306+peter-murray@users.noreply.github.com> Date: Wed, 3 Jul 2024 10:07:15 +0000 Subject: [PATCH] Updating actions versions --- .github/release.yml | 123 ---------------------------------- .github/workflows/release.yml | 2 +- 2 files changed, 1 insertion(+), 124 deletions(-) delete mode 100644 .github/release.yml diff --git a/.github/release.yml b/.github/release.yml deleted file mode 100644 index c54697e..0000000 --- a/.github/release.yml +++ /dev/null @@ -1,123 +0,0 @@ -name: Release - -run-name: Release ${{ inputs.version }} - -on: - workflow_dispatch: - inputs: - version: - type: string - required: true - - -jobs: - build_and_test: - name: Build and test - - runs-on: ubuntu-22.04 - - steps: - - name: Checkout - uses: actions/checkout@v4 - - - name: Setup Node.js - uses: actions/setup-node@v4 - with: - node-version: 20 - cache: npm - - - name: Build and Test - run: | - npm ci - npm run test --if-present - npm run build --if-present - npm run build-exe --if-present - - - validate_version: - name: Validate version number - runs-on: ubuntu-22.04 - - steps: - - name: Process version number as SemVer - id: semver - uses: peter-murray/semver-data-action@v1 - with: - version: ${{ inputs.version }} - - - release: - name: Release - - needs: - - validate_version - - build_and_test - - runs-on: ubuntu-22.04 - - steps: - - name: Process version number as SemVer - id: semver - uses: peter-murray/semver-data-action@v1 - with: - version: ${{ inputs.version }} - - - name: Checkout - uses: actions/checkout@v4 - - - name: Set git user - run: | - git config user.name github-actions - git config user.email github-actions@github.com - - - name: Setup Node.js - uses: actions/setup-node@v4 - with: - node-version: 20 - cache: npm - - - name: Version application - run: | - npm version ${{ steps.semver.outputs.semver }} - - - name: Build - run: | - npm ci - npm run build --if-present - npm run build-exe --if-present - - - name: Check that build is clean - id: clean_build - continue-on-error: true - run: | - git diff --exit-code - - - name: Update release - if: steps.clean_build.outcome == 'failure' - run: | - git add . - git commit -m "chore: Updating release files" - - - name: Update tags - if: steps.semver.outputs.isPreRelease == 'false' - run: | - git tag "v${{ steps.semver.outputs.semver }}" --force - git tag "v${{ steps.semver.outputs.major }}" --force - git tag "v${{ steps.semver.outputs.major }}.${{ steps.semver.outputs.minor }}" --force - git tag "v${{ steps.semver.outputs.major }}.${{ steps.semver.outputs.minor }}.${{ steps.semver.outputs.patch }}" --force - - git push origin ${{ github.ref_name }} - git push origin --tags --force - - - name: Attach CLI artifacts - uses: actions/upload-artifact@v3 - with: - name: cli - path: cli - - - name: Create release - uses: ncipollo/release-action@v1.13.0 - with: - artifacts: cli/* - prerelease: ${{ steps.semver.outputs.isPreRelease }} - tag: v${{ steps.semver.outputs.semver }} diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 223a081..d2c1cdf 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -113,7 +113,7 @@ jobs: git push origin --tags --force - name: Attach CLI artifacts - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: cli path: cli