forked from mmcloughlin/avo
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
lint: linter for package docstrings (mmcloughlin#59)
Fixes mmcloughlin#38
- Loading branch information
1 parent
f1e854a
commit 9c913ee
Showing
4 changed files
with
23 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
# Print an error message to the terminal. | ||
print_error() { | ||
local red='\033[0;31m' | ||
local nocolor='\033[0m' | ||
printf "${red}error${nocolor}\t$1\n" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
#!/bin/bash -e | ||
|
||
source script/lib.sh | ||
|
||
status=0 | ||
pkgs=$(go list -f '{{if not .Doc}}{{.ImportPath}}{{end}}' ./...) | ||
for pkg in ${pkgs}; do | ||
print_error "${pkg} missing docstring" | ||
status=1 | ||
done | ||
|
||
exit ${status} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
// Package issue50 tests for 32-bit MOVD/MOVQ instruction forms. | ||
package issue50 |