From bfa3ef7507b936993f84138c3d4e4fd09794b52e Mon Sep 17 00:00:00 2001 From: Alexander Heldt Date: Tue, 24 Nov 2026 18:03:24 +0100 Subject: [PATCH] pinwheel: Add rv, the review request watcher rv (alex/rv on gitea) watches GitHub for pull requests that request a review from me or from soundtrackyourbrand/content, notifies on each, and lists them in a web UI on 127.0.0.1:7778 that opens a review in its own worktree with Emacs. programs.rv runs `rv serve` as a systemd user service with the work GitHub token, on the same condition as the other GitHub-backed work tools. --- flake.lock | 22 ++++++++++++++++++++++ flake.nix | 6 ++++++ hosts/pinwheel/modules/work/default.nix | 10 ++++++++++ 3 files changed, 38 insertions(+) diff --git a/flake.lock b/flake.lock index 877bca3..58d10fe 100644 --- a/flake.lock +++ b/flake.lock @@ -931,12 +931,34 @@ "nixpkgs": "nixpkgs_3", "pppdotpm-site": "pppdotpm-site", "puppy-tracker": "puppy-tracker", + "rv": "rv", "schema": "schema", "todo": "todo", "whib-backend": "whib-backend", "whib-frontend": "whib-frontend" } }, + "rv": { + "inputs": { + "nixpkgs": [ + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1795538473, + "narHash": "sha256-vrePrHqmI/sXsJ+akFxMrAo9XKHcpr1M2ekDtrkN2k4=", + "ref": "main", + "rev": "60dd7a75094838d731e0713254cf595a0d2bfc17", + "revCount": 7, + "type": "git", + "url": "ssh://gitea@git.ppp.pm:1122/alex/rv.git" + }, + "original": { + "ref": "main", + "type": "git", + "url": "ssh://gitea@git.ppp.pm:1122/alex/rv.git" + } + }, "schema": { "inputs": { "nixpkgs": [ diff --git a/flake.nix b/flake.nix index 1212a3b..cc63f08 100644 --- a/flake.nix +++ b/flake.nix @@ -128,6 +128,12 @@ # url = "git+file:///home/alex/code/own/ct?ref=main"; inputs.nixpkgs.follows = "nixpkgs"; }; + + rv = { + url = "git+ssh://gitea@git.ppp.pm:1122/alex/rv.git?ref=main"; + # url = "git+file:///home/alex/code/own/rv?ref=main"; + inputs.nixpkgs.follows = "nixpkgs"; + }; }; outputs = diff --git a/hosts/pinwheel/modules/work/default.nix b/hosts/pinwheel/modules/work/default.nix index d179692..c4b9060 100644 --- a/hosts/pinwheel/modules/work/default.nix +++ b/hosts/pinwheel/modules/work/default.nix @@ -116,8 +116,18 @@ EOF } ]; }; + + programs.rv = lib.mkIf gitEnabled { + enable = true; + settings = { + tokenFile = config.age.secrets.work-github-token.path; + teams = [ "soundtrackyourbrand/content" ]; + }; + }; }; + home-manager.sharedModules = [ inputs.rv.homeManagerModules.default ]; + # Ensure ~/code/work is owned by alex; it was previously created as root by # agenix when secrets had a custom path there. systemd.tmpfiles.rules = [