Skip to content

Commit

Permalink
[scr] Made CI build dir names unique
Browse files Browse the repository at this point in the history
  • Loading branch information
chleh committed Aug 6, 2024
1 parent 22c759c commit d86cf77
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion scripts/ci/extends/template-build-linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
- rm -rf $build_dir_full
- mkdir -p $build_dir_full build
- if [[ "$OSTYPE" == "darwin"* ]] ; then readlink_cmd=greadlink; else readlink_cmd=readlink; fi
- ln -s `$readlink_cmd -f $build_dir_full` build/${CMAKE_PRESET}
- ln -s `$readlink_cmd -f $build_dir_full` build/${CMAKE_PRESET}-${CI_JOB_NAME_SLUG}-${CI_JOB_ID}
- ([[ $BUILD_CTEST_LARGE_ON_MASTER && "${CI_COMMIT_BRANCH}" == "master" ]]) && export BUILD_CTEST_LARGE=true
- cmake --preset=$CMAKE_PRESET --log-level=VERBOSE -Wno-dev $CMAKE_ARGS
# Activate .venv via .envrc
Expand Down
5 changes: 3 additions & 2 deletions scripts/ci/extends/template-build-win.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,13 @@
variables:
script:
- $build_directory_full = "..\build\" + $env:CMAKE_PRESET
- $artifacts_dir = "build\" + $env:CMAKE_PRESET + "-" + $env:CI_JOB_NAME_SLUG + "-" + $env:CI_JOB_ID
- $log_file = $build_directory_full + "\make.txt"
- (rm -r -fo $build_directory_full)
- cmd /c if not exist $build_directory_full mkdir $build_directory_full
- mkdir build
- mkdir build # We are inside the OGS source directory, now. This "build" dir will be, too.
# Create symlink https://stackoverflow.com/a/34905638/80480
- cmd /c mklink /D build\$env:CMAKE_PRESET $env:CI_PROJECT_DIR\$build_directory_full
- cmd /c mklink /D $artifacts_dir $env:CI_PROJECT_DIR\$build_directory_full
- $cmake_cmd = "cmake --preset=$env:CMAKE_PRESET --log-level=VERBOSE -Wno-dev $env:CMAKE_ARGS"
- $cmake_cmd
- Invoke-Expression $cmake_cmd
Expand Down

0 comments on commit d86cf77

Please sign in to comment.