-
Notifications
You must be signed in to change notification settings - Fork 371
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Configuration - Fix workflow echo statements and update artifact down…
…load path for clarity
- Loading branch information
Showing
1 changed file
with
4 additions
and
50 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 |
---|---|---|
|
@@ -20,37 +20,14 @@ jobs: | |
runs-on: windows-2022 | ||
|
||
steps: | ||
- name: Checkout repository | ||
uses: actions/[email protected] | ||
|
||
- name: Set up MSVC | ||
uses: ilammy/[email protected] | ||
with: | ||
arch: x64 | ||
|
||
- name: Download and extract 3rdparty dependencies | ||
run: | | ||
Invoke-WebRequest -Uri https://github.com/Open-Cascade-SAS/OCCT/releases/download/V7_8_0/3rdparty-vc14-64.zip -OutFile 3rdparty-vc14-64.zip | ||
Expand-Archive -Path 3rdparty-vc14-64.zip -DestinationPath . | ||
Remove-Item 3rdparty-vc14-64.zip | ||
shell: pwsh | ||
|
||
- name: Download and extract test data | ||
run: | | ||
cd data | ||
Invoke-WebRequest -Uri https://github.com/Open-Cascade-SAS/OCCT/releases/download/V7_8_0/opencascade-dataset-7.8.0.zip -OutFile opencascade-dataset-7.8.0.zip | ||
Expand-Archive -Path opencascade-dataset-7.8.0.zip -DestinationPath . | ||
Remove-Item opencascade-dataset-7.8.0.zip | ||
shell: pwsh | ||
|
||
- name: Get latest workflow run ID from target branch | ||
id: get_run_id | ||
run: | | ||
set workflow_name="Build and Test OCCT on Multiple Platforms" | ||
set target_branch=${{ github.event.pull_request.base.ref }} | ||
echo Fetching latest run ID for workflow: %workflow_name% on branch: %target_branch% | ||
echo Fetching latest run ID for workflow: "%workflow_name%" on branch: "%target_branch%" | ||
curl -s -H "Accept: application/vnd.github.v3+json" "https://api.github.com/repos/${{ github.repository }}/actions/runs?branch=%target_branch%&status=success&event=pull_request" > response.json | ||
for /F "tokens=*" %%i in ('jq -r ".workflow_runs[] | select(.name==%workflow_name%) | .id" response.json ^| head -n 1') do set latest_run_id=%%i | ||
for /F "tokens=*" %%i in ('jq -r ".workflow_runs[] | select(.name==\"%workflow_name%\") | .id" response.json ^| head -n 1') do set latest_run_id=%%i | ||
echo Latest run ID: %latest_run_id% | ||
echo latest_run_id=%latest_run_id% >> %GITHUB_ENV% | ||
shell: cmd | ||
|
@@ -78,28 +55,6 @@ jobs: | |
runs-on: ubuntu-24.04 | ||
|
||
steps: | ||
- name: Checkout repository | ||
uses: actions/[email protected] | ||
|
||
- name: Install dependencies | ||
run: sudo apt-get update && sudo apt-get install -y tcl-dev tk-dev cmake clang make libbtbb-dev libx11-dev libglu1-mesa-dev tcllib tcl-thread tcl libvtk9-dev libopenvr-dev libdraco-dev libfreeimage-dev libegl1-mesa-dev libgles2-mesa-dev libfreetype-dev | ||
|
||
- name: Install Xvfb and Mesa | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install -y xvfb mesa-utils libgl1-mesa-dri | ||
- name: Start Xvfb | ||
run: Xvfb :99 -screen 0 1920x1080x24 & | ||
|
||
- name: Set DISPLAY environment variable | ||
run: echo "DISPLAY=:99" >> $GITHUB_ENV | ||
|
||
- name: Download test data | ||
run: | | ||
cd data | ||
wget https://github.com/Open-Cascade-SAS/OCCT/releases/download/V7_8_0/opencascade-dataset-7.8.0.tar.xz | ||
tar -xf opencascade-dataset-7.8.0.tar.xz | ||
|
||
- name: Get latest workflow run ID from target branch | ||
id: get_run_id | ||
|
@@ -117,17 +72,16 @@ jobs: | |
uses: actions/[email protected] | ||
with: | ||
name: results-linux-clang-x64 | ||
path: install/bin | ||
path: install/bin/results-target | ||
github-token: ${{ secrets.GITHUB_TOKEN }} | ||
run-id: ${{ env.latest_run_id }} | ||
|
||
- name: Compare test results | ||
run: | | ||
cd install | ||
cd bin | ||
ls -R | ||
for dir in results/*; do export RESULTS_SUBFOLDER=$dir; done | ||
for dir in results-linux-clang-x64/*; do export RESULTS_LINUX_CLANG_SUBFOLDER=$dir; done | ||
for dir in results-target/*; do export RESULTS_LINUX_CLANG_SUBFOLDER=$dir; done | ||
echo $RESULTS_SUBFOLDER | ||
echo $RESULTS_LINUX_CLANG_SUBFOLDER | ||
shell: bash |