about summary refs log tree commit diff
diff options
context:
space:
mode:
authorMarco Burro <marcoburro98@gmail.com>2024-04-18 11:11:10 +0200
committerMarco Burro <marcoburro98@gmail.com>2024-04-18 11:11:10 +0200
commitec9dc94cdaed06942fd2b4109a4238d944782627 (patch)
tree4f566681be8e33d96c600186b02163cf5b115802
parent319c87362fba17225e677c277256b50a8062c63b (diff)
trak: suggested refactoring
-rw-r--r--pkgs/by-name/tr/trak/package.nix26
1 files changed, 12 insertions, 14 deletions
diff --git a/pkgs/by-name/tr/trak/package.nix b/pkgs/by-name/tr/trak/package.nix
index df74077ec8da8..5197366023784 100644
--- a/pkgs/by-name/tr/trak/package.nix
+++ b/pkgs/by-name/tr/trak/package.nix
@@ -8,16 +8,14 @@ python3Packages.buildPythonApplication rec {
   version = "0.0.4";
   pyproject = true;
 
-  src =
-    let
-      repo = fetchFromGitHub {
-        owner = "lcfd";
-        repo = "trak";
-        rev = "v${version}";
-        hash = "sha256-Lc5/i/OuAwHoPo8SeBZe+JSstZov8K/ku7EMyb2I9Ng=";
-      };
-    in
-    "${repo}/cli";
+  src = fetchFromGitHub {
+    owner = "lcfd";
+    repo = "trak";
+    rev = "v${version}";
+    hash = "sha256-Lc5/i/OuAwHoPo8SeBZe+JSstZov8K/ku7EMyb2I9Ng=";
+  };
+
+  sourceRoot = "${src.name}/cli";
 
   propagatedBuildInputs = with python3Packages; [
     typer
@@ -25,11 +23,11 @@ python3Packages.buildPythonApplication rec {
 
   build-system = [ python3Packages.poetry-core ];
 
-  meta = with lib; {
-    description = "Keep a record of the time you dedicate to your projects.";
+  meta = {
+    description = "Keep a record of the time you dedicate to your projects";
     homepage = "https://github.com/lcfd/trak";
-    license = licenses.agpl3Only;
-    maintainers = with maintainers; [ buurro ];
+    license = lib.licenses.agpl3Only;
+    maintainers = with lib.maintainers; [ buurro ];
     mainProgram = "trak";
   };
 }