diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml index 38d765a..3956347 100644 --- a/.github/workflows/maven.yml +++ b/.github/workflows/maven.yml @@ -12,15 +12,21 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 - - name: Set up JDK 21 - uses: actions/setup-java@v3 + - uses: actions/checkout@v4 + + - name: Set up GraalVM + uses: graalvm/setup-graalvm@v1 with: java-version: '21' - distribution: 'temurin' - cache: maven + distribution: 'graalvm' + github-token: ${{ secrets.GITHUB_TOKEN }} + cache: 'maven' + - name: Build with Maven run: mvn -B package --file pom.xml - name: Test with Maven run: mvn test --file pom.xml + + - name: Build Native Image + run: mvn -Pnative native:compile --file pom.xml diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 62ae017..5af0e3d 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -13,14 +13,15 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - - name: Set up JDK 21 - uses: actions/setup-java@v3 + - name: Set up GraalVM + uses: graalvm/setup-graalvm@v1 with: java-version: '21' - distribution: 'temurin' - cache: maven + distribution: 'graalvm' + github-token: ${{ secrets.GITHUB_TOKEN }} + cache: 'maven' - name: Extract version from pom.xml id: get_version @@ -31,6 +32,9 @@ jobs: - name: Build with Maven run: mvn -B package --file pom.xml + + - name: Build Native Image + run: mvn -Pnative native:compile --file pom.xml - name: Create Release uses: softprops/action-gh-release@v1 @@ -43,7 +47,15 @@ jobs: Educational Git-like version control system ### Installation - Download the JAR file and run: + Download the native binary for your platform or the JAR file: + + **Native Binary (Linux):** + ```bash + chmod +x minigit + ./minigit + ``` + + **JAR File:** ```bash java -jar minigit-${{ steps.get_version.outputs.version }}.jar ``` @@ -56,5 +68,6 @@ jobs: - `status` - Check repository status files: | target/minigit-${{ steps.get_version.outputs.version }}.jar + target/minigit draft: false prerelease: false