keep default.nix in sync

This commit is contained in:
2025-11-26 16:08:38 -08:00
parent 64647f77b0
commit 6d1b7f8e56

View File

@@ -5,9 +5,17 @@
installShellFiles,
...
}:
let
cmakeContent = builtins.readFile ./CMakeLists.txt;
cmakeLines = lib.splitString "\n" cmakeContent;
# Find the line containing set(KE_VERSION "...")
versionLine = lib.findFirst (l: builtins.match ".*set\\(KE_VERSION \".+\"\\).*" l != null) (throw "KE_VERSION not found in CMakeLists.txt") cmakeLines;
# Extract the version number
version = builtins.head (builtins.match ".*set\\(KE_VERSION \"(.+)\"\\).*" versionLine);
in
stdenv.mkDerivation {
pname = "ke";
version = "1.5.1";
inherit version;
src = lib.cleanSource ./.;