Skip to content

.gitlab-ci.yml: More robust solution to MacOS permission error failures

Description

As reported elsewhere (https://git.ligo.org/computing/helpdesk/-/issues/1742, https://git.ligo.org/lscsoft/lalsuite/-/issues/548) macOS CI jobs can fail when a previous make distcheck job fails, leaving behind read-only files, which git clean will then refuse to remove in a subsequent job. The current solution (!1743 (merged), !1872 (merged)) adds an after_script to reset the file permissions, but this won't work if the user manually cancels a CI job/pipeline, as then the after_script isn't run.

A more robust solution is to disable GitLab Runner running git clean for any job which runs make distcheck by setting GIT_CLEAN_FLAGS to none for the .make-distcheck template. Instead, run git clean manually in the .make-distcheck build script, after first running chmod -R +w $CI_PROJECT_DIR to reset the file permissions

The .macos-job template is removed, as it's no longer needed.

In addition, a minor cleanup: use macos (instead of macosx) consistently in macOS CI job names

API Changes and Justification

Backwards Compatible Changes

  • This change does not modify any class/function/struct/type definitions in a public C header file or any Python class/function definitions
  • This change adds new classes/functions/structs/types to a public C header file or Python module

Backwards Incompatible Changes

  • This change modifies an existing class/function/struct/type definition in a public C header file or Python module
  • This change removes an existing class/function/struct/type from a public C header file or Python module

Review Status

cc @adam-mercer

Merge request reports