Skip to content

Commit

Permalink
Merge pull request #153 from ACCESS-NRI/davide/set_py_version
Browse files Browse the repository at this point in the history
Added PY_VERSION as Repo Variable
  • Loading branch information
atteggiani authored Nov 10, 2024
2 parents 495aaa5 + d510b2a commit ad9d244
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 9 deletions.
7 changes: 2 additions & 5 deletions .github/workflows/CD.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,6 @@ on:
tags:
- '*'

env:
PY_VERSION: "3.11"

jobs:

conda:
Expand All @@ -24,7 +21,7 @@ jobs:
uses: conda-incubator/setup-miniconda@11b562958363ec5770fef326fe8ef0366f8cbf8a
with:
miniconda-version: "latest"
python-version: ${{ env.PY_VERSION }}
python-version: ${{ vars.PY_VERSION }}
environment-file: conda/env_build.yml
auto-update-conda: false
auto-activate-base: false
Expand All @@ -34,7 +31,7 @@ jobs:
uses: uibcdf/action-build-and-upload-conda-packages@c6e7a90ad5e599d6cde76e130db4ee52ad733ecf
with:
meta_yaml_dir: conda
python-version: ${{ env.PY_VERSION }}
python-version: ${{ vars.PY_VERSION }}
user: accessnri
label: main
token: ${{ secrets.anaconda_token }}
6 changes: 2 additions & 4 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,6 @@ on:
branches: main
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
env:
PY_VERSION: "3.11"

jobs:
# JOB to run change in the build files
Expand Down Expand Up @@ -51,7 +49,7 @@ jobs:
uses: conda-incubator/setup-miniconda@a4260408e20b96e80095f42ff7f1a15b27dd94ca # v3.0.4
with:
miniconda-version: "latest"
python-version: ${{ env.PY_VERSION }}
python-version: ${{ vars.PY_VERSION }}
environment-file: .conda/env_build.yml
auto-activate-base: false
auto-update-conda: false
Expand Down Expand Up @@ -117,7 +115,7 @@ jobs:

# - name: Upload code coverage
# # Only upload once for the installed version
# if: ${{ matrix.python-version == env.PY_VERSION }}
# if: ${{ matrix.python-version == vars.PY_VERSION }}
# uses: codecov/codecov-action@b9fd7d16f6d7d1b5d2bec1a2887e65ceed900238 #v4.6.0
# with:
# token: ${{ secrets.codecov_token }}
Expand Down

0 comments on commit ad9d244

Please sign in to comment.