diff --git a/action.yml b/action.yml index 8c82922..1b25c56 100644 --- a/action.yml +++ b/action.yml @@ -18,7 +18,7 @@ inputs: prettier_options: description: Options for the 'prettier' command required: false - default: --write "**/*.js" + default: "--write '**/*.js'" branch: description: Branch which the changes are merged to required: true diff --git a/entrypoint.sh b/entrypoint.sh index 5cf2551..1233bcb 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -18,12 +18,13 @@ EOF git config --global user.name "GitHub Actions" } -echo "Installing dependencies..." -npm install --silent +echo "Installing prettier..." npm install --silent --global prettier echo "Prettifing files..." prettier $INPUT_PRETTIER_OPTIONS || echo "Problem prettifing your files" +ls + if ! git diff --quiet then echo "Commiting and pushing changes..."