From d6fa2e0af1565d4eeced0b676c41a65265fed4a2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20Ho=C3=9F?= Date: Sat, 30 Mar 2024 07:52:24 +0100 Subject: [PATCH] improve release workflow MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Sebastian Hoß --- .github/workflows/release.yml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 3be697946..50481127a 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -18,9 +18,14 @@ jobs: uses: actions/checkout@v4 with: fetch-depth: 0 + - id: last_release + name: Fetch last release info + run: echo "tag=$(gh release view --json tagName --jq '.tagName')" >> $GITHUB_OUTPUT + env: + GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} - id: commits name: Count Commits - run: echo "count=$(git rev-list --count HEAD --since='last Monday' -- internal)" >> $GITHUB_OUTPUT + run: echo "count=$(git rev-list --count ${{ steps.last_release.outputs.tag }}..HEAD)" >> $GITHUB_OUTPUT - id: release name: Create Release Version if: steps.commits.outputs.count > 0