From c154cc6a77695d4483937745499e07fee62addd3 Mon Sep 17 00:00:00 2001 From: Tonye Jack Date: Sat, 6 Nov 2021 11:27:52 -0400 Subject: [PATCH] CRLF/LF support for all platforms (#103) * CRLF/LF support for all platforms * Update action.yml * Update action.yml * Update entrypoint.sh --- action.yml | 1 + entrypoint.sh | 6 +++++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/action.yml b/action.yml index 86d0a17..e0f2d9c 100644 --- a/action.yml +++ b/action.yml @@ -26,6 +26,7 @@ runs: id: verify-changed-files shell: bash env: + PLATFORM: ${{ runner.os }} GITHUB_SERVER_URL: ${{ github.server_url }} GITHUB_REPOSITORY: ${{ github.repository }} # INPUT_ is not available in Composite run steps diff --git a/entrypoint.sh b/entrypoint.sh index 57f74fa..f92eee8 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -2,7 +2,11 @@ set -e -git config core.autocrlf true +if [[ "$PLATFORM" == 'Windows' ]]; then + git config core.autocrlf true +else + git config core.autocrlf input +fi CHANGED_FILES=()