From 91104c5e9ac91e409cf9f01a4a4f3136cff4f149 Mon Sep 17 00:00:00 2001 From: zichao Date: Fri, 14 Jul 2023 22:09:06 +0800 Subject: [PATCH] update CI with conda --- .github/workflows/buildTest.yml | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/.github/workflows/buildTest.yml b/.github/workflows/buildTest.yml index 122215f..9987c7a 100644 --- a/.github/workflows/buildTest.yml +++ b/.github/workflows/buildTest.yml @@ -10,6 +10,9 @@ jobs: name: Build test # Set the type of machine to run on runs-on: ubuntu-20.04 + defaults: + run: + shell: bash -l {0} container: ros:noetic # Only run when merging to main. if: github.ref == 'refs/heads/main' @@ -30,11 +33,21 @@ jobs: - name: Checkout code uses: actions/checkout@v2 + - uses: conda-incubator/setup-miniconda@v2 + with: + miniconda-version: "latest" + channels: bioconda, conda-forge, defaults + use-only-tar-bz2: true # IMPORTANT: This needs to be set for caching to work properly! + auto-update-conda: true + auto-activate-base: true + - name: Install dependencies run: | cd $GITHUB_WORKSPACE - $CONDA/bin/conda env create -f environment.yml - $CONDA/bin/conda activate codebotler + echo "begin: PATH=$PATH;" + conda env create -f environment.yml + conda activate codebotler || true + echo "after conda activate codebotler: PATH=$PATH;" pip3 install torch torchvision torchaudio - name: Catkin make