diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2020-04-09 14:55:45 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-04-09 14:55:45 +0200 |
commit | 555b30e9ebdf82dfc2e0c7ddd9f0f8b51ccb4a39 (patch) | |
tree | e56d6b21c07df5e3a442ed423a6d6cba8d22247f /hack/golangci-lint.sh | |
parent | 655139fdda20819160b2baad840429a80d6285e5 (diff) | |
parent | e0847f5457edfdeb17dad259f1cd06b1d4cec93e (diff) | |
download | podman-555b30e9ebdf82dfc2e0c7ddd9f0f8b51ccb4a39.tar.gz podman-555b30e9ebdf82dfc2e0c7ddd9f0f8b51ccb4a39.tar.bz2 podman-555b30e9ebdf82dfc2e0c7ddd9f0f8b51ccb4a39.zip |
Merge pull request #5634 from jwhonce/wip/service
V2 podman system service
Diffstat (limited to 'hack/golangci-lint.sh')
-rwxr-xr-x | hack/golangci-lint.sh | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/hack/golangci-lint.sh b/hack/golangci-lint.sh new file mode 100755 index 000000000..385b21f39 --- /dev/null +++ b/hack/golangci-lint.sh @@ -0,0 +1,15 @@ +#!/bin/bash -e + +# Need to run linter twice to cover all the build tags code paths + +declare -A BUILD_TAGS +BUILD_TAGS[default]="apparmor,seccomp,selinux" +BUILD_TAGS[abi]="${BUILD_TAGS[default]},ABISupport,varlink,!remoteclient" +BUILD_TAGS[tunnel]="${BUILD_TAGS[default]},!ABISupport,!varlink,remoteclient" + +[[ $1 == run ]] && shift + +for i in tunnel abi; do + echo Build Tags: ${BUILD_TAGS[$i]} + golangci-lint run --build-tags=${BUILD_TAGS[$i]} "$@" +done |