From 2201423956d93161f18006908d26a3f5c7c6a679 Mon Sep 17 00:00:00 2001 From: John Freeman Date: Sat, 1 Jun 2024 16:58:08 -0500 Subject: [PATCH] Platform-specific virtual environment installation --- .github/actions/install-nix/action.yml | 10 ++++++++++ .github/actions/install-python/action.yml | 20 -------------------- .github/actions/install-windows/action.yml | 10 ++++++++++ 3 files changed, 20 insertions(+), 20 deletions(-) diff --git a/.github/actions/install-nix/action.yml b/.github/actions/install-nix/action.yml index 5a4fee0..6eba1de 100644 --- a/.github/actions/install-nix/action.yml +++ b/.github/actions/install-nix/action.yml @@ -11,6 +11,16 @@ runs: uses: ./.github/actions/install-python with: key: ${{ inputs.cache-key-python }} + - name: install Conan + shell: bash + run: | + venv=${HOME}/.venvs/conan + python -m venv ${venv} + ${venv}/bin/pip install --upgrade pip + ${venv}/bin/pip install 'conan<2' + mkdir -p ${HOME}/.local/bin + ln ${venv}/bin/conan ${HOME}/.local/bin/conan + echo ${HOME}/.local/bin >> ${GITHUB_PATH} - name: install Ninja on Linux if: startsWith(matrix.platform, 'ubuntu') shell: bash diff --git a/.github/actions/install-python/action.yml b/.github/actions/install-python/action.yml index 7d98745..45ffb43 100644 --- a/.github/actions/install-python/action.yml +++ b/.github/actions/install-python/action.yml @@ -27,26 +27,6 @@ runs: with: path: ${{ steps.pip-cache.outputs.dir }} key: ${{ runner.os }}-${{ inputs.key }} - - name: install Conan - shell: bash - run: | - venv=${HOME}/.venvs/conan - python -m venv ${venv} - ls -d ${HOME}/.venvs - ls -l ${HOME}/.venvs - ls -l ${venv} - ls -l ${venv}/bin - ${venv}/bin/pip install --upgrade pip - ${venv}/bin/pip install 'conan<2' - ${venv}/bin/conan --version - mkdir -p ${HOME}/.local/bin - ln ${venv}/bin/conan ${HOME}/.local/bin/conan - echo ${HOME}/.local/bin >> ${GITHUB_PATH} - - name: check installation - shell: bash - run: | - type conan - conan --version - name: install packages shell: bash run: | diff --git a/.github/actions/install-windows/action.yml b/.github/actions/install-windows/action.yml index 05eedd8..6edd0f0 100644 --- a/.github/actions/install-windows/action.yml +++ b/.github/actions/install-windows/action.yml @@ -35,6 +35,16 @@ runs: uses: ./.github/actions/install-python with: key: ${{ inputs.cache-key-python }} + - name: install Conan + shell: bash + run: | + venv=${HOME}/.venvs/conan + python -m venv ${venv} + ${venv}/Scripts/pip install --upgrade pip + ${venv}/Scripts/pip install 'conan<2' + mkdir -p ${HOME}/.local/bin + ln ${venv}/Scripts/conan ${HOME}/.local/bin/conan + echo ${HOME}/.local/bin >> ${GITHUB_PATH} - name: check environment shell: pwsh run: |