diff --git a/.github/workflows/flow-deploy-release-artifact.yaml b/.github/workflows/flow-deploy-release-artifact.yaml index f3695e70d..f6b5c0e40 100644 --- a/.github/workflows/flow-deploy-release-artifact.yaml +++ b/.github/workflows/flow-deploy-release-artifact.yaml @@ -87,6 +87,7 @@ jobs: needs: prepare-release with: commit-changes: true + version: ${{ needs.prepare-release.outputs.version }} secrets: GH_ACCESS_TOKEN: ${{ secrets.GH_ACCESS_TOKEN }} GH_ACCESS_GPG_KEY: ${{ secrets.GH_ACCESS_GPG_KEY }} @@ -104,6 +105,7 @@ jobs: with: token: ${{ secrets.GH_ACCESS_TOKEN }} fetch-depth: 0 + ref: ${{ needs.update-readme.outputs.commit-hash }} - name: Install GnuPG Tools run: | @@ -174,6 +176,7 @@ jobs: - name: Publish Semantic Release env: + commit: ${{ needs.update-readme.outputs.commit-hash }} NPM_TOKEN: ${{ secrets.NPM_TOKEN }} GITHUB_TOKEN: ${{ secrets.GH_ACCESS_TOKEN }} GIT_AUTHOR_NAME: ${{ secrets.GIT_USER_NAME }} diff --git a/.github/workflows/flow-update-readme.yaml b/.github/workflows/flow-update-readme.yaml index 4f3c4fa17..8866c445e 100644 --- a/.github/workflows/flow-update-readme.yaml +++ b/.github/workflows/flow-update-readme.yaml @@ -33,6 +33,14 @@ on: type: boolean required: false default: false + version: + description: "The version to set the app to during deploy/release" + type: string + required: false + outputs: + commit-hash: + description: "The commit hash for the updated README.md commit" + value: ${{ jobs.commit-readme.outputs.commit_hash }} push: paths: - '**/*.mjs' @@ -100,9 +108,14 @@ jobs: sudo apt-get install gettext-base - name: Update README.md + env: + VERSION: ${{ github.event.inputs.version }} run: | set -x npm install -g @hashgraph/solo + npm link + + [[ -n "${VERSION}" ]] && npm version ${VERSION} -f --no-git-tag-version which solo export SOLO_CLUSTER_NAME=solo @@ -178,7 +191,8 @@ jobs: git_commit_gpgsign: true - name: Commit README.md Changes - if : ${{ inputs.commit-changes }} + id: commit-readme + if : ${{ github.event.inputs.dry-run-enabled != 'true' && !cancelled() && !failure() && inputs.commit-changes }} uses: stefanzweifel/git-auto-commit-action@8621497c8c39c72f3e2a999a26b4ca1b5058a842 # v5.0.1 with: commit_message: "auto update README.md [skip ci]"