mirror of
https://github.com/jesseduffield/lazygit.git
synced 2025-05-11 04:15:48 +02:00
Fix issue where latest tag wasn't obtained early enough in auto-release script
This commit is contained in:
parent
dcf264b182
commit
269d89ea51
1 changed files with 8 additions and 3 deletions
11
.github/workflows/release.yml
vendored
11
.github/workflows/release.yml
vendored
|
@ -16,6 +16,12 @@ jobs:
|
||||||
with:
|
with:
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
|
|
||||||
|
- name: Get Latest Tag
|
||||||
|
run: |
|
||||||
|
latest_tag=$(git describe --tags $(git rev-list --tags --max-count=1) || echo "v0.0.0")
|
||||||
|
echo "Latest tag: $latest_tag"
|
||||||
|
echo "latest_tag=$latest_tag" >> $GITHUB_ENV
|
||||||
|
|
||||||
- name: Check for changes since last release
|
- name: Check for changes since last release
|
||||||
run: |
|
run: |
|
||||||
if [ -z "$(git diff --name-only ${{ env.latest_tag }})" ]; then
|
if [ -z "$(git diff --name-only ${{ env.latest_tag }})" ]; then
|
||||||
|
@ -53,9 +59,8 @@ jobs:
|
||||||
|
|
||||||
- name: Calculate next version
|
- name: Calculate next version
|
||||||
run: |
|
run: |
|
||||||
latest_tag=$(git describe --tags $(git rev-list --tags --max-count=1) || echo "v0.0.0")
|
echo "Latest tag: ${{ env.latest_tag }}"
|
||||||
echo "Latest tag: $latest_tag"
|
IFS='.' read -r major minor patch <<< "${{ env.latest_tag }}"
|
||||||
IFS='.' read -r major minor patch <<< "$latest_tag"
|
|
||||||
new_minor=$((minor + 1))
|
new_minor=$((minor + 1))
|
||||||
new_tag="$major.$new_minor.0"
|
new_tag="$major.$new_minor.0"
|
||||||
echo "New tag: $new_tag"
|
echo "New tag: $new_tag"
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue