@@ -2,53 +2,50 @@ sudo: false
2
2
language : python
3
3
python : 2.7
4
4
5
+ # This is a big repository so break Travis CI work into 2 CI jobs.
5
6
env :
6
- - CHUNK=xaa
7
- - CHUNK=xab
8
- - CHUNK=xac
9
- - CHUNK=xad
7
+ - CHUNK=0
8
+ - CHUNK=1
10
9
11
10
before_install :
12
11
- export GALAXY_REPO=https://github.com/galaxyproject/galaxy
13
12
- export GALAXY_RELEASE=release_16.10
14
13
- export PLANEMO_CONDA_PREFIX="$HOME/conda"
15
- - unset JAVA_HOME # Interferes with java tools installed through conda
16
14
17
15
install :
18
- # html5lib (planemo dep) requires setuptools >= 18.5
19
- - pip install -q flake8 planemo
16
+ - pip install flake8 planemo
20
17
- planemo conda_init
21
18
- export PATH="$PLANEMO_CONDA_PREFIX/bin:$PATH"
19
+ - conda update -y conda
22
20
- conda create -y -q -c bioconda --name iuc_conda samtools=0.1.19 bcftools
23
21
- . activate iuc_conda
24
22
- planemo --version
25
23
- conda --version
26
- - echo $TRAVIS_COMMIT_RANGE
27
- - git diff --name-only $TRAVIS_COMMIT_RANGE | xargs -n1 dirname | ./filter_directories.py | sort -u > changed_repositories.list
28
- - cat changed_repositories.list
29
-
30
- script :
31
- - cd "$TRAVIS_BUILD_DIR" # # && flake8 -v --exclude=.git .
24
+ - git diff --quiet "$TRAVIS_COMMIT_RANGE" -- ; GIT_DIFF_EXIT_CODE=$?
32
25
- |
33
- if [ -s changed_repositories.list ]
34
- then
35
- split -n l/4 changed_repositories.list
26
+ if [ "$GIT_DIFF_EXIT_CODE" -gt 1 ] ; then
27
+ git remote set-branches --add origin master;
28
+ git fetch;
29
+ TRAVIS_COMMIT_RANGE=origin/master...;
36
30
fi
37
- - echo "$CHUNK"
31
+ - echo $TRAVIS_COMMIT_RANGE
38
32
- |
39
- if [ "${CHUNK}" ] && [ -s "${CHUNK}" ]
40
- then
41
- cat "$CHUNK"
42
- export PLANEMO_TEST_RUN=True
43
- while read -r DIR; do planemo shed_lint --report_level warn --tools --fail_level error --recursive "$DIR"; done < "$CHUNK"
44
- while read -r DIR; do planemo conda_install "$DIR"; done < "$CHUNK"
45
- while read -r DIR; do planemo test --conda_dependency_resolution --galaxy_branch $GALAXY_RELEASE --galaxy_source $GALAXY_REPO "$DIR" || exit 1; done < "$CHUNK"
46
- fi
33
+ planemo ci_find_repos --exclude_from .tt_blacklist \
34
+ --exclude packages --exclude data_managers \
35
+ --changed_in_commit_range "$TRAVIS_COMMIT_RANGE" \
36
+ --chunk_count 2 --chunk "${CHUNK}" \
37
+ --output changed_repositories_chunk.list
38
+ - cat changed_repositories_chunk.list
39
+
40
+ script :
41
+ - cd "$TRAVIS_BUILD_DIR" # # && flake8 --exclude=.git .
42
+ - while read -r DIR; do planemo shed_lint --tools --ensure_metadata --urls --report_level warn --fail_level error --recursive "$DIR" || exit 1; done < changed_repositories_chunk.list
43
+ - while read -r DIR; do planemo conda_install "$DIR"; done < changed_repositories_chunk.list
44
+ - while read -r DIR; do planemo test --conda_dependency_resolution --galaxy_branch "$GALAXY_RELEASE" --galaxy_source "$GALAXY_REPO" "$DIR" || exit 1; done < changed_repositories_chunk.list
47
45
48
46
after_success :
49
47
- |
50
- if [ "$TRAVIS_PULL_REQUEST" == "false" -a "$TRAVIS_BRANCH" == "master" -a "$PLANEMO_TEST_RUN" == 'True' ]
51
- then
52
- while read -r DIR; do planemo shed_update --shed_target testtoolshed --shed_email $SHED_EMAIL --shed_password $SHED_PASSWORD --force_repository_creation "$DIR" || exit 1; done < "$CHUNK"
53
- while read -r DIR; do planemo shed_update --shed_target toolshed --shed_email $SHED_EMAIL --shed_password $SHED_PASSWORD --force_repository_creation "$DIR" || exit 1; done < "$CHUNK"
48
+ if [ "$TRAVIS_PULL_REQUEST" == "false" -a "$TRAVIS_BRANCH" == "master" ]; then
49
+ while read -r DIR; do planemo shed_update --shed_target testtoolshed --shed_email "$SHED_EMAIL" --shed_password "$SHED_PASSWORD" --force_repository_creation "$DIR" || exit 1; done < changed_repositories_chunk.list
50
+ while read -r DIR; do planemo shed_update --shed_target toolshed --shed_email "$SHED_EMAIL" --shed_password "$SHED_PASSWORD" --force_repository_creation "$DIR" || exit 1; done < changed_repositories_chunk.list
54
51
fi
0 commit comments