From: Georgi Gerganov Date: Sun, 14 Jan 2024 08:53:19 +0000 (+0200) Subject: scripts : sync-ggml-am.sh add option to skip commits X-Git-Tag: upstream/1.7.4~1114 X-Git-Url: https://git.djapps.eu/?a=commitdiff_plain;h=654baf693d6d343585e6a014c3c20674754c64d1;p=pkg%2Fggml%2Fsources%2Fwhisper.cpp scripts : sync-ggml-am.sh add option to skip commits --- diff --git a/extra/sync-ggml-am.sh b/extra/sync-ggml-am.sh index 25f53729..a88418c4 100755 --- a/extra/sync-ggml-am.sh +++ b/extra/sync-ggml-am.sh @@ -5,7 +5,7 @@ # Usage: # # $ cd /path/to/whisper.cpp -# $ ./extra/sync-ggml-am.sh +# $ ./extra/sync-ggml-am.sh -skip hash0,hash1,hash2... # set -e @@ -24,6 +24,11 @@ fi lc=$(cat $SRC_WHISPER/extra/sync-ggml.last) echo "Syncing ggml changes since commit $lc" +to_skip="" +if [ "$1" == "-skip" ]; then + to_skip=$2 +fi + cd $SRC_GGML git log --oneline $lc..HEAD @@ -40,6 +45,13 @@ if [ -f $SRC_WHISPER/ggml-src.patch ]; then fi while read c; do + if [ -n "$to_skip" ]; then + if [[ $to_skip == *"$c"* ]]; then + echo "Skipping $c" + continue + fi + fi + git format-patch -k $c~1..$c --stdout -- \ include/ggml/ggml*.h \ src/ggml*.h \