| 123456789101112131415161718192021222324252627282930 |
- language: go
- sudo: false
- install:
- - mkdir -p "${GOPATH%%:*}/src/github.com/shurcooL/markdownfmt"
- - git clone https://github.com/tianon/markdownfmt.git "${GOPATH%%:*}/src/github.com/shurcooL/markdownfmt"
- - go get -v github.com/shurcooL/markdownfmt
- script:
- - files="$(find -name '*.md' -print0 | xargs -0 markdownfmt -l)";
- if [ "$files" ]; then
- echo >&2 "Need markdownfmt:";
- echo >&2 "$files";
- echo >&2;
- echo "$files" | xargs markdownfmt -d >&2;
- exit 1;
- fi
- - failed='';
- for short in */README-short.txt; do
- chars="$(echo -n "$(cat "$short")" | wc -m)";
- lines="$(cat "$short" | wc -l)";
- if [ "$chars" -gt 100 -o "$lines" -gt 1 ]; then
- failed+=" $short";
- fi
- done;
- if [ "$failed" ]; then
- echo >&2 "Too long (or too many lines):$failed";
- exit 1;
- fi
|