Fix Python path in macOS ARM64

This commit is contained in:
Wilson Lin 2021-11-12 16:39:59 +11:00
parent 1f81458c18
commit b11ad8dee3
1 changed files with 1 additions and 5 deletions

View File

@ -34,8 +34,6 @@ jobs:
- name: Set up Python (macOS ARM64) - name: Set up Python (macOS ARM64)
if: runner.name == 'macos-arm64' if: runner.name == 'macos-arm64'
run: | run: |
eval "$(/opt/homebrew/bin/brew shellenv)"
export HOMEBREW_NO_INSTALL_CLEANUP=1
brew unlink python brew unlink python
brew link python@${{ matrix.python }} brew link python@${{ matrix.python }}
@ -99,9 +97,7 @@ jobs:
eval "$(pyenv init --path)" eval "$(pyenv init --path)"
fi fi
if [[ "${{ runner.name }}" == macos-arm64 ]]; then if [[ "${{ runner.name }}" == macos-arm64 ]]; then
eval "$(/opt/homebrew/bin/brew shellenv)" pathToPython="/opt/homebrew/bin/python3"
export HOMEBREW_NO_INSTALL_CLEANUP=1
pathToPython="$(which python3)"
else else
pathToPython="$(which python)" pathToPython="$(which python)"
fi fi