From 86748bd806764905768615b0806eef3bc2e66f94 Mon Sep 17 00:00:00 2001 From: ludeeus Date: Sat, 9 Mar 2019 11:25:14 +0100 Subject: [PATCH] init --- .github/main.workflow | 16 ++++++++++++++++ Dockerfile | 16 ++++++++++++++++ README.md | 24 ++++++++++++++++++++++++ runaction.sh | 4 ++++ 4 files changed, 60 insertions(+) create mode 100644 .github/main.workflow create mode 100644 Dockerfile create mode 100644 README.md create mode 100644 runaction.sh diff --git a/.github/main.workflow b/.github/main.workflow new file mode 100644 index 0000000..a457525 --- /dev/null +++ b/.github/main.workflow @@ -0,0 +1,16 @@ +workflow "Trigger: Push" { + on = "push" + resolves = [ + "Shellcheck", + "Black Code Formatter", + ] +} + +action "Shellcheck" { + uses = "ludeeus/action-shellcheck@master" +} + +action "Black Code Formatter" { + uses = "lgeiger/black-action@master" + args = "$GITHUB_WORKSPACE --check" +} \ No newline at end of file diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..a1d7172 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,16 @@ +FROM debian:latest + +COPY runaction.sh /runaction.sh +RUN chmod +x /runaction.sh +RUN apt update +RUN apt install -y shellcheck + +ENTRYPOINT ["/runaction.sh"] + +LABEL "name"="shellcheck" +LABEL "maintainer"="Ludeeus " +LABEL "version"="0.0.1" +LABEL "com.github.actions.name"="shellcheck" +LABEL "com.github.actions.description"="Run shell check on ALL sh files in the repository." +LABEL "com.github.actions.icon"="terminal" +LABEL "com.github.actions.color"="black" diff --git a/README.md b/README.md new file mode 100644 index 0000000..f5f47d4 --- /dev/null +++ b/README.md @@ -0,0 +1,24 @@ +# SHELLCHECK + +[![BuyMeCoffee][buymecoffeebedge]][buymecoffee] + +_Run shellcheck on ALL sh files in the repository._ + +## Example + +``` +workflow "Shellcheck" { + on = "push" + resolves = [ + "Shellcheck", + ] +} + + +action "Shellcheck" { + uses = "ludeeus/actions/shellcheck@master" +} +``` + +[buymecoffee]: https://www.buymeacoffee.com/ludeeus +[buymecoffeebedge]: https://camo.githubusercontent.com/cd005dca0ef55d7725912ec03a936d3a7c8de5b5/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6275792532306d6525323061253230636f666665652d646f6e6174652d79656c6c6f772e737667 diff --git a/runaction.sh b/runaction.sh new file mode 100644 index 0000000..c0b48ca --- /dev/null +++ b/runaction.sh @@ -0,0 +1,4 @@ +#!/bin/bash + +cd "$GITHUB_WORKSPACE" || exit 1 +find . -name \*.sh -exec shellcheck {} + \ No newline at end of file