-
Notifications
You must be signed in to change notification settings - Fork 2
/
.travis.yml
60 lines (52 loc) · 1.68 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
# Travis configuration file
---
dist: trusty
language: bash
addons:
apt_packages:
- build-essential
- git
- curl
cache:
timeout: 1000
directories:
- "$HOME/miniconda3_$TRAVIS_OS_NAME"
- "$TRAVIS_BUILD_DIR/.snakemake/conda" # snakemake envs
before_install: |
url="https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh"
if [[ -d "$HOME"/miniconda3_"$TRAVIS_OS_NAME"/bin ]]; then
echo "miniconda already installed."
else
echo "Installing miniconda."
mkdir -p "$HOME"/download
wget \
--continue \
--output-document "$HOME"/download/miniconda_"$TRAVIS_OS_NAME".sh \
$url
chmod +x "$HOME"/download/miniconda_"$TRAVIS_OS_NAME".sh
"$HOME"/download/miniconda_"$TRAVIS_OS_NAME".sh \
-u \
-b \
-p "$HOME"/miniconda3_"$TRAVIS_OS_NAME"
"$HOME"/miniconda3_"$TRAVIS_OS_NAME"/bin/conda clean --all --yes
echo "local_repodata_ttl: 1800" >> ~/.condarc
fi
install: |
export PATH="$HOME"/miniconda3_"$TRAVIS_OS_NAME"/bin:"$PATH"
echo "$PATH"
conda config --add channels defaults
conda config --add channels bioconda
conda config --add channels conda-forge
conda install --quiet --yes --channel bioconda snakemake=5.3.0
snakemake --use-conda --create-envs-only
conda clean --all --yes
script: |
echo $PATH
python --version
export PATH="$HOME"/miniconda3_"$TRAVIS_OS_NAME"/bin:"$PATH"
snakemake --use-conda --jobs 2
before_cache: |
# snakemake --cleanup-conda
conda clean --all --yes
rm -rf "$CONDA_PATH"/{locks,pkgs,var,conda-meta/history}
after_failure: