mirror of
https://github.com/ntop/n2n.git
synced 2024-09-20 00:51:10 +02:00
Only trigger release process on annotated tags
Annotated tags are meant for releases while lightweight tags are meant for private or temporary object labels. For this reason, we should not trigger the automatic release actions unless we have an annotated tag.
This commit is contained in:
parent
b9eac35c00
commit
71521b81d8
20
.github/workflows/tests.yml
vendored
20
.github/workflows/tests.yml
vendored
|
@ -479,8 +479,12 @@ jobs:
|
||||||
name: binaries
|
name: binaries
|
||||||
path: binaries
|
path: binaries
|
||||||
|
|
||||||
upload_release:
|
# Given the clearly documented use of annotated tags to signal releases,
|
||||||
name: Upload Release Assets
|
# it seems strange that there is no simple way to trigger actions if the
|
||||||
|
# tag is annotated. So we need to jump through some hoops.
|
||||||
|
#
|
||||||
|
get_tagtype:
|
||||||
|
name: Get the type of Tag
|
||||||
if: startsWith(github.ref, 'refs/tags/')
|
if: startsWith(github.ref, 'refs/tags/')
|
||||||
needs:
|
needs:
|
||||||
- package_dpkg
|
- package_dpkg
|
||||||
|
@ -491,6 +495,18 @@ jobs:
|
||||||
- binaries_linux_crosscompile
|
- binaries_linux_crosscompile
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Set variable
|
||||||
|
run: |
|
||||||
|
echo '::set-output name=TAGTYPE::$(git cat-file -t $GITHUB_REF)'
|
||||||
|
|
||||||
|
upload_release:
|
||||||
|
name: Upload Release Assets
|
||||||
|
if: steps.get_tagtype.outputs.TAGTYPE == 'tag'
|
||||||
|
needs:
|
||||||
|
- get_tagtype
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Fetch all Artifacts
|
- name: Fetch all Artifacts
|
||||||
uses: actions/download-artifact@v2
|
uses: actions/download-artifact@v2
|
||||||
|
|
Loading…
Reference in New Issue
Block a user