neofetch/.travis.yml

23 lines
860 B
YAML
Raw Normal View History

2016-03-26 02:03:25 +01:00
language: bash
2016-03-26 02:13:31 +01:00
sudo: required
2016-03-26 02:03:25 +01:00
2016-03-26 04:32:06 +01:00
os:
- linux
- osx
2016-03-27 10:50:09 +02:00
before_install:
2016-12-08 10:23:15 +01:00
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew update; fi
2016-03-27 10:50:09 +02:00
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install screenresolution; fi
2016-03-26 02:03:25 +01:00
script:
2018-05-04 01:35:28 +02:00
- time ./neofetch --travis -v
2016-12-08 09:18:06 +01:00
# See this wiki page for why we're disabling these errors.
2016-12-08 10:17:08 +01:00
# https://github.com/dylanaraps/neofetch/wiki/Shellcheck-Exclusions
2018-06-02 22:59:24 +02:00
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then shellcheck neofetch; fi
# The if statement is here to invert the exit code from grep.
# grep normally errors if no match is found but we want the opposite.
# We invert it so grep fails if a match is found.
# Check for lines longer than 100 chars.
# There are 3 lines that must be longer than 100 chars.
- if (("$(grep '.\{101\}' neofetch | wc -l)" > 3)); then (exit 1); else (exit 0); fi