From: Georgi Gerganov Date: Wed, 3 Jan 2024 12:50:34 +0000 (+0200) Subject: scripts : allow to skip commits during sync (#678) X-Git-Tag: upstream/0.0.1642~1126 X-Git-Url: https://git.djapps.eu/?a=commitdiff_plain;h=ae29248e6bf601aace1e00c9f707ee0bc81abab2;p=pkg%2Fggml%2Fsources%2Fggml scripts : allow to skip commits during sync (#678) --- diff --git a/scripts/sync-llama-am.sh b/scripts/sync-llama-am.sh index c3caebdf..0aab3dcb 100755 --- a/scripts/sync-llama-am.sh +++ b/scripts/sync-llama-am.sh @@ -5,7 +5,7 @@ # Usage: # # $ cd /path/to/ggml -# $ ./scripts/sync-llama-am.sh +# $ ./scripts/sync-llama-am.sh -skip hash0,hash1,hash2... # set -e @@ -24,6 +24,11 @@ fi lc=$(cat $SRC_GGML/scripts/sync-llama.last) echo "Syncing llama.cpp changes since commit $lc" +to_skip="" +if [ "$1" == "-skip" ]; then + to_skip=$2 +fi + cd $SRC_LLAMA git log --oneline $lc..HEAD @@ -40,6 +45,13 @@ if [ -f $SRC_GGML/llama-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 -- \ ggml*.h \ ggml*.c \ diff --git a/scripts/sync-llama.last b/scripts/sync-llama.last index dbdf4bcc..68a5adb8 100644 --- a/scripts/sync-llama.last +++ b/scripts/sync-llama.last @@ -1 +1 @@ -7d4265af83a8a5ab1b3b90094434e130e4d4a58b +dd22e4f9081080440024b19fe97045d498e8cddf diff --git a/scripts/sync-whisper-am.sh b/scripts/sync-whisper-am.sh index bdc4d176..dcbf8ce3 100755 --- a/scripts/sync-whisper-am.sh +++ b/scripts/sync-whisper-am.sh @@ -5,7 +5,7 @@ # Usage: # # $ cd /path/to/ggml -# $ ./scripts/sync-whisper-am.sh +# $ ./scripts/sync-whisper-am.sh -skip hash0,hash1,hash2... # set -e @@ -24,6 +24,11 @@ fi lc=$(cat $SRC_GGML/scripts/sync-whisper.last) echo "Syncing whisper.cpp changes since commit $lc" +to_skip="" +if [ "$1" == "-skip" ]; then + to_skip=$2 +fi + cd $SRC_WHISPER git log --oneline $lc..HEAD @@ -40,6 +45,13 @@ if [ -f $SRC_GGML/whisper-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 -- \ ggml*.h \ ggml*.c \ diff --git a/scripts/sync-whisper.last b/scripts/sync-whisper.last index 0cc74fbe..08206346 100644 --- a/scripts/sync-whisper.last +++ b/scripts/sync-whisper.last @@ -1 +1 @@ -2623640cd6b8e077ffb1fbe3c265208da3a0ca6d +14c57952f7a53a82819bbfcfcc6a91682c66ddbf