X-Git-Url: https://git.madduck.net/etc/vim.git/blobdiff_plain/4d6a84a8294d035747404d00b88a925fc2640e1e..403ce1a18a8a1600ab8249d828e7eaaca442cad7:/action/entrypoint.sh?ds=sidebyside 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