From b7c49ee517e39802a9b37a338b470764bcbc8809 Mon Sep 17 00:00:00 2001 From: deadprogram Date: Mon, 20 Oct 2025 14:40:56 +0200 Subject: [PATCH 1/7] build: perhaps a simpler way to get the latest tag Signed-off-by: deadprogram --- .github/actions/get-tag-name/action.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/actions/get-tag-name/action.yml b/.github/actions/get-tag-name/action.yml index d59d568..59a3bc0 100644 --- a/.github/actions/get-tag-name/action.yml +++ b/.github/actions/get-tag-name/action.yml @@ -18,6 +18,5 @@ runs: shell: bash run: | cd ${{ inputs.repo-path }} - BUILD_TAGS="$(git rev-list --tags --max-count=1)" - BUILD_NUMBER="$(git describe --tags $BUILD_TAGS)" + BUILD_NUMBER="$(git describe --abbrev=0 --tags)" echo "name=${BUILD_NUMBER}" >> $GITHUB_OUTPUT From e11bbb12846af828cfa37a16273f224d5a5c2e28 Mon Sep 17 00:00:00 2001 From: deadprogram Date: Mon, 20 Oct 2025 14:46:24 +0200 Subject: [PATCH 2/7] build: perhaps a simpler way to get the latest tag Signed-off-by: deadprogram --- .github/actions/get-tag-name/action.yml | 3 ++- .github/workflows/build.yml | 6 +++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/.github/actions/get-tag-name/action.yml b/.github/actions/get-tag-name/action.yml index 59a3bc0..d59d568 100644 --- a/.github/actions/get-tag-name/action.yml +++ b/.github/actions/get-tag-name/action.yml @@ -18,5 +18,6 @@ runs: shell: bash run: | cd ${{ inputs.repo-path }} - BUILD_NUMBER="$(git describe --abbrev=0 --tags)" + BUILD_TAGS="$(git rev-list --tags --max-count=1)" + BUILD_NUMBER="$(git describe --tags $BUILD_TAGS)" echo "name=${BUILD_NUMBER}" >> $GITHUB_OUTPUT diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 65d990e..e321cc0 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -41,9 +41,9 @@ jobs: git fetch --prune --prune-tags --depth=1 --no-recurse-submodules - name: Determine own tag name id: currenttag - uses: ./.github/actions/get-tag-name - with: - repo-path: . + run: | + BUILD_NUMBER="$(git describe --tags --abbrev=0)" + echo "name=${BUILD_NUMBER}" >> $GITHUB_OUTPUT - name: Save tags id: tags run: | From 168a3bed3f272126de02a047e9f867a58062639f Mon Sep 17 00:00:00 2001 From: deadprogram Date: Mon, 20 Oct 2025 14:47:43 +0200 Subject: [PATCH 3/7] build: perhaps a simpler way to get the latest tag Signed-off-by: deadprogram --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index e321cc0..7369bd9 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -38,7 +38,7 @@ jobs: repo-path: ./llama.cpp - name: Fetch tags run: | - git fetch --prune --prune-tags --depth=1 --no-recurse-submodules + git fetch --depth=10 --no-recurse-submodules - name: Determine own tag name id: currenttag run: | From 9b504addb8ec6e3256713b3de3c9331ba1d65a63 Mon Sep 17 00:00:00 2001 From: deadprogram Date: Mon, 20 Oct 2025 14:49:49 +0200 Subject: [PATCH 4/7] build: perhaps a simpler way to get the latest tag Signed-off-by: deadprogram --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 7369bd9..f9d1584 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -38,7 +38,7 @@ jobs: repo-path: ./llama.cpp - name: Fetch tags run: | - git fetch --depth=10 --no-recurse-submodules + git fetch --tags - name: Determine own tag name id: currenttag run: | From a6c571a1f6850c950e337ab20e3be1bd2c757b12 Mon Sep 17 00:00:00 2001 From: deadprogram Date: Mon, 20 Oct 2025 20:58:34 +0200 Subject: [PATCH 5/7] build: perhaps a simpler way to get the latest tag Signed-off-by: deadprogram --- .github/workflows/build.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index f9d1584..3a2f57c 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -21,6 +21,8 @@ jobs: steps: - name: Check out the repo uses: actions/checkout@v5 + with: + fetch-tags: 'true' - name: Checkout llama.cpp repo uses: actions/checkout@v5 with: From 0f568ec1a1c872c5395395b4d8963eca45f0e2f4 Mon Sep 17 00:00:00 2001 From: deadprogram Date: Mon, 20 Oct 2025 21:00:48 +0200 Subject: [PATCH 6/7] build: perhaps a simpler way to get the latest tag Signed-off-by: deadprogram --- .github/workflows/build.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 3a2f57c..acc5c8b 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -40,12 +40,12 @@ jobs: repo-path: ./llama.cpp - name: Fetch tags run: | - git fetch --tags + git fetch --prune --prune-tags --depth=5 --no-recurse-submodules - name: Determine own tag name id: currenttag - run: | - BUILD_NUMBER="$(git describe --tags --abbrev=0)" - echo "name=${BUILD_NUMBER}" >> $GITHUB_OUTPUT + uses: ./.github/actions/get-tag-name + with: + repo-path: . - name: Save tags id: tags run: | From c195f18cd0cc432d7f036eaf5d9981ad59f256c6 Mon Sep 17 00:00:00 2001 From: deadprogram Date: Mon, 20 Oct 2025 21:07:32 +0200 Subject: [PATCH 7/7] build: perhaps a simpler way to get the latest tag Signed-off-by: deadprogram --- .github/workflows/build.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index acc5c8b..6abeebd 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -40,12 +40,12 @@ jobs: repo-path: ./llama.cpp - name: Fetch tags run: | - git fetch --prune --prune-tags --depth=5 --no-recurse-submodules + git fetch --tags - name: Determine own tag name id: currenttag - uses: ./.github/actions/get-tag-name - with: - repo-path: . + run: | + BUILD_NUMBER="$(git tag -l | grep 'b*$' | sort -V)" + echo "name=${BUILD_NUMBER}" >> $GITHUB_OUTPUT - name: Save tags id: tags run: |