🐊 Fix build and code review comments #123
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Build | |
| on: | |
| push: | |
| branches: | |
| - main | |
| pull_request: | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| - name: Set up JDK 17 | |
| uses: actions/setup-java@v4 | |
| with: | |
| java-version: '17' | |
| distribution: 'temurin' | |
| cache: gradle | |
| - name: Publish to Maven Local | |
| run: ./gradlew publishToMavenLocal :techdebt-gradle-plugin:publishToMavenLocal --stacktrace -Pskip.signing | |
| - name: Build with Gradle | |
| run: ./gradlew build | |
| - name: Verify Artifacts | |
| run: | | |
| GROUP_PATH="io/github/igorescodro" | |
| VERSION=$(grep "techdebt =" gradle/libs.versions.toml | cut -d'"' -f2) | |
| REPO_PATH="$HOME/.m2/repository/$GROUP_PATH" | |
| echo "Checking for artifacts in $REPO_PATH (Version: $VERSION)" | |
| # Check annotations | |
| ls $REPO_PATH/techdebt-annotations/$VERSION/techdebt-annotations-$VERSION.jar | |
| ls $REPO_PATH/techdebt-annotations/$VERSION/techdebt-annotations-$VERSION.pom | |
| # Check processor | |
| ls $REPO_PATH/techdebt-processor/$VERSION/techdebt-processor-$VERSION.jar | |
| ls $REPO_PATH/techdebt-processor/$VERSION/techdebt-processor-$VERSION.pom |