diff --git a/.circleci/config.yml b/.circleci/config.yml index 7f163a2..5aa6fcc 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -25,43 +25,40 @@ jobs: docker: - image: ubuntu:bionic environment: - CONDA_PREFIX: /root/tools/miniconda3 + CONDA_PREFIX: /root/tools/mambaforge + PYSOLID_HOME: /root/tools/PySolid user: root working_directory: /root/tools/PySolid # Checkout the code as the first step. This is a dedicated CircleCI step. steps: - checkout - run: - name: Setting Environment with Miniconda + name: Setting Environment with Mambaforge command: | apt update apt-get update --yes && apt-get upgrade --yes apt-get install --yes wget git - # download and install miniconda3 + # download and install mambaforge mkdir -p ${HOME}/tools cd ${HOME}/tools - wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh - bash Miniconda3-latest-Linux-x86_64.sh -b -p ${HOME}/tools/miniconda3 - ${HOME}/tools/miniconda3/bin/conda init bash - ${HOME}/tools/miniconda3/bin/conda config --add channels conda-forge - ${HOME}/tools/miniconda3/bin/conda install -c conda-forge --yes mamba + wget https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-Linux-x86_64.sh + bash Mambaforge-Linux-x86_64.sh -b -p ${HOME}/tools/mambaforge + ${HOME}/tools/mambaforge/bin/mamba init bash + # modify/export env var PATH to BASH_ENV to be shared across run steps + echo 'export PATH=${CONDA_PREFIX}/bin:${PATH}' >> ${BASH_ENV} + - run: name: Installing PySolid no_output_timeout: 10m command: | export PYTHONUNBUFFERED=1 - # setup environment variable - export PATH=${CONDA_PREFIX}/bin:${PATH} - # install dependencies - source activate root - mamba install --verbose --yes fortran-compiler --file ${HOME}/tools/PySolid/requirements.txt - python -m pip install ${HOME}/tools/PySolid + # install dependencies and source code + mamba install --verbose --yes fortran-compiler --file ${PYSOLID_HOME}/requirements.txt + python -m pip install ${PYSOLID_HOME} - run: - name: Test + name: Unit Test command: | - # setup environment variables - export PATH=${CONDA_PREFIX}/bin:${PATH} # run tests - python ${HOME}/tools/PySolid/tests/point.py - python ${HOME}/tools/PySolid/tests/grid.py + python ${PYSOLID_HOME}/tests/point.py + python ${PYSOLID_HOME}/tests/grid.py diff --git a/README.md b/README.md index 7b31b11..7abf05e 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,9 @@ [![Language](https://img.shields.io/badge/python-3.8%2B-blue.svg?style=flat-square)](https://www.python.org/) -[![CircleCI](https://img.shields.io/circleci/build/github/insarlab/PySolid.svg?logo=circleci&label=test&style=flat-square)](https://circleci.com/gh/insarlab/PySolid) -[![Version](https://img.shields.io/github/v/release/insarlab/PySolid?color=brightgreen&label=version&style=flat-square)](https://github.com/insarlab/PySolid/releases) -[![Conda Download](https://img.shields.io/conda/dn/conda-forge/pysolid?color=green&style=flat-square)](https://anaconda.org/conda-forge/pysolid) -[![License](https://img.shields.io/badge/license-GPLv3+-yellow.svg?style=flat-square)](https://github.com/insarlab/PySolid/blob/main/LICENSE) -[![Citation](https://img.shields.io/badge/doi-10.1109%2FTGRS.2022.3168509-blue?style=flat-square)](https://doi.org/10.1109/TGRS.2022.3168509) +[![CircleCI](https://img.shields.io/circleci/build/github/insarlab/PySolid.svg?logo=circleci&label=tests&style=flat-square)](https://circleci.com/gh/insarlab/PySolid) +[![Conda Download](https://img.shields.io/conda/dn/conda-forge/pysolid?color=green&label=conda%20downloads&style=flat-square)](https://anaconda.org/conda-forge/pysolid) +[![Version](https://img.shields.io/github/v/release/insarlab/PySolid?color=yellow&label=version&style=flat-square)](https://github.com/insarlab/PySolid/releases) +[![License](https://img.shields.io/badge/license-GPLv3+-blue.svg?style=flat-square)](https://github.com/insarlab/PySolid/blob/main/LICENSE) +[![Citation](https://img.shields.io/badge/DOI-10.1109%2FTGRS.2022.3168509-blue?style=flat-square)](https://doi.org/10.1109/TGRS.2022.3168509) ## PySolid