From 6f75d7058bb63f4a6800051175a428c0f437f72d Mon Sep 17 00:00:00 2001 From: Brian Hicks Date: Tue, 21 Sep 2021 12:39:46 -0500 Subject: [PATCH] add sysz --- flake.lock | 17 +++++++++++++++++ flake.nix | 21 +++++++++++++++++++++ machines/torch/default.nix | 2 ++ 3 files changed, 40 insertions(+) diff --git a/flake.lock b/flake.lock index 9fb986f..8835506 100644 --- a/flake.lock +++ b/flake.lock @@ -319,6 +319,7 @@ "shellcheck-kak": "shellcheck-kak", "similar-sort": "similar-sort", "smarttab-kak": "smarttab-kak", + "sysz": "sysz", "tmux": "tmux", "tree-grepper": "tree-grepper", "tug": "tug" @@ -381,6 +382,22 @@ "type": "github" } }, + "sysz": { + "flake": false, + "locked": { + "lastModified": 1632244394, + "narHash": "sha256-mXTQvj3UoZH2T8cGnBHvS/3LZS8iPk46+vahOD51fC4=", + "owner": "joehillen", + "repo": "sysz", + "rev": "1940582fbfe49747e3e85bb1244d2d0a376cf798", + "type": "github" + }, + "original": { + "owner": "joehillen", + "repo": "sysz", + "type": "github" + } + }, "tmux": { "flake": false, "locked": { diff --git a/flake.nix b/flake.nix index e2de21b..2e1afcf 100644 --- a/flake.nix +++ b/flake.nix @@ -36,6 +36,11 @@ flake = false; }; + sysz = { + url = "github:joehillen/sysz"; + flake = false; + }; + tmux = { url = "github:tmux/tmux/3.3-rc"; flake = false; @@ -176,6 +181,22 @@ ${final.pandoc}/bin/pandoc -s -f markdown -t man $1 | ${final.groff}/bin/groff -T utf8 -man | ${final.less}/bin/less ''; + sysz = final.stdenv.mkDerivation { + name = "sysz"; + src = inputs.sysz; + + buildPhase = "true"; + buildInputs = [ final.makeWrapper ]; + installPhase = '' + mkdir -p $out/bin + install -m755 sysz $out/bin + + wrapProgram $out/bin/sysz --prefix PATH : ${ + final.lib.makeBinPath [ final.fzf ] + } + ''; + }; + tmux = prev.tmux.overrideAttrs (attrs: attrs // { src = inputs.tmux; diff --git a/machines/torch/default.nix b/machines/torch/default.nix index 60cc792..a274593 100644 --- a/machines/torch/default.nix +++ b/machines/torch/default.nix @@ -43,6 +43,8 @@ inputs: networking.useDHCP = false; networking.interfaces.wlp3s0.useDHCP = true; + environment.systemPackages = [ pkgs.sysz ]; + # Enable CUPS to print documents. # services.printing.enable = true;