diff --git a/flake.lock b/flake.lock index d7dba17..44f8251 100644 --- a/flake.lock +++ b/flake.lock @@ -50,6 +50,22 @@ "type": "github" } }, + "cpufetch": { + "flake": false, + "locked": { + "lastModified": 1761985022, + "narHash": "sha256-8EgsQEZBZKv2nQhQ7lZb8ws7nifbSCULmt2THsMiSz8=", + "owner": "Dr-Noob", + "repo": "cpufetch", + "rev": "b1f20cfec6ff902975919ab6f3fd18be744f16fe", + "type": "github" + }, + "original": { + "owner": "Dr-Noob", + "repo": "cpufetch", + "type": "github" + } + }, "disko": { "inputs": { "nixpkgs": [ @@ -463,6 +479,7 @@ "root": { "inputs": { "catppuccin": "catppuccin", + "cpufetch": "cpufetch", "disko": "disko", "gh-review": "gh-review", "home-manager": "home-manager", diff --git a/flake.nix b/flake.nix index f78cca9..fabfc62 100755 --- a/flake.nix +++ b/flake.nix @@ -36,6 +36,11 @@ url = "github:Neville-Loh/gh-review"; flake = false; }; + + cpufetch = { + url = "github:Dr-Noob/cpufetch"; + flake = false; + }; }; outputs = { diff --git a/home/fish.nix b/home/fish.nix index 34d53f2..db3ffec 100644 --- a/home/fish.nix +++ b/home/fish.nix @@ -1,4 +1,13 @@ -_: { +{ + inputs, + lib, + pkgs, + ... +}: let + cpufetch = pkgs.callPackage ../packages/cpufetch.nix { + src = inputs.cpufetch; + }; +in { programs.fish = { enable = true; @@ -15,6 +24,7 @@ _: { shellAliases = { cat = "bat --paging=never"; + fullfetch = "clear; ${lib.getExe pkgs.fastfetch}; ${lib.getExe cpufetch}; ${lib.getExe pkgs.ramfetch}"; }; functions = { diff --git a/packages/cpufetch.nix b/packages/cpufetch.nix new file mode 100644 index 0000000..0e47c6e --- /dev/null +++ b/packages/cpufetch.nix @@ -0,0 +1,21 @@ +{ + lib, + stdenv, + src, +}: stdenv.mkDerivation { + pname = "cpufetch"; + version = "unstable"; + + inherit src; + + installFlags = [ + "PREFIX=$(out)" + ]; + + meta = { + description = "Simple yet fancy CPU architecture fetching tool"; + homepage = "https://github.com/Dr-Noob/cpufetch"; + license = lib.licenses.gpl2Only; + mainProgram = "cpufetch"; + }; +}