File: validate-formatting.sh

package info (click to toggle)
gitlab-workhorse 7.6.0%2Bdebian-1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 7,440 kB
  • sloc: makefile: 233; sh: 161; python: 15
file content (11 lines) | stat: -rwxr-xr-x 239 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
#!/bin/sh

set -eu

IMPORT_RESULT=$(goimports -e -local "gitlab.com/gitlab-org/gitlab-workhorse" -l "$@")

if [ -n "${IMPORT_RESULT}" ]; then
  echo >&2 "Formatting or imports need fixing: 'make fmt'"
  echo "${IMPORT_RESULT}"
  exit 1
fi