From 0e41931348086c1044aa263d93da8d3426c01f07 Mon Sep 17 00:00:00 2001 From: "t.momose" Date: Tue, 15 Oct 2024 09:59:42 +0900 Subject: [PATCH 1/2] Use fetch-gh-package-latest-snapshot-version in test-snapshot-liquibase.yml --- .github/workflows/test-snapshot-liquibase.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/test-snapshot-liquibase.yml b/.github/workflows/test-snapshot-liquibase.yml index a87311e1..37d21038 100644 --- a/.github/workflows/test-snapshot-liquibase.yml +++ b/.github/workflows/test-snapshot-liquibase.yml @@ -28,12 +28,12 @@ jobs: - name: Fetch latest SNAPSHOT version from GitHub Packages id: liquibase-core-latest-snapshot-version - run: | - LATEST_VERSION=$(curl -s -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" \ - https://api.github.com/orgs/liquibase/packages/maven/org.liquibase.liquibase-core/versions | \ - jq -r '.[0].name') - echo "Latest version is $LATEST_VERSION" - echo "version=$LATEST_VERSION" >> $GITHUB_OUTPUT + uses: momosetkn/fetch-gh-package-latest-snapshot-version@main + with: + org: liquibase + packageType: maven + packageName: org.liquibase.liquibase-core + githubToken: ${{ secrets.GITHUB_TOKEN }} - name: Configure Gradle for GitHub Packages run: | From 56020cfdb629a2b57af85cf55c54f83341d846d3 Mon Sep 17 00:00:00 2001 From: "t.momose" Date: Tue, 15 Oct 2024 10:08:47 +0900 Subject: [PATCH 2/2] Fix for windows --- .github/workflows/test-snapshot-liquibase.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test-snapshot-liquibase.yml b/.github/workflows/test-snapshot-liquibase.yml index 37d21038..74a71e20 100644 --- a/.github/workflows/test-snapshot-liquibase.yml +++ b/.github/workflows/test-snapshot-liquibase.yml @@ -37,8 +37,8 @@ jobs: - name: Configure Gradle for GitHub Packages run: | - echo "gpr.user=${{ github.actor }}" >> ~/.gradle/gradle.properties - echo "gpr.token=${{ secrets.GITHUB_TOKEN }}" >> ~/.gradle/gradle.properties + echo "gpr.user=${{ github.actor }}" >> gradle.properties + echo "gpr.token=${{ secrets.GITHUB_TOKEN }}" >> gradle.properties - name: Test with latest liquibase SNAPSHOT version run: |