Explorar el Código

Align versions for local builds (#9635)

Darwin was using a different pattern for the version string
than linux or windows.
Daniel Hiltgen hace 1 mes
padre
commit
2d2247e59e
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      scripts/build_darwin.sh

+ 1 - 1
scripts/build_darwin.sh

@@ -8,7 +8,7 @@ usage() {
     exit 1
 }
 
-export VERSION=${VERSION:-$(git describe --tags --dirty)}
+export VERSION=${VERSION:-$(git describe --tags --first-parent --abbrev=7 --long --dirty --always | sed -e "s/^v//g")}
 export GOFLAGS="'-ldflags=-w -s \"-X=github.com/ollama/ollama/version.Version=${VERSION#v}\" \"-X=github.com/ollama/ollama/server.mode=release\"'"
 export CGO_CPPFLAGS='-mmacosx-version-min=11.3'