mirror of
https://github.com/armbian/build
synced 2025-09-24 19:47:06 +07:00
mk_format_patch: Copy only those patches that have changes in chunks
This commit is contained in:
@@ -25,10 +25,17 @@ ii_cp()
|
||||
local new_p=$1
|
||||
local old_p=$2
|
||||
|
||||
# Patches can be extracted in several ways.
|
||||
# Copy only those patches that have changes in chunks,
|
||||
# line numbers, or source text.
|
||||
# Ignore lines that may be changed by another method
|
||||
# of extracting (creating) the patch.
|
||||
if [ "$(diff -N \
|
||||
--ignore-matching-lines="^From [0-9a-f]\{40\}" \
|
||||
--ignore-matching-lines="^index [0-9a-f]\{7\}" \
|
||||
--ignore-matching-lines="^Subject:" \
|
||||
--ignore-matching-lines='/.*/* |[ ][ 1-9]' \
|
||||
--ignore-matching-lines='^Armbian$' \
|
||||
--ignore-matching-lines="^[2-3].[1-9][0-9]" \
|
||||
$old_p $new_p 2>/dev/null)" != "" ]
|
||||
then
|
||||
@@ -170,7 +177,7 @@ then
|
||||
prefix=""
|
||||
|
||||
$(git -C $url_t \
|
||||
format-patch --filename-max-length=75 $range \
|
||||
format-patch --filename-max-length=75 --abbrev=12 $range \
|
||||
-o $tmp_dir/$target_name
|
||||
) 2>/dev/null
|
||||
|
||||
|
||||
Reference in New Issue
Block a user