Skip to content

Commit e41fa83

Browse files
authored
Merge pull request sergi#63 from maksimov/master
Fix lint.sh on macOS (sergi#62)
2 parents 431343a + 159939f commit e41fa83

File tree

3 files changed

+6
-4
lines changed

3 files changed

+6
-4
lines changed

AUTHORS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,3 +22,4 @@ Shatrugna Sadhu <[email protected]>
2222
Shawn Smith <[email protected]>
2323
Tor Arvid Lund <[email protected]>
2424
Zac Bergquist <[email protected]>
25+
Stas Maksimov <[email protected]>

CONTRIBUTORS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,3 +29,4 @@ Shatrugna Sadhu <[email protected]>
2929
Shawn Smith <[email protected]>
3030
Tor Arvid Lund <[email protected]>
3131
Zac Bergquist <[email protected]>
32+
Stas Maksimov <[email protected]>

scripts/lint.sh

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,18 +5,18 @@ if [ -z ${ROOT_DIR+x} ]; then echo "ROOT_DIR is not set"; exit 1; fi
55

66
echo "gofmt:"
77
OUT=$(gofmt -l $ROOT_DIR)
8-
if [ $(echo -n "$OUT" | wc -l) -ne 0 ]; then echo "$OUT"; PROBLEM=1; fi
8+
if [ $(echo "$OUT\c" | wc -l) -ne 0 ]; then echo "$OUT"; PROBLEM=1; fi
99

1010
echo "errcheck:"
1111
OUT=$(errcheck $PKG/...)
12-
if [ $(echo -n "$OUT" | wc -l) -ne 0 ]; then echo "$OUT"; PROBLEM=1; fi
12+
if [ $(echo "$OUT\c" | wc -l) -ne 0 ]; then echo "$OUT"; PROBLEM=1; fi
1313

1414
echo "go vet:"
1515
OUT=$(go tool vet -all=true -v=true $ROOT_DIR 2>&1 | grep --invert-match -P "(Checking file|\%p of wrong type|can't check non-constant format)")
16-
if [ $(echo -n "$OUT" | wc -l) -ne 0 ]; then echo "$OUT"; PROBLEM=1; fi
16+
if [ $(echo "$OUT\c" | wc -l) -ne 0 ]; then echo "$OUT"; PROBLEM=1; fi
1717

1818
echo "golint:"
1919
OUT=$(golint $PKG/... | grep --invert-match -P "(method DiffPrettyHtml should be DiffPrettyHTML)")
20-
if [ $(echo -n "$OUT" | wc -l) -ne 0 ]; then echo "$OUT"; PROBLEM=1; fi
20+
if [ $(echo "$OUT\c" | wc -l) -ne 0 ]; then echo "$OUT"; PROBLEM=1; fi
2121

2222
if [ -n "$PROBLEM" ]; then exit 1; fi

0 commit comments

Comments
 (0)