@@ -24,10 +24,6 @@ permissions:
2424 contents : write
2525 deployments : write
2626
27- env :
28- CONAN_LOGIN_USERNAME : ${{ secrets.CONAN_USER }}
29- CONAN_PASSWORD : ${{ secrets.CONAN_PASS }}
30-
3127# TODO: Make cura-workflows/benchmark.yml generic enough to fit the gcodeanalyzer benchmark
3228
3329jobs :
@@ -47,24 +43,14 @@ jobs:
4743 name : Run GCodeAnalyzer on the engine
4844 runs-on : ubuntu-latest
4945 steps :
50- - name : Checkout repo
51- uses : actions/checkout@v4
52- if : ${{ github.event.pull_request.head.repo.full_name == github.repository }}
46+ - name : Setup the build environment
47+ # FIXME: use main once merged
48+ uses : ultimaker/cura-workflows/. github/actions/setup-build-environment@CURA-11622_conan_v2
5349 with :
54- path : ' CuraEngine'
55- fetch-depth : 1
56- ref : ${{ github.head_ref }}
57-
58- - name : Checkout repo PR
59- uses : actions/checkout@v4
60- if : ${{ github.event.pull_request.head.repo.full_name != github.repository }}
61- with :
62- path : ' CuraEngine'
63- fetch-depth : 1
64- ref : ${{ github.base_ref }}
50+ install_system_dependencies : true
6551
6652 - name : Checkout GCodeAnalyzer
67- uses : actions/checkout@v3
53+ uses : actions/checkout@v4
6854 with :
6955 repository : ' Ultimaker/GCodeAnalyzer'
7056 ref : ' main'
@@ -73,95 +59,31 @@ jobs:
7359 token : ${{ secrets.CURA_BENCHMARK_PAT }}
7460
7561 - name : Checkout Test Models
76- uses : actions/checkout@v3
62+ uses : actions/checkout@v4
7763 with :
7864 repository : ' Ultimaker/NightlyTestModels'
7965 ref : ' main'
8066 path : ' NightlyTestModels'
8167 fetch-depth : 1
8268 token : ${{ secrets.GITHUB_TOKEN }}
8369
84- - name : Sync pip requirements
85- run : curl -O https://raw.githubusercontent.com/Ultimaker/cura-workflows/main/.github/workflows/requirements-runner.txt
86- working-directory : CuraEngine/.github/workflows
87-
88- - name : Setup Python and pip
89- uses : actions/setup-python@v4
90- with :
91- python-version : 3.11.x
92- cache : pip
93- cache-dependency-path : CuraEngine/.github/workflows/requirements-runner.txt
94-
95- - name : Install Python requirements and Create default Conan profile
96- run : |
97- pip install -r CuraEngine/.github/workflows/requirements-runner.txt
98- pip install wheel numpy pandas python-dateutil pytz six
99- pip install git+https://github.com/ultimaker/libcharon@CURA-9495_analyzer_requisites#egg=charon
100- pip install pytest pytest-benchmark
101-
102- - name : Install Linux system requirements for building
103- run : |
104- mkdir runner_scripts
105- cd runner_scripts
106- curl -O https://raw.githubusercontent.com/Ultimaker/cura-workflows/main/runner_scripts/ubuntu_setup.sh
107- chmod +x ubuntu_setup.sh
108- sudo ./ubuntu_setup.sh
109-
110- - name : Setup pipeline caches
111- run : |
112- mkdir -p /home/runner/.conan/downloads
113- mkdir -p /home/runner/.conan/data
114-
115- - name : Create default Conan profile
116- run : conan profile new default --detect
117-
118- - name : Get Conan configuration
119- run : |
120- conan config install https://github.com/Ultimaker/conan-config.git
121- conan config install https://github.com/Ultimaker/conan-config.git -a "-b runner/${{ runner.os }}/${{ runner.arch }}"
122-
123- - name : Cache Conan packages
124- uses : actions/cache@v3
125- with :
126- path : /home/runner/.conan/data
127- key : ${{ runner.os }}-conan-data-${{ github.run_id }}
128- restore-keys : |
129- ${{ runner.os }}-conan-data-
130-
131- - name : Cache Conan downloads
132- uses : actions/cache@v3
133- with :
134- path : /home/runner/.conan/downloads
135- key : ${{ runner.os }}-conan-downloads-${{ github.run_id }}
136- restore-keys : |
137- ${{ runner.os }}-conan-downloads-
138-
13970 - name : Install dependencies
140- run : conan install . ${{ needs.conan-recipe-version.outputs.recipe_id_full }} -s build_type=Release --build=missing --update -g GitHubActionsRunEnv -g GitHubActionsBuildEnv -c tools.build:skip_test=True -o with_cura_resources=True
141- working-directory : CuraEngine
142-
143- - name : Set Environment variables from Conan install (bash)
144- if : ${{ runner.os != 'Windows' }}
145- run : |
146- . ./activate_github_actions_runenv.sh
147- . ./activate_github_actions_buildenv.sh
148- working-directory : CuraEngine/build/Release/generators
71+ run : conan install . ${{ needs.conan-recipe-version.outputs.version_full }} -s "*:build_type=Release" --build=missing --update -g VirtualRunEnv -c tools.build:skip_test=True -o with_cura_resources=True
14972
15073 - name : Build CuraEngine and tests
15174 run : |
75+ source build/Release/generators/conanbuild.sh
15276 cmake --preset release
15377 cmake --build --preset release
154- working-directory : CuraEngine
15578
15679 - name : Collect STL-files, run CuraEngine, output GCode-files
15780 run : |
158- for file in `ls ../ NightlyTestModels/*.stl`;
81+ for file in `ls NightlyTestModels/*.stl`;
15982 do
160- ( time ./build/Release/CuraEngine slice --force-read-parent --force-read-nondefault -v -p -j $CURA_RESOURCES/definitions/ultimaker_s3.def.json -l $file -o ../ `basename $file .stl`.gcode ) 2> ../ `basename $file .stl`.time
83+ ( time ./build/Release/CuraEngine slice --force-read-parent --force-read-nondefault -v -p -j $CURA_RESOURCES/definitions/ultimaker_s3.def.json -l $file -o `basename $file .stl`.gcode ) 2> `basename $file .stl`.time
16184 done
162- working-directory : CuraEngine
16385
164- # TODO: Move this to GCodeAnalyzer
86+ # TODO: Move this to GCodeAnalyzer
16587 - name : Run GCodeAnalyzer on generated GCode files
16688 id : gcode_out
16789 run : |
0 commit comments