3
0
Fork 0
mirror of https://github.com/tj-actions/changed-files synced 2025-03-05 21:06:25 +00:00

Update action.yml

This commit is contained in:
Tonye Jack 2021-05-17 04:14:23 -04:00 committed by GitHub
parent 1c561c0270
commit fe86615f16
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -104,28 +104,28 @@ runs:
do
echo "Checking for file changes: \"${path}\"..."
IFS=" "
ADDED_ARRAY+=("$(git diff --diff-filter=A --name-only "$HEAD_SHA" | grep -E "(${path})" | xargs || true)")
COPIED_ARRAY+=("$(git diff --diff-filter=C --name-only "$HEAD_SHA" | grep -E "(${path})" | xargs || true)")
DELETED_ARRAY+=("$(git diff --diff-filter=D --name-only "$HEAD_SHA" | grep -E "(${path})" | xargs || true)")
MODIFIED_ARRAY+=("$(git diff --diff-filter=M --name-only "$HEAD_SHA" | grep -E "(${path})" | xargs || true)")
RENAMED_ARRAY+=("$(git diff --diff-filter=R --name-only "$HEAD_SHA" | grep -E "(${path})" | xargs || true)")
CHANGED_ARRAY+=("$(git diff --diff-filter=T --name-only "$HEAD_SHA" | grep -E "(${path})" | xargs || true)")
UNMERGED_ARRAY+=("$(git diff --diff-filter=U --name-only "$HEAD_SHA" | grep -E "(${path})" | xargs || true)")
UNKNOWN_ARRAY+=("$(git diff --diff-filter=X --name-only "$HEAD_SHA" | grep -E "(${path})" | xargs || true)")
ALL_CHANGED_ARRAY+=("$(git diff --diff-filter="*ACDMRTUX" --name-only "$HEAD_SHA" | grep -E "(${path})" | xargs || true)")
ALL_MODIFIED_FILES_ARRAY+=("$(git diff --diff-filter="ACM" --name-only "$HEAD_SHA" | grep -E "(${path})" | xargs || true)")
ADDED_ARRAY+=($(git diff --diff-filter=A --name-only "$HEAD_SHA" | grep -E "(${path})" | xargs || true))
COPIED_ARRAY+=($(git diff --diff-filter=C --name-only "$HEAD_SHA" | grep -E "(${path})" | xargs || true))
DELETED_ARRAY+=($(git diff --diff-filter=D --name-only "$HEAD_SHA" | grep -E "(${path})" | xargs || true))
MODIFIED_ARRAY+=($(git diff --diff-filter=M --name-only "$HEAD_SHA" | grep -E "(${path})" | xargs || true))
RENAMED_ARRAY+=($(git diff --diff-filter=R --name-only "$HEAD_SHA" | grep -E "(${path})" | xargs || true))
CHANGED_ARRAY+=($(git diff --diff-filter=T --name-only "$HEAD_SHA" | grep -E "(${path})" | xargs || true))
UNMERGED_ARRAY+=($(git diff --diff-filter=U --name-only "$HEAD_SHA" | grep -E "(${path})" | xargs || true))
UNKNOWN_ARRAY+=($(git diff --diff-filter=X --name-only "$HEAD_SHA" | grep -E "(${path})" | xargs || true))
ALL_CHANGED_ARRAY+=($(git diff --diff-filter="*ACDMRTUX" --name-only "$HEAD_SHA" | grep -E "(${path})" | xargs || true))
ALL_MODIFIED_FILES_ARRAY+=($(git diff --diff-filter="ACM" --name-only "$HEAD_SHA" | grep -E "(${path})" | xargs || true))
done
ADDED=$(echo "${ADDED_ARRAY[*]}" | tr -s ' ' | sed 's/ */'"$INPUT_SEPARATOR"'/g')
COPIED=$(echo "${COPIED_ARRAY[*]}" | tr -s ' ' | sed 's/ */'"$INPUT_SEPARATOR"'/g')
DELETED=$(echo "${DELETED_ARRAY[*]}" | tr -s ' ' | sed 's/ */'"$INPUT_SEPARATOR"'/g')
MODIFIED=$(echo "${MODIFIED_ARRAY[*]}" | tr -s ' ' | sed 's/ */'"$INPUT_SEPARATOR"'/g')
RENAMED=$(echo "${RENAMED_ARRAY[*]}" | tr -s ' ' | sed 's/ */'"$INPUT_SEPARATOR"'/g')
CHANGED=$(echo "${CHANGED_ARRAY[*]}" | tr -s ' ' | sed 's/ */'"$INPUT_SEPARATOR"'/g')
UNMERGED=$(echo "${UNMERGED_ARRAY[*]}" | tr -s ' ' | sed 's/ */'"$INPUT_SEPARATOR"'/g')
UNKNOWN=$(echo "${UNKNOWN_ARRAY[*]}" | tr -s ' ' | sed 's/ */'"$INPUT_SEPARATOR"'/g')
ALL_CHANGED=$(echo "${ALL_CHANGED_ARRAY[*]}" | tr -s ' ' | sed 's/ */'"$INPUT_SEPARATOR"'/g')
ALL_MODIFIED_FILES=$(echo "${ALL_MODIFIED_FILES_ARRAY[*]}" | tr -s ' ' | sed 's/ */'"$INPUT_SEPARATOR"'/g')
ADDED=$(echo "${ADDED_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g')
COPIED=$(echo "${COPIED_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g')
DELETED=$(echo "${DELETED_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g')
MODIFIED=$(echo "${MODIFIED_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g')
RENAMED=$(echo "${RENAMED_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g')
CHANGED=$(echo "${CHANGED_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g')
UNMERGED=$(echo "${UNMERGED_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g')
UNKNOWN=$(echo "${UNKNOWN_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g')
ALL_CHANGED=$(echo "${ALL_CHANGED_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g')
ALL_MODIFIED_FILES=$(echo "${ALL_MODIFIED_FILES_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g')
fi
fi