Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Include MACOS arm64 compatibility in manage.sh #929

Open
wants to merge 9 commits into
base: master
Choose a base branch
from
9 changes: 7 additions & 2 deletions .github/workflows/test_suite.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
matrix:
python-version: [3.8]
#platform: [ubuntu-18.04, macos-latest]
platform: [ubuntu-20.04]
platform: [ubuntu-20.04, macos-latest, ubuntu-22.04-arm]
runs-on: ${{ matrix.platform }}

steps:
Expand All @@ -27,7 +27,12 @@ jobs:

- name: Install IC
run: |
source $CONDA/etc/profile.d/conda.sh

case "$(uname -m)" in
x86_64) source $CONDA/etc/profile.d/conda.sh ;;
aarch64) echo "CONDA=/home/runner/miniconda" >> "$GITHUB_ENV" ;;
arm64) echo "CONDA=/Users/runner/miniconda" >> "$GITHUB_ENV" ;;
esac
source manage.sh work_in_python_version_no_tests ${{ matrix.python-version }}


Expand Down
17 changes: 16 additions & 1 deletion manage.sh
Original file line number Diff line number Diff line change
Expand Up @@ -56,11 +56,26 @@ function install_conda {
;;
esac

# Setting architecture based on input
ARCH=$(uname -m)

case $ARCH in

x86_64) : ;;
arm64) : ;;
aarch64) : ;;
*)
echo "Installation only supported on x86_64 and arm architectures"
exit 1
;;
esac


if conda --version ; then
echo Conda already installed. Skipping conda installation.
else
echo Installing conda for $CONDA_OS
CONDA_URL="https://repo.anaconda.com/miniconda/Miniconda3-py${PYTHON_VERSION//.}_4.9.2-${CONDA_OS}-x86_64.sh"
CONDA_URL="https://repo.anaconda.com/miniconda/Miniconda3-py${PYTHON_VERSION//.}_4.12.0-${CONDA_OS}-${ARCH}.sh"
if which wget; then
wget ${CONDA_URL} -O miniconda.sh
else
Expand Down
Loading