about summary refs log tree commit diff stats
path: root/pkgs/by-name/ya/yambar-memory/flake.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/by-name/ya/yambar-memory/flake.nix')
-rw-r--r--pkgs/by-name/ya/yambar-memory/flake.nix35
1 files changed, 35 insertions, 0 deletions
diff --git a/pkgs/by-name/ya/yambar-memory/flake.nix b/pkgs/by-name/ya/yambar-memory/flake.nix
new file mode 100644
index 00000000..186195cc
--- /dev/null
+++ b/pkgs/by-name/ya/yambar-memory/flake.nix
@@ -0,0 +1,35 @@
+{
+  description = "A smart way to check your cpu usage";
+
+  inputs = {
+    nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
+    crane.url = "github:ipetkov/crane";
+    crane.inputs.nixpkgs.follows = "nixpkgs";
+    flake-utils.url = "github:numtide/flake-utils";
+  };
+
+  outputs = {
+    self,
+    nixpkgs,
+    crane,
+    flake-utils,
+    ...
+  }:
+    flake-utils.lib.eachDefaultSystem (system: let
+      craneLib = crane.lib.${system};
+      craneBuild = craneLib.buildPackage {
+        src = craneLib.cleanCargoSource ./.;
+
+        doCheck = true;
+      };
+    in {
+      packages.default = craneBuild;
+      legacyPackages.default = craneBuild;
+      app.default = {
+        type = "app";
+        program = "${self.packages.${system}.default}/bin/memory";
+      };
+    });
+}
+# vim: ts=2
+