diff --git a/flake.nix b/flake.nix index acddbedcaa..0e7efc2dee 100644 --- a/flake.nix +++ b/flake.nix @@ -20,7 +20,13 @@ { packages.default = pkgs.maven.buildMavenPackage rec { pname = "keycloak-scim"; - version = "1.0-SNAPSHOT"; + version = ( + builtins.readFile ( + pkgs.runCommand "version" { } '' + ${pkgs.coreutils}/bin/cat ${src}/pom.xml | ${pkgs.xq-xml}/bin/xq -x "project/version" | ${pkgs.coreutils}/bin/tr -d '\n' > $out + '' + ) + ); src = ./.; mvnHash = "sha256-y3ASPCAbgwSJNu4NiBeWNFc8YA903C0e5z0/TSlc3Og=";