-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Updates staging workflow to use Gradle build instead of Eclipse-build
- Loading branch information
Showing
1 changed file
with
31 additions
and
37 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -21,54 +21,48 @@ jobs: | |
|
||
runs-on: ubuntu-latest | ||
|
||
#defaults: | ||
# run: | ||
# working-directory: ./.. | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
# Because of scheduled runs, by default run on default branch | ||
with: | ||
ref: staging | ||
path: workspace/clava | ||
|
||
- name: Cache ivy dependencies | ||
id: cache-nivy | ||
uses: actions/cache@v3 | ||
env: | ||
cache-name: cache-ivy-dependencies | ||
with: | ||
# ivy dependencies cache files are stored in `~/.ivy2` on Linux/macOS | ||
path: ~/.ivy2 | ||
key: ${{ runner.os }}-build-${{ env.cache-name }} | ||
|
||
- name: Set up JDK 17 | ||
uses: actions/setup-java@v3 | ||
uses: actions/setup-java@v4 | ||
with: | ||
java-version: '17' | ||
distribution: 'temurin' | ||
|
||
- name: Install build essentials and CMake | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install build-essential | ||
sudo apt-get install -y cmake | ||
- name: Generate build.xml | ||
run: | | ||
wget -q -N http://specs.fe.up.pt/tools/eclipse-build.jar | ||
java -jar eclipse-build.jar https://github.com/specs-feup/specs-java-libs https://github.com/specs-feup/lara-framework?commit=staging ./ | ||
wget -N -O /usr/share/ant/lib/ivy-2.5.0.jar specs.fe.up.pt/libs/ivy-2.5.0.jar | ||
- name: Build with Ant | ||
run: | | ||
ant -noinput -buildfile build.xml | ||
- 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 | ||
path: workspace/lara-framework | ||
ref: staging | ||
|
||
# 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 | ||
|
||
- name: List directory | ||
run: | | ||
echo "Current folder" | ||
ls | ||
- name: Publish Test Report | ||
uses: mikepenz/[email protected] | ||
if: always() # always run even if the previous step fails | ||
# Setting up gradle multi-project would be helpful | ||
- name: Build and test ClangAstParser | ||
working-directory: workspace/clava/ClangAstParser | ||
run: gradle build test | ||
- name: Build and test ClavaWeaver | ||
working-directory: workspace/clava/ClavaWeaver | ||
run: gradle build test | ||
|
||
- name: Publish Test Report | ||
uses: mikepenz/action-junit-report@v4 | ||
if: always() | ||
with: | ||
report_paths: '**/reports-eclipse-build/TEST-*.xml' | ||
report_paths: 'workspace/clava/**/build/test-results/test/TEST-*.xml' | ||
summary: true | ||
#exclude_sources: '' |