diff --git a/.github/workflows/coding-style.yml b/.github/workflows/coding-style.yml index 961a11ee..f0c91fcf 100644 --- a/.github/workflows/coding-style.yml +++ b/.github/workflows/coding-style.yml @@ -12,6 +12,10 @@ on: permissions: contents: read +.prepare-conda: &prepare-conda + - source $CONDA/etc/profile.d/conda.sh + - conda activate + jobs: Flake8: runs-on: ubuntu-latest @@ -50,8 +54,7 @@ jobs: python-version: ${{ matrix.python-version }} - name: Install dependencies run: | - source $CONDA/etc/profile.d/conda.sh - conda activate + *prepare-conda conda install -y -c conda-forge mayavi traits traitsui pyface pyfmi h5py mpi4py pytest-cov psutil pytables pyyaml matplotlib mamba pandas openpyxl jupyter jupyter-book flake8 pylint #python -m pip install --upgrade pip #pip install pylint @@ -59,6 +62,5 @@ jobs: pip install . - name: Analysing the code with pylint run: | - source $CONDA/etc/profile.d/conda.sh - conda activate + *prepare-conda pylint $(git ls-files '*.py') --fail-under=7.0 \ No newline at end of file