From 704b8e577ab5b59254d3df25579bf4ef663dc622 Mon Sep 17 00:00:00 2001 From: Alexander Miroshnichenko Date: Mon, 28 Sep 2026 15:30:31 +0300 Subject: [PATCH] feat(open-code-review): expose ocr alias for the CLI binary Upstream and the bundled OpenCode plugin invoke the tool as `ocr`, but the Go build names the binary after its cmd/ directory (`opencodereview`), so the CLI was missing from PATH under the name everything expects. --- packages/open-code-review/package.nix | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/packages/open-code-review/package.nix b/packages/open-code-review/package.nix index fed2db4..7cb8443 100644 --- a/packages/open-code-review/package.nix +++ b/packages/open-code-review/package.nix @@ -24,6 +24,12 @@ buildGoModule rec { doCheck = false; + # Upstream (and the bundled OpenCode plugin) invokes the CLI as `ocr`, but the + # Go build names the binary after its cmd/ directory. + postInstall = '' + ln -s $out/bin/opencodereview $out/bin/ocr + ''; + ldflags = [ "-s" "-w"