Skip to content

Commit 4477ce9

Browse files
committed
removed changed file mistakenly included
1 parent 8335bd2 commit 4477ce9

File tree

1 file changed

+16
-25
lines changed

1 file changed

+16
-25
lines changed

.github/workflows/test_conda-build.yml

Lines changed: 16 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -17,45 +17,36 @@ jobs:
1717
test_conda_install:
1818
runs-on: ubuntu-latest
1919
timeout-minutes: 10
20-
strategy:
21-
matrix:
22-
python-version: ['3.8', '3']
23-
env:
24-
ENV_FILE: conda-environment.yml
2520
steps:
2621
- name: checkout cylc-flow
2722
uses: actions/checkout@v4
2823

29-
- name: modify conda env file
30-
run: |
31-
# write environment file
32-
echo " - pip" >> "$ENV_FILE" # list pip as a dependency
33-
echo " - pip:" >> "$ENV_FILE" # add a pip section
34-
echo " - ." >> "$ENV_FILE" # install cylc-flow (pip install .)
35-
cat "$ENV_FILE"
36-
3724
- name: build conda env
38-
uses: conda-incubator/setup-miniconda@v3
39-
with:
40-
python-version: ${{ matrix.python-version }}
41-
environment-file: ${{ env.ENV_FILE }}
42-
43-
- name: check cylc installation
44-
shell: bash -el {0}
4525
run: |
46-
conda run -n test cylc version --long
26+
# write environment file
27+
env_file='conda-environment.yml'
28+
echo " - pip" >> "$env_file" # list pip as a dependency
29+
echo " - pip:" >> "$env_file" # add a pip section
30+
echo " - ." >> "$env_file" # install cylc-flow (pip install .)
31+
cat "$env_file"
32+
# install environment
33+
conda env create \
34+
-f "$env_file" \
35+
--prefix cylc-dev
36+
. /usr/share/miniconda/etc/profile.d/conda.sh
37+
# check cylc-flow was installed correctly
38+
conda run --prefix cylc-dev cylc version --long
4739
4840
- name: check for activate scripts
49-
shell : bash -el {0}
5041
run: |
5142
# https://github.com/cylc/cylc-flow/issues/3704#issuecomment-897442365
5243
# locate all activate scripts
53-
find "$CONDA_PREFIX" -name "activate.d" | tee > activates.txt
44+
find ./cylc-dev/ -name "activate.d" | tee > activates.txt
5445
# ignore the conda activate script itself
55-
sed -i "\|$CONDA_PREFIX/etc/conda/activate.d|d" activates.txt
46+
sed -i '/cylc-dev\/etc\/conda\/activate.d/d' activates.txt
5647
# check to make sure no packages have contributed new activate scripts
5748
# (we rely on having a conda activate-less environment)
58-
if [[ $(wc -l < activates.txt) -ne 0 ]]; then
49+
if [[ $(cat activates.txt | wc -l) -ne 0 ]]; then
5950
echo '::error::Found activate scripts in installation.'
6051
cat activates.txt >&2
6152
exit 1

0 commit comments

Comments
 (0)