From 33b4e0eb74fee27d8edacb581fd6eeb10cce9f4f Mon Sep 17 00:00:00 2001 From: Gregor Kleen Date: Tue, 17 Dec 2019 00:17:57 +0100 Subject: worktime --- nix/worktime.nix | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 nix/worktime.nix (limited to 'nix/worktime.nix') diff --git a/nix/worktime.nix b/nix/worktime.nix new file mode 100644 index 0000000..ddab8b2 --- /dev/null +++ b/nix/worktime.nix @@ -0,0 +1,22 @@ +{ stdenv +, python37 +}: + +stdenv.mkDerivation rec { + pname = "worktime"; + version = "3"; + src = ../worktime.py; + + phases = [ "buildPhase" "installPhase" ]; + + python = python37.withPackages (ps: with ps; [pyxdg dateutil uritools requests configparser]); + + buildPhase = '' + substituteAll $src worktime + ''; + + installPhase = '' + install -m 0755 -D -t $out/bin \ + worktime + ''; +} -- cgit v1.2.3