X-Git-Url: https://git.madduck.net/etc/vim.git/blobdiff_plain/4d6a84a8294d035747404d00b88a925fc2640e1e..62bfbd6a63dcac2f6f31eb014f69397c9eb967d2:/action/entrypoint.sh diff --git a/action/entrypoint.sh b/action/entrypoint.sh index dc86fa1..30bf4eb 100755 --- a/action/entrypoint.sh +++ b/action/entrypoint.sh @@ -1,10 +1,9 @@ -#!/bin/sh -set -e +#!/bin/bash -e -if [ $# -eq 0 ]; then - # Default (if no args provided). - sh -c "black . --check --diff" -else - # Custom args. - sh -c "black $*" +if [ -n "$INPUT_BLACK_ARGS" ]; then + echo '::warning::Input `with.black_args` is deprecated. Use `with.options` and `with.src` instead.' + black $INPUT_BLACK_ARGS + exit $? fi + +black $INPUT_OPTIONS $INPUT_SRC