Use `fetch-tags` option in release workflows (#1025)

## Changes

The manual unshallow step is superfluous and can be done as part of the
`actions/checkout` step.

Companion to #1022.

## Tests

Manual trigger of the snapshot build workflow.
This commit is contained in:
Pieter Noordhuis 2023-11-29 16:24:01 +01:00 committed by GitHub
parent 09991da534
commit f2969e91bd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 8 deletions

View File

@ -14,9 +14,9 @@ jobs:
steps:
- name: Checkout repository and submodules
uses: actions/checkout@v4
- name: Unshallow
run: git fetch --prune --unshallow
with:
fetch-depth: 0
fetch-tags: true
- name: Setup Go
uses: actions/setup-go@v4
@ -56,7 +56,7 @@ jobs:
- name: Update snapshot tag
# Snapshot release may only be updated for commits to the main branch.
# if: github.ref == 'refs/heads/main'
if: github.ref == 'refs/heads/main'
run: |
git tag snapshot
@ -65,7 +65,7 @@ jobs:
- name: Update snapshot release
# Snapshot release may only be updated for commits to the main branch.
# if: github.ref == 'refs/heads/main'
if: github.ref == 'refs/heads/main'
uses: softprops/action-gh-release@v1
with:

View File

@ -15,9 +15,9 @@ jobs:
steps:
- name: Checkout repository and submodules
uses: actions/checkout@v4
- name: Unshallow
run: git fetch --prune --unshallow
with:
fetch-depth: 0
fetch-tags: true
- name: Setup Go
uses: actions/setup-go@v4