diff --git a/.ci/install.sh b/.ci/install.sh index 00a1a9c93..c18aa4b23 100755 --- a/.ci/install.sh +++ b/.ci/install.sh @@ -6,31 +6,15 @@ set -ue -o pipefail # Prevent commands misbehaving due to locale differences export LC_ALL=C -git fetch origin master:master - -if [ "${LINT#vimlint}" != "$LINT" ]; then - git clone --depth=1 https://github.com/wsdjeg/vim-vimlint /tmp/vimlint - git clone --depth=1 https://github.com/ynkdir/vim-vimlparser /tmp/vimlparser -elif [ "${LINT#vint}" != "$LINT" ]; then - pip install --pre vim-vint pathlib enum34 typing - vint --version -elif [ "${LINT#vader}" != "$LINT" ]; then - if [[ ! -d "$HOME/.cache/vimfiles/repos/github.com/Shougo/dein.vim" ]]; then - git clone --depth=1 https://github.com/Shougo/dein.vim.git ~/.cache/vimfiles/repos/github.com/Shougo/dein.vim - fi - .ci/install/linux.sh $VIM_BIN $VIM_TAG - if [ "$VIM_BIN" = "nvim" ]; then - export PATH="${DEPS}/_neovim/${VIM_TAG}/bin:${PATH}" - export VIM="${DEPS}/_neovim/${VIM_TAG}/share/nvim/runtime" - else - export PATH="${DEPS}/_vim/${VIM_TAG}/bin:${PATH}" - export VIM="${DEPS}/_vim/${VIM_TAG}/share/vim" - fi - - echo "\$PATH: \"${PATH}\"" - echo "\$VIM: \"${VIM}\"" - echo "================= nvim version ======================" - $VIM_BIN --version -elif [ "$LINT" = "jekyll" ]; then - .ci/bootstrap +.ci/install/linux.sh $VIM_BIN $VIM_TAG +if [ "$VIM_BIN" = "nvim" ]; then + export PATH="${DEPS}/_neovim/${VIM_TAG}/bin:${PATH}" + export VIM="${DEPS}/_neovim/${VIM_TAG}/share/nvim/runtime" +else + export PATH="${DEPS}/_vim/${VIM_TAG}/bin:${PATH}" + export VIM="${DEPS}/_vim/${VIM_TAG}/share/vim" fi + +echo "\$VIM: \"${VIM}\"" +echo "================= nvim version ======================" +$VIM_BIN --version diff --git a/.ci/script.sh b/.ci/script.sh index e1ffdf52d..3b36ef20b 100755 --- a/.ci/script.sh +++ b/.ci/script.sh @@ -83,7 +83,6 @@ elif [ "$LINT" = "vader" ]; then make test_coverage covimerage -vv xml --omit 'build/*' codecov -X search gcov pycov -f coverage.xml - make test elif [ "$LINT" = "jekyll" ]; then .ci/build-production fi diff --git a/.github/workflows/check.yml b/.github/workflows/check.yml index 64a36f279..0e888626e 100644 --- a/.github/workflows/check.yml +++ b/.github/workflows/check.yml @@ -1,4 +1,4 @@ -name: Test +name: build on: [push, pull_request] @@ -7,19 +7,43 @@ jobs: strategy: fail-fast: false matrix: - vimFlavor: ["vim", "nvim"] + include: + - vimbin: vim + vimtag: ["v7.4.052", "v7.4.629", "v7.4.1689", "v8.0.0027", "v8.0.1453", "v8.1.2269"] + - vimbin: nvim + vimtag: [] + vimtag: ["v0.4.3", "v0.4.3", "v0.4.3", "v0.4.2", "v0.3.8", "v0.3.7", "v0.3.5", "v0.3.4", "v0.3.3", "v0.3.2", "v0.3.1", "v0.3.0"] runs-on: ubuntu-latest steps: - name: Checkout uses: actions/checkout@master - - name: Install ${{ matrix.vimFlavor }} - if: matrix.vimFlavor == 'nvim' + - name: Install ${{ matrix.vimbin }} ${{ matrix.vimtag }} + env: + VIM_BIN: matrix.vimbin + VIM_TAG: matrix.vimtag + DEPS: $HOME/deps + PATH: $DEPS/bin:$HOME/vim/bin:$PATH run: | - sudo add-apt-repository universe - sudo apt-get update - sudo apt-get install neovim - - name: Review ${{ matrix.vimFlavor }} version - run: ${{ matrix.vimFlavor }} --version - - name: Run vader test + .ci/install/linux.sh $VIM_BIN $VIM_TAG + - name: Review ${{ matrix.vimbin }} version + run: ${{ matrix.vimbin }} --version + - name: Run test run: | - make test + if [ "$VIM_BIN" = "nvim" ]; then + export PATH="${DEPS}/_neovim/${VIM_TAG}/bin:${PATH}" + export VIM="${DEPS}/_neovim/${VIM_TAG}/share/nvim/runtime" + else + export PATH="${DEPS}/_vim/${VIM_TAG}/bin:${PATH}" + export VIM="${DEPS}/_vim/${VIM_TAG}/share/vim" + fi + + echo "\$PATH: \"${PATH}\"" + echo "\$VIM: \"${VIM}\"" + echo "================= ${VIM_BIN} version ======================" + $VIM_BIN --version + pip install covimerage + pip install codecov + python -c 'import os,sys,fcntl; flags = fcntl.fcntl(sys.stdout, fcntl.F_GETFL); fcntl.fcntl(sys.stdout, fcntl.F_SETFL, flags&~os.O_NONBLOCK);' + make test_coverage + covimerage -vv xml --omit 'build/*' + codecov -X search gcov pycov -f coverage.xml