Skip to content
This repository was archived by the owner on Aug 25, 2024. It is now read-only.

Commit 8ad17e9

Browse files
committed
ci: remove images: Do not give branch name on first log --stat
Signed-off-by: John Andersen <[email protected]>
1 parent a3921c6 commit 8ad17e9

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

.github/workflows/remove_images.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,15 +32,17 @@ jobs:
3232
git fetch origin $BRANCH
3333
git reset --hard origin/$BRANCH
3434
git log -n 3 --oneline
35-
git log --stat $BRANCH | grep -E '\.png|\.jpeg|\.jpg|\.gif'
35+
git log --stat | grep -E '\.png|\.jpeg|\.jpg|\.gif'
3636
cat > $GIT_FILTER_REPO_PATHS <<'EOF'
3737
glob:*.gif
3838
glob:*.png
3939
glob:*.jpg
4040
glob:*.jpeg
4141
EOF
4242
git filter-repo --force --invert-paths --paths-from-file $GIT_FILTER_REPO_PATHS
43+
set +e
4344
git log --stat | grep -E '\.png|\.jpeg|\.jpg|\.gif'
45+
set -e
4446
4547
export GIT_SSH_COMMAND='ssh -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no'
4648

0 commit comments

Comments
 (0)