0
1
Fork 0
mirror of https://github.com/actions/checkout synced 2024-07-03 16:52:39 +02:00
checkout/__test__/verify-fetch-filter.sh

16 lines
420 B
Bash
Raw Normal View History

2023-06-30 18:12:38 +02:00
#!/bin/bash
# Verify .git folder
if [ ! -d "./fetch-filter/.git" ]; then
echo "Expected ./fetch-filter/.git folder to exist"
exit 1
fi
# Verify .git/config contains partialclonefilter
CLONE_FILTER=$(git config --local --get remote.origin.partialclonefilter)
if [ "$CLONE_FILTER" != "blob:none" ]; then
echo "Expected ./fetch-filter/.git/config to have 'remote.origin.partialclonefilter' set to 'blob:none'"
fi