From e171111cc15631d1917d8a84ab2ab5b8a0c74f1f Mon Sep 17 00:00:00 2001 From: Adam Dinwoodie Date: Thu, 21 May 2026 10:14:28 +0100 Subject: [PATCH 1/2] github-copilot-cli: improve dependency handling Add glib and libsecret as dependencies for builds that might need them. Replace `autoPatchelfIgnoreMissingDeps = true` with an explicit list of the dependencies we're deliberately ignoring. GitHub Copilot CLI isn't an open source tool and the documentation isn't clear on what each possible dependency is used for. I expect some dependencies are only used in rare scenarios or would never be used by the CLI tool and are just inhereted from some of the desktop Copilot applications. That means there's a bit of a guessing game in balancing (a) the desire to provide all the tools Copilot might use and (b) not growing the package closure for no real benefit. I've added glib and libsecret as I don't think they significantly expand the closure and are relatively likely to be useful. I've left out the tools that seem most useful for GUI and media interfaces as they're bulky and seem likely to be included because they're common with GUI-based Copilot tools rather than because they're needed for GitHub Copilot CLI. Assisted-by: GitHub Copilot CLI (claude-sonnet-4.6) --- .../by-name/gi/github-copilot-cli/package.nix | 23 +++++++++++++++---- 1 file changed, 19 insertions(+), 4 deletions(-) diff --git a/pkgs/by-name/gi/github-copilot-cli/package.nix b/pkgs/by-name/gi/github-copilot-cli/package.nix index c4b3a46784bd..400951d2ca82 100644 --- a/pkgs/by-name/gi/github-copilot-cli/package.nix +++ b/pkgs/by-name/gi/github-copilot-cli/package.nix @@ -4,6 +4,8 @@ autoPatchelfHook, cacert, fetchurl, + glib, + libsecret, makeBinaryWrapper, bash, nodejs, @@ -28,12 +30,25 @@ stdenv.mkDerivation (finalAttrs: { makeBinaryWrapper ] ++ lib.optionals stdenv.hostPlatform.isLinux [ autoPatchelfHook ]; - buildInputs = lib.optionals stdenv.hostPlatform.isLinux [ stdenv.cc.cc.lib ]; + buildInputs = lib.optionals stdenv.hostPlatform.isLinux [ + stdenv.cc.cc.lib + glib + libsecret + ]; sourceRoot = "package"; dontStrip = true; - # keytar.node and computer.node have optional system-library deps not provided - # here; ignore missing deps rather than fail the build. - autoPatchelfIgnoreMissingDeps = true; + # computer.node requires GUI/media libraries (X11, pipewire, libei, libjpeg, + # libpng) for screen-capture and input-simulation features that are not + # relevant for CLI use; ignore those missing deps rather than fail the build + # or pull in heavy dependencies. + autoPatchelfIgnoreMissingDeps = [ + "libX11.so.6" + "libXtst.so.6" + "libjpeg.so.8" + "libpng16.so.16" + "libpipewire-0.3.so.0" + "libei.so.1" + ]; installPhase = '' runHook preInstall From 0669f27508ebb8b1f09623f8495ffd4c4a87f150 Mon Sep 17 00:00:00 2001 From: Adam Dinwoodie Date: Thu, 21 May 2026 10:23:54 +0100 Subject: [PATCH 2/2] github-copilot-cli: add me-and as maintainer --- pkgs/by-name/gi/github-copilot-cli/package.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/pkgs/by-name/gi/github-copilot-cli/package.nix b/pkgs/by-name/gi/github-copilot-cli/package.nix index 400951d2ca82..b71c9fd72969 100644 --- a/pkgs/by-name/gi/github-copilot-cli/package.nix +++ b/pkgs/by-name/gi/github-copilot-cli/package.nix @@ -84,6 +84,7 @@ stdenv.mkDerivation (finalAttrs: { license = lib.licenses.unfree; maintainers = with lib.maintainers; [ dbreyfogle + me-and ]; mainProgram = "copilot"; platforms = [