diff --git a/.github/workflows/create_release.yml b/.github/workflows/create_release.yml index ec7c0af..354f881 100644 --- a/.github/workflows/create_release.yml +++ b/.github/workflows/create_release.yml @@ -44,12 +44,12 @@ jobs: VERSION='${{ inputs.version }}' INCR='${{ inputs.increment }}' if [[ "$MODE" == "explicit" && -z "$VERSION" ]]; then - echo "❌ mode=explicit requires 'version' (e.g., 1.3-alpha)."; exit 1 + echo "? mode=explicit requires 'version' (e.g., 1.3-alpha)."; exit 1 fi if [[ "$MODE" == "bump" && -z "$INCR" ]]; then - echo "❌ mode=bump requires 'increment' (major|minor|patch)."; exit 1 + echo "? mode=bump requires 'increment' (major|minor|patch)."; exit 1 fi - echo "✅ inputs look good." + echo "? inputs look good." set-version: needs: validate-inputs diff --git a/.github/workflows/format.yml b/.github/workflows/format.yml index a428f7d..b42573a 100644 --- a/.github/workflows/format.yml +++ b/.github/workflows/format.yml @@ -8,7 +8,7 @@ on: branches: [main, develop] workflow_run: - workflows: [Create Prerelease, Create Release] + workflows: [Create Release] types: [requested] permissions: diff --git a/.github/workflows/pack_publish.yml b/.github/workflows/pack_publish.yml index 61ba60d..8ed5e72 100644 --- a/.github/workflows/pack_publish.yml +++ b/.github/workflows/pack_publish.yml @@ -8,8 +8,8 @@ permissions: contents: write pull-requests: write packages: write - statuses: write - + statuses: write + jobs: set-config: uses: Stillpoint-Software/shared-workflows/.github/workflows/determine_build_configuration.yml@main @@ -18,17 +18,26 @@ jobs: target_branch: ${{ github.event.release.target_commitish }} override_build_configuration: '' prerelease: ${{ github.event.release.prerelease }} # true/false from the release - - publish: + + tests: needs: set-config + uses: Stillpoint-Software/shared-workflows/.github/workflows/run_tests.yml@main + with: + branch: ${{ github.event.release.target_commitish }} + solution_name: ${{ vars.SOLUTION_NAME }} + + publish: + needs: [set-config, tests] uses: Stillpoint-Software/shared-workflows/.github/workflows/pack_and_publish.yml@main with: build_configuration: ${{ needs.set-config.outputs.build_configuration }} secrets: NUGET_API_KEY: ${{ secrets.NUGET_API_KEY }} + result: - needs: [publish] + needs: [publish, tests] if: always() runs-on: ubuntu-latest steps: + - run: echo "Tests result = ${{ needs.tests.result }}" - run: echo "Pack & Publish result = ${{ needs.publish.result }}" diff --git a/.github/workflows/run_tests.yml b/.github/workflows/run_tests.yml index 9efc51d..f234a86 100644 --- a/.github/workflows/run_tests.yml +++ b/.github/workflows/run_tests.yml @@ -2,7 +2,7 @@ name: Run Tests on: workflow_run: - workflows: [Create Prerelease, Create Release] + workflows: [Create Release] types: [requested] branches: [main, develop] workflow_dispatch: