From 049144826b2ec5f69486587034e5e0f5018865e0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Bispo?= Date: Mon, 12 Aug 2024 17:12:42 +0100 Subject: [PATCH] Removes lara-js workflow, adds main and staging --- .github/workflows/{lara-js.yml => main.yml} | 8 +-- .github/workflows/staging.yml | 77 +++++++++++++++++++++ 2 files changed, 81 insertions(+), 4 deletions(-) rename .github/workflows/{lara-js.yml => main.yml} (95%) create mode 100644 .github/workflows/staging.yml diff --git a/.github/workflows/lara-js.yml b/.github/workflows/main.yml similarity index 95% rename from .github/workflows/lara-js.yml rename to .github/workflows/main.yml index 02c0758..dec9592 100644 --- a/.github/workflows/lara-js.yml +++ b/.github/workflows/main.yml @@ -1,7 +1,7 @@ # This workflow will build a Java project with Ant # For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-ant -name: Java CI - Lara-JS +name: Java CI - Main on: push: @@ -33,7 +33,7 @@ jobs: with: repository: specs-feup/clava-benchmarks path: workspace/clava-benchmarks - ref: clava-js + ref: main - name: Set up JDK 17 uses: actions/setup-java@v4 @@ -51,14 +51,14 @@ jobs: uses: actions/checkout@v4 with: repository: specs-feup/lara-framework - ref: feature/lara-js + ref: master path: workspace/lara-framework - name: Check out Clava repo uses: actions/checkout@v4 with: repository: specs-feup/clava - ref: feature/clava-js + ref: master path: workspace/clava # Configure Gradle for optimal use in GitHub Actions, including caching of downloaded dependencies. diff --git a/.github/workflows/staging.yml b/.github/workflows/staging.yml new file mode 100644 index 0000000..4e04981 --- /dev/null +++ b/.github/workflows/staging.yml @@ -0,0 +1,77 @@ +# This workflow will build a Java project with Ant +# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-ant + +name: Java CI - Staging + +on: + push: + branches: [ main ] + pull_request: + branches: [ main ] + + # Daily at midnight + schedule: + - cron: '0 0 * * *' + +permissions: + checks: write + +jobs: + build: + + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + # Because of scheduled runs, by default run on default branch + with: + ref: main + path: workspace/clava-benchmarks-tests + + - name: Check out clava-benchmarks repo + uses: actions/checkout@v4 + with: + repository: specs-feup/clava-benchmarks + path: workspace/clava-benchmarks + ref: main + + - name: Set up JDK 17 + uses: actions/setup-java@v4 + with: + java-version: '17' + distribution: 'temurin' + + - name: Check out specs-java-libs repo + uses: actions/checkout@v4 + with: + repository: specs-feup/specs-java-libs + path: workspace/specs-java-libs + + - name: Check out lara-framework repo + uses: actions/checkout@v4 + with: + repository: specs-feup/lara-framework + ref: staging + path: workspace/lara-framework + + - name: Check out Clava repo + uses: actions/checkout@v4 + with: + repository: specs-feup/clava + ref: staging + path: workspace/clava + + # Configure Gradle for optimal use in GitHub Actions, including caching of downloaded dependencies. + # See: https://github.com/gradle/actions/blob/main/setup-gradle/README.md + - name: Setup Gradle + uses: gradle/actions/setup-gradle@417ae3ccd767c252f5661f1ace9f835f9654f2b5 # v3.1.0 + + # Setting up gradle multi-project would be helpful + - name: InstallDist Clava + working-directory: workspace/clava/ClavaWeaver + run: gradle installDist + + - name: Execute 'all-benches.clava' + working-directory: workspace/clava-benchmarks-tests + run: | + ../clava/ClavaWeaver/build/install/ClavaWeaver/bin/ClavaWeaver --config ./all-benches/all-benches.clava