diff --git a/default.nix b/default.nix index b1c3e0b..0759fd3 100644 --- a/default.nix +++ b/default.nix @@ -1,8 +1,8 @@ -{ pythonPackages }: +{ pythonPackages, rev ? "local" }: pythonPackages.buildPythonApplication rec { pname = "selfprivacy-graphql-api"; - version = "local"; + version = rev; src = builtins.filterSource (p: t: p != ".git" && t != "symlink") ./.; propagatedBuildInputs = with pythonPackages; [ fastapi diff --git a/flake.nix b/flake.nix index 75391ba..568b7ff 100644 --- a/flake.nix +++ b/flake.nix @@ -9,6 +9,7 @@ pkgs = nixpkgs.legacyPackages.${system}; selfprivacy-graphql-api = pkgs.callPackage ./default.nix { pythonPackages = pkgs.python310Packages; + rev = self.shortRev or self.dirtyShortRev or "dirty"; }; in {