3
0
Mirror von https://github.com/PaperMC/Paper.git synchronisiert 2024-12-15 02:50:09 +01:00

Apparently this is the correct regex.

Dieser Commit ist enthalten in:
md_5 2013-01-19 19:24:36 +11:00
Ursprung f23a5fd90a
Commit 3b88df5a42

Datei anzeigen

@ -5,7 +5,7 @@ echo "Rebuilding patch files from current fork state..."
function cleanupPatches {
cd $1
for patch in *.patch; do
lines=$(git diff --staged $patch | grep -E "^(\+|\-)" | grep -Ev "(From [a-z0-9]{32,}|--- a|+++ b)" | wc -l)
lines=$(git diff --staged $patch | grep -E "^(\+|\-)" | grep -Ev "(From [a-z0-9]{32,}|\-\-\- a|\+\+\+ b|.index)" | wc -l)
if [ "$lines" == "0" ] ; then
git reset HEAD $patch >/dev/null
git checkout -- $patch >/dev/null