]> git.djapps.eu Git - pkg/ggml/sources/ggml/commitdiff
ggml : remove -dev suffix from release version (#1355)
authorDaniel Bevenius <redacted>
Fri, 26 Sep 2025 15:34:42 +0000 (17:34 +0200)
committerGitHub <redacted>
Fri, 26 Sep 2025 15:34:42 +0000 (17:34 +0200)
This commit removes the `-dev` suffix from the version string in
CMakeLists.txt and the release script. The version will now be
just be formatted as `MAJOR.MINOR.PATCH`.

CMakeLists.txt
scripts/release.sh

index 315a06df2da31778865537fa14589d403f01b5a4..0bb2daa7f7a134268190e36b0b96c1559b6646f0 100644 (file)
@@ -5,7 +5,6 @@ project("ggml" C CXX ASM)
 set(GGML_VERSION_MAJOR 0)
 set(GGML_VERSION_MINOR 9)
 set(GGML_VERSION_PATCH 3)
-set(GGML_VERSION_DEV "")  # "-dev" for development, "" for releases
 set(GGML_VERSION_BASE "${GGML_VERSION_MAJOR}.${GGML_VERSION_MINOR}.${GGML_VERSION_PATCH}")
 
 find_program(GIT_EXE NAMES git git.exe NO_CMAKE_FIND_ROOT_PATH)
@@ -26,8 +25,8 @@ if(GIT_EXE)
     )
 endif()
 
-# Build the version string with optional -dev suffix and dirty flag
-set(GGML_VERSION "${GGML_VERSION_BASE}${GGML_VERSION_DEV}")
+# Build the version string with optional dirty flag
+set(GGML_VERSION "${GGML_VERSION_BASE}")
 if(GGML_GIT_DIRTY AND NOT GGML_GIT_DIRTY EQUAL 0)
     set(GGML_VERSION "${GGML_VERSION}-dirty")
 endif()
index ed1b54ba51875ff0df05a776695e9d1f92694655..222063eafff74cc8321aed12679ddee6bd1c7e53 100755 (executable)
@@ -159,7 +159,7 @@ prepare_release() {
     MINOR=$(grep "set(GGML_VERSION_MINOR" CMakeLists.txt | sed 's/.*MINOR \([0-9]*\).*/\1/')
     PATCH=$(grep "set(GGML_VERSION_PATCH" CMakeLists.txt | sed 's/.*PATCH \([0-9]*\).*/\1/')
 
-    echo "Current version: $MAJOR.$MINOR.$PATCH-dev"
+    echo "Current version: $MAJOR.$MINOR.$PATCH"
 
     # Calculate new version
     case $VERSION_TYPE in
@@ -202,12 +202,10 @@ prepare_release() {
         echo "  [dry-run] Would update GGML_VERSION_MAJOR to $NEW_MAJOR"
         echo "  [dry-run] Would update GGML_VERSION_MINOR to $NEW_MINOR"
         echo "  [dry-run] Would update GGML_VERSION_PATCH to $NEW_PATCH"
-        echo "  [dry-run] Would remove -dev suffix"
     else
         sed -i'' -e "s/set(GGML_VERSION_MAJOR [0-9]*)/set(GGML_VERSION_MAJOR $NEW_MAJOR)/" CMakeLists.txt
         sed -i'' -e "s/set(GGML_VERSION_MINOR [0-9]*)/set(GGML_VERSION_MINOR $NEW_MINOR)/" CMakeLists.txt
         sed -i'' -e "s/set(GGML_VERSION_PATCH [0-9]*)/set(GGML_VERSION_PATCH $NEW_PATCH)/" CMakeLists.txt
-        sed -i'' -e 's/set(GGML_VERSION_DEV "-dev")/set(GGML_VERSION_DEV "")/' CMakeLists.txt
     fi
     echo ""
 
@@ -251,17 +249,11 @@ finalize_release() {
     check_master_branch
     check_master_up_to_date
 
-    # Read current version from CMakeLists.txt (should not have -dev suffix)
+    # Read current version from CMakeLists.txt
     echo "Step 1: Reading current release version..."
     MAJOR=$(grep "set(GGML_VERSION_MAJOR" CMakeLists.txt | sed 's/.*MAJOR \([0-9]*\).*/\1/')
     MINOR=$(grep "set(GGML_VERSION_MINOR" CMakeLists.txt | sed 's/.*MINOR \([0-9]*\).*/\1/')
     PATCH=$(grep "set(GGML_VERSION_PATCH" CMakeLists.txt | sed 's/.*PATCH \([0-9]*\).*/\1/')
-    DEV_SUFFIX=$(grep "set(GGML_VERSION_DEV" CMakeLists.txt | sed 's/.*DEV "\([^"]*\)".*/\1/')
-
-    if [ "$DEV_SUFFIX" = "-dev" ]; then
-        echo "Error: Current version still has -dev suffix. Make sure the release candidate PR has been merged."
-        exit 1
-    fi
 
     RELEASE_VERSION="$MAJOR.$MINOR.$PATCH"
     echo "Release version: $RELEASE_VERSION"
@@ -277,54 +269,18 @@ finalize_release() {
     fi
     echo ""
 
-    # Create branch for next development version
-    DEV_BRANCH="ggml-dev-v$RELEASE_VERSION"
-    echo "Step 3: Creating development branch..."
-    if [ "$DRY_RUN" = true ]; then
-        echo "  [dry-run] Would create branch: $DEV_BRANCH"
-    else
-        git checkout -b "$DEV_BRANCH"
-        echo "✓ Created and switched to branch: $DEV_BRANCH"
-    fi
-    echo ""
-
-    # Add -dev suffix back (no version increment)
-    NEXT_DEV_VERSION="$RELEASE_VERSION-dev"
-    echo "Step 4: Adding -dev suffix for next development cycle ($NEXT_DEV_VERSION)..."
-    if [ "$DRY_RUN" = true ]; then
-        echo "  [dry-run] Would add -dev suffix"
-    else
-        sed -i'' -e 's/set(GGML_VERSION_DEV "")/set(GGML_VERSION_DEV "-dev")/' CMakeLists.txt
-    fi
-    echo ""
-
-    # Commit development version
-    echo "Step 5: Committing development version..."
-    if [ "$DRY_RUN" = true ]; then
-        echo "  [dry-run] Would commit: 'ggml : prepare for development of $NEXT_DEV_VERSION'"
-    else
-        git add CMakeLists.txt
-        git commit -m "ggml : prepare for development of $NEXT_DEV_VERSION"
-    fi
-    echo ""
 
     echo ""
     if [ "$DRY_RUN" = true ]; then
         echo "[dry-run] Summary (no changes were made):"
         echo "  • Would have created tag: v$RELEASE_VERSION"
-        echo "  • Would have created branch: $DEV_BRANCH"
-        echo "  • Would have prepared next development version: $NEXT_DEV_VERSION"
     else
         echo "Release finalization completed!"
         echo "Summary:"
         echo "  • Created signed tag: v$RELEASE_VERSION"
-        echo "  • Created branch: $DEV_BRANCH"
-        echo "  • Prepared next development version: $NEXT_DEV_VERSION"
         echo ""
         echo "Next steps:"
         echo "  • Push tag to remote: git push origin v$RELEASE_VERSION"
-        echo "  • Push development branch: git push origin $DEV_BRANCH"
-        echo "  • Create PR for development version manually"
         echo "  • The release is now complete!"
     fi
 }