diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 5296d999..c5ef0280 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -30,7 +30,10 @@ jobs: echo "BRANCH=${GITHUB_REF##*/}" >> $GITHUB_ENV echo "WORKDIR=$(pwd)" >> $GITHUB_ENV - + - name: install miniforge + run: | + wget -O Miniforge3.sh "https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge3-$(uname)-$(uname -m).sh" + bash Miniforge3.sh -b -p "${HOME}/conda" - name: cythonize and pip # Convert .pyx files to .cpp and package into sdist tarball. @@ -38,7 +41,7 @@ jobs: # This only requires Cython, Python, and g++. Then install the tarball # with pip to make sure it works. run: | - eval "$(conda shell.bash hook)" + source "${HOME}/conda/etc/profile.d/conda.sh" conda create -p ./cython-env -y "cython>=0.29.30,<3.0" python=${{ matrix.python-version }} gxx zlib --channel conda-forge conda activate ./cython-env python setup.py clean cythonize sdist @@ -61,7 +64,7 @@ jobs: # # Tests below will operate in this newly-installed directory. run: | - eval "$(conda shell.bash hook)" + source "${HOME}/conda/etc/profile.d/conda.sh" conda install python=${{ matrix.python-version }} -y --channel conda-forge # Only install non-python dependencies (like bedtools & ucsc tools); @@ -91,7 +94,7 @@ jobs: # Run pytest and sphinx doctests run: | cd $WORKDIR - eval "$(conda shell.bash hook)" + source "${HOME}/conda/etc/profile.d/conda.sh" conda activate ./test-env # Extract the package tarball built above, and use that for running the tests. @@ -107,7 +110,7 @@ jobs: # Build docs and commit to gh-pages branch. Note that no push happens # unless we're on the master branch run: | - eval "$(conda shell.bash hook)" + source "${HOME}/conda/etc/profile.d/conda.sh" conda activate ./test-env # Move to extracted tarball dir, see above notes