Skip to content

Commit

Permalink
fix: allow pushes to dev to generate a latest tag
Browse files Browse the repository at this point in the history
  • Loading branch information
wax911 committed Apr 28, 2024
1 parent af3c3f8 commit 7901b52
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions .github/workflows/deno-cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,16 +32,16 @@ jobs:
- name: Set Tag
id: set-tag
run: |
if [[ -z "${{ github.event.inputs.tag }}" && -z "${GITHUB_REF#refs/tags/}" ]]; then
echo "::set-output name=tag::latest"
if [[ -n "${{ github.event.inputs.tag }}" ]]; then
echo "::set-output name=tag::${{ github.event.inputs.tag }}"
elif [[ "${{ github.ref }}" =~ ^refs/tags/ ]]; then
echo "::set-output name=tag::${GITHUB_REF#refs/tags/}"
else
if [ -z "${{ github.event.inputs.tag }}" ]; then
echo "::set-output name=tag::${GITHUB_REF#refs/tags/}"
else
echo "::set-output name=tag::${{ github.event.inputs.tag }}"
fi
echo "::set-output name=tag::latest"
fi
- name: Show Generated Tag
run: |
echo "Tag: ${{ steps.set-tag.outputs.tag }}"
- name: Build and Push Docker Image
run: |
docker buildx create --use
Expand Down

0 comments on commit 7901b52

Please sign in to comment.