diff --git a/.travis.yml b/.travis.yml index 35ce481..652d04c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -11,11 +11,11 @@ git: install: - export GOPATH="${TRAVIS_BUILD_DIR}/Godeps/_workspace:$GOPATH" - export PATH="${TRAVIS_BUILD_DIR}/Godeps/_workspace/bin:$PATH" - - sudo env PATH=$PATH GOPATH=$GOPATH sh files/check-install.sh + - sudo env PATH=$PATH GOPATH=$GOPATH bash files/check-install.sh script: - - sh files/check.sh - - sh files/run_on_master.sh + - bash files/check.sh + - bash files/run_on_master.sh notifications: email: false diff --git a/files/Dockerfile b/files/Dockerfile index d573a6a..5961cd6 100644 --- a/files/Dockerfile +++ b/files/Dockerfile @@ -6,4 +6,4 @@ ENV GOPATH "/home/travis/gopath" ENV GOROOT "/home/travis/.gimme/versions/go1.7.4.linux.amd64" ENV PATH "$GOPATH/bin:$GOROOT/bin:$PATH" COPY check-install.sh /tmp -RUN sh /tmp/check-install.sh +RUN bash /tmp/check-install.sh diff --git a/files/dictionary.dic b/files/dictionary.dic index 0e695eb..705252a 100644 --- a/files/dictionary.dic +++ b/files/dictionary.dic @@ -170,5 +170,5 @@ yandex Хостелы цій ывро -явника який +явника diff --git a/files/docker-compose.yml b/files/docker-compose.yml index 15f2075..5c0cf1e 100644 --- a/files/docker-compose.yml +++ b/files/docker-compose.yml @@ -7,6 +7,6 @@ services: dockerfile: Dockerfile container_name: ru_de_checker user: travis - command: bash -l -c "cd /home/travis/ru-de-faq && sh files/check.sh" + command: bash -l -c "cd /home/travis/ru-de-faq && bash files/check.sh" volumes: - ../.:/home/travis/ru-de-faq diff --git a/files/push.sh b/files/push.sh index ee0ff92..58a2e8c 100644 --- a/files/push.sh +++ b/files/push.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/bash setup_git() { git config --global user.email "travis@travis-ci.org" diff --git a/files/run_on_master.sh b/files/run_on_master.sh index 03919a8..3539608 100644 --- a/files/run_on_master.sh +++ b/files/run_on_master.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/bash set -e @@ -8,6 +8,9 @@ skip() { exit 0 } +[ "${TRAVIS_COMMIT_MESSAGE}" == "${TRAVIS_COMMIT_MESSAGE/Travis build/}" ] || \ + skip "Skip for travis updates." + [ "${TRAVIS_PULL_REQUEST}" = "false" ] || \ skip "Not running master-only script for pull-requests." @@ -22,7 +25,7 @@ skip() { dict_check() { LC_ALL=ru_RU.UTF8 sort files/dictionary.dic -C || \ - (LC_ALL=ru_RU.UTF8 sort files/dictionary.dic -o files/dictionary.dic -f && sh files/push.sh) + (LC_ALL=ru_RU.UTF8 sort files/dictionary.dic -o files/dictionary.dic -f && bash files/push.sh) } dict_check