From 26b20f4f83599d507d9eb4f3ed291e77728788df Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Tue, 9 Feb 2016 00:18:07 -0200 Subject: [PATCH] Update README.md --- README.md | 30 ++++++++++++++++++++++++------ 1 file changed, 24 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index d361bb6..6a67124 100644 --- a/README.md +++ b/README.md @@ -5,13 +5,31 @@ on [caarlos0/shell-ci-build](https://github.com/caarlos0/shell-ci-build). ## How to +### Check your scripts + ```console -# build the image: -$ docker build -t shellcheck . +$ docker run \ + -v /folder/with/my/scripts:/tmp \ + -t caarlos0/shellcheck \ + sh -c 'shellcheck /tmp/*.sh' +``` + +### Copy the binary to outside -# run it locally against your scripts: -$ docker run -v /folder/with/my/scripts:/tmp -t shellcheck sh -c 'shellcheck /tmp/*.sh' +So you can use in it any ubuntu machine, travis machines, for example, +as I do in [caarlos0/shell-ci-build](https://github.com/caarlos0/shell-ci-build). -# copy the binary to outside, so it can be used in any ubuntu machine: -$ docker run -v `pwd`:/tmp -t shellcheck cp -f /usr/bin/shellcheck /tmp/ +``` +$ docker run \ + -v `pwd`:/tmp \ + -t caarlos0/shellcheck \ + cp -f /usr/bin/shellcheck /tmp/ +``` + +### Build + +Not really needed unless you change something, as this repo is an automated Docker hub build. + +```console +$ docker build -t caarlos0/shellcheck . ```