mirror of
https://github.com/weaveworks/scope.git
synced 2026-03-04 10:41:14 +00:00
shell-lint tool
This commit is contained in:
@@ -4,11 +4,15 @@ Included in this repo are tools shared by weave.git and scope.git. They include
|
|||||||
|
|
||||||
- ```cover```: a tool which merges overlapping coverage reports generated by go
|
- ```cover```: a tool which merges overlapping coverage reports generated by go
|
||||||
test
|
test
|
||||||
|
- ```files-with-type```: a tool to search directories for files of a given
|
||||||
|
MIME type
|
||||||
- ```lint```: a script to lint Go project; runs various tools like golint, go
|
- ```lint```: a script to lint Go project; runs various tools like golint, go
|
||||||
vet, errcheck etc
|
vet, errcheck etc
|
||||||
- ```rebuild-image```: a script to rebuild docker images when their input files
|
- ```rebuild-image```: a script to rebuild docker images when their input files
|
||||||
change; useful when you using docker images to build your software, but you
|
change; useful when you using docker images to build your software, but you
|
||||||
don't want to build the image every time.
|
don't want to build the image every time.
|
||||||
|
- ```shell-lint```: a script to lint multiple shell files with
|
||||||
|
[shellcheck](http://www.shellcheck.net/)
|
||||||
- ```socks```: a simple, dockerised SOCKS proxy for getting your laptop onto
|
- ```socks```: a simple, dockerised SOCKS proxy for getting your laptop onto
|
||||||
the Weave network
|
the Weave network
|
||||||
- ```test```: a script to run all go unit tests in subdirectories, gather the
|
- ```test```: a script to run all go unit tests in subdirectories, gather the
|
||||||
|
|||||||
13
shell-lint
Executable file
13
shell-lint
Executable file
@@ -0,0 +1,13 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
#
|
||||||
|
# Lint all shell files in given directories with `shellcheck`.
|
||||||
|
#
|
||||||
|
# e.g.
|
||||||
|
# $ shell-lint infra k8s
|
||||||
|
#
|
||||||
|
# Depends on:
|
||||||
|
# - shellcheck
|
||||||
|
# - files-with-type
|
||||||
|
# - file >= 5.22
|
||||||
|
|
||||||
|
"$(dirname "${BASH_SOURCE[0]}")/files-with-type" text/x-shellscript "$@" | xargs shellcheck
|
||||||
Reference in New Issue
Block a user