Skip to content

Commit

Permalink
Repair ci - added get-previous tag job (#70)
Browse files Browse the repository at this point in the history
  • Loading branch information
Nikita-Smirnov-Exactpro authored Oct 2, 2023
1 parent 504dc15 commit 9c83266
Showing 1 changed file with 18 additions and 1 deletion.
19 changes: 18 additions & 1 deletion .github/workflows/dev-release-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,26 @@ jobs:
uses: th2-net/.github/.github/workflows/compound-prebuild-java-workflow.yml@main
with:
project-path: .
get-previous-tag:
name: Get previous tag
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 100
fetch-tags: true
- id: previous-tag
run: |
FOUND_TAG=$(git tag --list --sort=-version:refname '*.*.*-dev' | head --lines 1)
echo "result=$FOUND_TAG" >> "$GITHUB_OUTPUT"
[[ -z $(echo "$FOUND_TAG") ]] && { echo "No tag found..."; exit 1; } || { echo "Tag found: ${FOUND_TAG}"; }
outputs:
tag: ${{ steps.previous-tag.outputs.result }}
changes:
name: Collect changed files
runs-on: ubuntu-20.04
needs:
- get-previous-tag
outputs:
app: ${{ steps.filter.outputs.app }}
grpc: ${{ steps.filter.outputs.grpc }}
Expand All @@ -22,7 +39,7 @@ jobs:
- uses: dorny/paths-filter@v2
id: filter
with:
base: ${{ github.ref }}
base: ${{ needs.get-previous-tag.outputs.tag }}
filters: |
app:
- 'gradle.properties'
Expand Down

0 comments on commit 9c83266

Please sign in to comment.