Skip to content

Commit f94f488

Browse files
committed
apply actions linting to conda-package-cf
1 parent bc04150 commit f94f488

1 file changed

Lines changed: 14 additions & 14 deletions

File tree

.github/workflows/conda-package-cf.yml

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ jobs:
5656
${{ runner.os }}-conda-${{ env.CACHE_NUMBER }}-
5757
5858
- name: Add conda to system path
59-
run: echo $CONDA/bin >> $GITHUB_PATH
59+
run: echo "$CONDA/bin" >> "$GITHUB_PATH"
6060

6161
- name: Install conda-build
6262
run: conda install conda-build
@@ -66,7 +66,7 @@ jobs:
6666
CHANNELS=(-c conda-forge --override-channels)
6767
VERSIONS=(--python "${{ matrix.python }}" --numpy "${{ matrix.numpy }}")
6868
TEST=(--no-test)
69-
echo "CONDA_BLD=${CONDA}/conda-bld/linux-64" >> $GITHUB_ENV
69+
echo "CONDA_BLD=${CONDA}/conda-bld/linux-64" >> "$GITHUB_ENV"
7070
7171
conda build \
7272
"${TEST[@]}" \
@@ -100,21 +100,21 @@ jobs:
100100
with:
101101
name: ${{ env.PACKAGE_NAME }} ${{ runner.os }} Python ${{ matrix.python }}
102102
- name: Add conda to system path
103-
run: echo $CONDA/bin >> $GITHUB_PATH
103+
run: echo "$CONDA/bin" >> "$GITHUB_PATH"
104104
- name: Install conda-build
105105
run: conda install conda-build
106106
- name: Create conda channel
107107
run: |
108-
mkdir -p $GITHUB_WORKSPACE/channel/linux-64
109-
mv ${PACKAGE_NAME}-*.conda $GITHUB_WORKSPACE/channel/linux-64
110-
conda index $GITHUB_WORKSPACE/channel
108+
mkdir -p "$GITHUB_WORKSPACE/channel/linux-64"
109+
mv "${PACKAGE_NAME}"-*.conda "$GITHUB_WORKSPACE/channel/linux-64"
110+
conda index "$GITHUB_WORKSPACE/channel"
111111
# Test channel
112-
conda search $PACKAGE_NAME -c $GITHUB_WORKSPACE/channel --override-channels
112+
conda search "$PACKAGE_NAME" -c "$GITHUB_WORKSPACE/channel" --override-channels
113113
114114
- name: Collect dependencies
115115
run: |
116-
CHANNELS="-c $GITHUB_WORKSPACE/channel ${{ env.CHANNELS }}"
117-
conda create -n test_mkl_umath $PACKAGE_NAME python=${{ matrix.python }} $CHANNELS --only-deps --dry-run > lockfile
116+
CHANNELS=(-c "$GITHUB_WORKSPACE/channel" -c "conda-forge" --override-channels)
117+
conda create -n test_mkl_umath "$PACKAGE_NAME" "python=${{ matrix.python }}" "${CHANNELS[@]}" --only-deps --dry-run > lockfile
118118
- name: Display lockfile
119119
run: cat lockfile
120120

@@ -136,20 +136,20 @@ jobs:
136136
137137
- name: Install mkl_umath
138138
run: |
139-
CHANNELS="-c $GITHUB_WORKSPACE/channel ${{ env.CHANNELS }}"
140-
conda create -n test_mkl_umath python=${{ matrix.python }} $PACKAGE_NAME pytest $CHANNELS
139+
CHANNELS=(-c "$GITHUB_WORKSPACE/channel" -c "conda-forge" --override-channels)
140+
conda create -n test_mkl_umath "python=${{ matrix.python }}" "$PACKAGE_NAME" pytest "${CHANNELS[@]}"
141141
# Test installed packages
142142
conda list -n test_mkl_umath
143143
144144
- name: Smoke test
145145
run: |
146-
source $CONDA/etc/profile.d/conda.sh
146+
source "$CONDA/etc/profile.d/conda.sh"
147147
conda activate test_mkl_umath
148148
python -c "import mkl_umath, numpy as np; mkl_umath.use_in_numpy(); np.sin(np.linspace(0, 1, num=10**6));"
149149
150150
- name: Run tests
151151
run: |
152-
source $CONDA/etc/profile.d/conda.sh
152+
source "$CONDA/etc/profile.d/conda.sh"
153153
conda activate test_mkl_umath
154154
pytest -v --pyargs ${{ env.PACKAGE_NAME }}
155155
@@ -205,7 +205,7 @@ jobs:
205205
- name: Store conda paths as envs
206206
shell: bash -l {0}
207207
run: |
208-
echo "CONDA_BLD=$CONDA/conda-bld/win-64/" | tr "\\\\" '/' >> $GITHUB_ENV
208+
echo "CONDA_BLD=$CONDA/conda-bld/win-64/" | tr "\\\\" '/' >> "$GITHUB_ENV"
209209
210210
- name: Install conda build
211211
run: |

0 commit comments

Comments
 (0)