memos: set version in go code

This fixes apps like Moe Memos which rely on the server properly
advertising its version (via the /api/v1/instance/profile endpoint)
This commit is contained in:
uku
2026-06-13 20:04:15 +02:00
parent b294847af6
commit 82ba60cac5
+4
View File
@@ -52,6 +52,10 @@ buildGoModule (finalAttrs: {
vendorHash = "sha256-6oJgxhGS7aD3I0umTQuVMLzcOhzf53g4TZcCtkKrrc8=";
ldflags = [
"-X github.com/usememos/memos/internal/version.Version=${finalAttrs.version}"
];
preBuild = ''
rm -rf server/router/frontend/dist
cp -r ${finalAttrs.memos-web} server/router/frontend/dist