1
0
mirror of https://github.com/SpaceVim/SpaceVim.git synced 2025-01-24 06:30:03 +08:00
SpaceVim/.travis.yml

71 lines
1.9 KiB
YAML
Raw Normal View History

2017-04-15 15:23:39 +08:00
language: python
sudo: false
2016-12-26 21:20:45 +08:00
2017-08-27 06:33:24 +08:00
notifications:
slack:
on_success: never
on_failure: never
2017-10-19 08:02:00 +08:00
email:
2017-11-05 16:45:37 +08:00
on_success: never # default: change
2017-10-19 08:02:00 +08:00
on_failure: never # default: always
2016-12-26 21:20:45 +08:00
cache:
2017-04-14 20:48:35 +08:00
pip: true
2016-12-26 21:20:45 +08:00
env:
2017-04-15 15:23:39 +08:00
global:
- DEPS=$HOME/deps
- PATH=$DEPS/bin:$PATH
2017-04-14 20:48:35 +08:00
matrix:
- LINT=vimlint-errors
2016-12-26 21:20:45 +08:00
- LINT=vimlint
- LINT=vint-errors
- LINT=vint
2017-04-14 20:32:24 +08:00
- LINT=vader
2016-12-26 21:20:45 +08:00
matrix:
2017-04-14 20:48:35 +08:00
allow_failures:
- env: LINT=vimlint
2016-12-26 21:20:45 +08:00
- env: LINT=vint
install:
2017-04-14 20:48:35 +08:00
- |
set -e
2017-04-14 20:48:35 +08:00
if [ "${LINT#vimlint}" != "$LINT" ]; then
git clone --depth=1 https://github.com/syngan/vim-vimlint /tmp/vimlint
git clone --depth=1 https://github.com/ynkdir/vim-vimlparser /tmp/vimlparser
elif [ "${LINT#vint}" != "$LINT" ]; then
virtualenv /tmp/vint && source /tmp/vint/bin/activate && pip install vim-vint
elif [ "${LINT#vader}" != "$LINT" ]; then
2017-10-10 21:28:04 +08:00
git clone --depth=1 https://github.com/Shougo/dein.vim.git ~/.cache/vimfiles/repos/github.com/Shougo/dein.vim
2017-04-15 15:29:49 +08:00
C_OPTS="--prefix=$DEPS --with-features=huge --disable-gui --enable-pythoninterp"
2017-10-07 07:37:26 +08:00
(git clone --depth 1 https://github.com/vim/vim /tmp/vim &&
cd /tmp/vim &&
./configure $C_OPTS &&
make install)
2017-04-14 20:48:35 +08:00
fi
2016-12-26 21:20:45 +08:00
script:
2017-04-14 20:48:35 +08:00
- |
2017-10-06 06:18:20 +08:00
set -ex
2017-04-14 20:48:35 +08:00
if [ "$LINT" = "vimlint" ]; then
2017-10-10 21:14:46 +08:00
for file in $(git diff --name-only HEAD dev | grep .vim$);
2017-10-06 21:20:03 +08:00
do
sh /tmp/vimlint/bin/vimlint.sh -l /tmp/vimlint -p /tmp/vimlparser $file;
done
2017-04-14 20:48:35 +08:00
elif [ "$LINT" = "vimlint-errors" ]; then
2017-10-10 21:14:46 +08:00
for file in $(git diff --name-only HEAD dev | grep .vim$);
2017-10-06 21:20:03 +08:00
do
sh /tmp/vimlint/bin/vimlint.sh -E -l /tmp/vimlint -p /tmp/vimlparser $file;
done
2017-04-14 20:48:35 +08:00
elif [ "$LINT" = "vint" ]; then
vint .
elif [ "$LINT" = "vint-errors" ]; then
vint --error .
elif [ "$LINT" = "vader" ]; then
2017-10-15 21:51:46 +08:00
pip install covimerage
make test_coverage
2017-10-09 04:25:37 +08:00
covimerage -vv xml --omit 'build/*'
pip install codecov
codecov -X search gcov pycov -f coverage.xml
2017-04-14 20:48:35 +08:00
fi
2017-10-15 21:55:46 +08:00
set +x