mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-28 23:38:25 +01:00
Apparently this is the correct regex.
By: md_5 <md_5@live.com.au>
This commit is contained in:
parent
9ed1f633a0
commit
fe0864051c
1 changed files with 1 additions and 1 deletions
|
@ -5,7 +5,7 @@ echo "Rebuilding patch files from current fork state..."
|
||||||
function cleanupPatches {
|
function cleanupPatches {
|
||||||
cd $1
|
cd $1
|
||||||
for patch in *.patch; do
|
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
|
if [ "$lines" == "0" ] ; then
|
||||||
git reset HEAD $patch >/dev/null
|
git reset HEAD $patch >/dev/null
|
||||||
git checkout -- $patch >/dev/null
|
git checkout -- $patch >/dev/null
|
||||||
|
|
Loading…
Reference in a new issue