diff options
Diffstat (limited to 'negative-set')
-rwxr-xr-x | negative-set | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/negative-set b/negative-set new file mode 100755 index 0000000..14c8714 --- /dev/null +++ b/negative-set @@ -0,0 +1,45 @@ +#!/bin/bash +# +# SPDX-License-Identifier: GPL-2.0 +# (c) 2020,2022, Mathieu Poirier <mathieu.poirier@linaro.org> +# +# Finds all the commits within the commit range(s) that have not been pack +# ported to a stable kernel tree. +# +# USAGE: +# $ negative-set <postive.set> <outputfilename.out> <commit range> <commit range> ... +# +# INPUT: +# $1: Output file from the command "positive-set" +# $2: Name of the ouput file +# $3: A valid kernel commit range, i.e v5.0..v5.2 or bcf876870b95..65550098c1c4 +# + +if [ $# -lt 3 ]; then + echo "Script needs at least two arguments" + exit 1 +fi + +# Make a backup of the output file if it already exists +if [ -e "$2" ]; then + mv $2 $2.bkp +fi + +# Needed by grep command in get-mainline-delta +touch $2 + +declare -i count=1 + +for arg in "$@"; do + # Skip over the stable and filename argument + if [ $count -lt 3 ]; then + count+=1 + continue + fi + echo processing $arg + git log --no-merges --no-renames --format="%H" $arg | parallel --link get-mainline-feature :::: - ::: $1 ::: $2 +done + +exit + + |