diff options
author | Nick Thomas <nick@gitlab.com> | 2019-10-17 12:26:08 +0100 |
---|---|---|
committer | Nick Thomas <nick@gitlab.com> | 2019-10-18 11:47:25 +0100 |
commit | ede41ee451dd0aa6d0ecd958c7fadbdb3b63f3e4 (patch) | |
tree | 0f80f7394231d39970f23a08ba9ba2ce7051e22c /support/go-format | |
parent | ff46222a3a75467d6b22c94abb09a3bb6be60623 (diff) | |
download | gitlab-shell-ede41ee451dd0aa6d0ecd958c7fadbdb3b63f3e4.tar.gz |
Simplify building and testing the Go components
Diffstat (limited to 'support/go-format')
-rwxr-xr-x | support/go-format | 16 |
1 files changed, 0 insertions, 16 deletions
diff --git a/support/go-format b/support/go-format deleted file mode 100755 index 59af23c..0000000 --- a/support/go-format +++ /dev/null @@ -1,16 +0,0 @@ -#!/usr/bin/env ruby - -def main(check) - go_files = Dir['go/**/*.go'] - cmd = %w[gofmt -s -l] - cmd << '-w' unless check - cmd += go_files - output = IO.popen(cmd, 'r', &:read) - $stdout.write(output) - abort 'gofmt failed' unless $?.success? - if check && output.lines.any? { |l| l != "\n" } - abort "\nPlease run #{$0} to fix formatting" - end -end - -main(ARGV.first == 'check') |