Skip to content

Commit

Permalink
github/workflows: force deletion of existing upstream python symlinks…
Browse files Browse the repository at this point in the history
… on macOS

This way each time a new Python version is installed via Homebrew
, we don't get CI failures due to the upstream Python distribution
also being installed.

Ref: actions/runner-images#6459
Ref: actions/runner-images#2322
  • Loading branch information
jeeb committed Nov 11, 2022
1 parent 33136c2 commit 3d05988
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,14 @@ jobs:
steps:
- uses: actions/checkout@v3

- name: Remove stray upstream python binary symlinks under /usr/local
run: |
for lfile in $(find /usr/local/bin -type l); do
readlink "${lfile}";
done
find /usr/local/bin -lname '*/Library/Frameworks/Python.framework/*' -delete
brew link --overwrite python
- name: Install dependencies
run: |
brew update
Expand Down

0 comments on commit 3d05988

Please sign in to comment.