about summary refs log tree commit diff
path: root/pkgs/tools
diff options
context:
space:
mode:
authorh7x4 <h7x4@nani.wtf>2023-11-23 22:09:35 +0100
committerBjørn Forsman <bjorn.forsman@gmail.com>2023-11-24 21:01:03 +0100
commit12315f53ff6afad470ece13a666c21dd8aad770f (patch)
treeef19ddaac26575ed4cbb5887b528c6e0aa6a20ab /pkgs/tools
parent14caf2eb45eebce6a8b6289882546bea6beba321 (diff)
treewide: add mainProgram
Diffstat (limited to 'pkgs/tools')
-rw-r--r--pkgs/tools/X11/alttab/default.nix1
-rw-r--r--pkgs/tools/X11/autocutsel/default.nix1
-rw-r--r--pkgs/tools/X11/bgs/default.nix1
-rw-r--r--pkgs/tools/X11/ckbcomp/default.nix1
-rw-r--r--pkgs/tools/X11/devour/default.nix1
-rw-r--r--pkgs/tools/X11/dex/default.nix1
-rw-r--r--pkgs/tools/X11/dispad/default.nix1
-rw-r--r--pkgs/tools/X11/ffcast/default.nix1
-rw-r--r--pkgs/tools/X11/find-cursor/default.nix1
-rw-r--r--pkgs/tools/X11/gobble/default.nix1
-rw-r--r--pkgs/tools/X11/grobi/default.nix1
-rw-r--r--pkgs/tools/X11/icon-slicer/default.nix1
-rw-r--r--pkgs/tools/X11/imwheel/default.nix1
-rw-r--r--pkgs/tools/X11/inputplug/default.nix1
-rw-r--r--pkgs/tools/X11/kdocker/default.nix1
-rw-r--r--pkgs/tools/X11/keynav/default.nix1
-rw-r--r--pkgs/tools/X11/ksuperkey/default.nix1
-rw-r--r--pkgs/tools/X11/nitrogen/default.nix1
-rw-r--r--pkgs/tools/X11/obconf/default.nix1
-rw-r--r--pkgs/tools/X11/paperview/default.nix1
-rw-r--r--pkgs/tools/X11/pmenu/default.nix1
-rw-r--r--pkgs/tools/X11/ratmen/default.nix1
-rw-r--r--pkgs/tools/X11/run-scaled/default.nix1
-rw-r--r--pkgs/tools/X11/sbs/default.nix1
-rw-r--r--pkgs/tools/X11/setroot/default.nix1
-rw-r--r--pkgs/tools/X11/smart-wallpaper/default.nix1
-rw-r--r--pkgs/tools/X11/srandrd/default.nix1
-rw-r--r--pkgs/tools/X11/sselp/default.nix1
-rw-r--r--pkgs/tools/X11/sx/default.nix1
-rw-r--r--pkgs/tools/X11/vdpauinfo/default.nix1
-rw-r--r--pkgs/tools/X11/wayv/default.nix1
-rw-r--r--pkgs/tools/X11/wmctrl/default.nix1
-rw-r--r--pkgs/tools/X11/x11vnc/default.nix1
-rw-r--r--pkgs/tools/X11/x2vnc/default.nix1
-rw-r--r--pkgs/tools/X11/x2x/default.nix1
-rw-r--r--pkgs/tools/X11/xannotate/default.nix1
-rw-r--r--pkgs/tools/X11/xbanish/default.nix1
-rw-r--r--pkgs/tools/X11/xbindkeys-config/default.nix1
-rw-r--r--pkgs/tools/X11/xborders/default.nix1
-rw-r--r--pkgs/tools/X11/xbrightness/default.nix1
-rw-r--r--pkgs/tools/X11/xcalib/default.nix1
-rw-r--r--pkgs/tools/X11/xcape/default.nix1
-rw-r--r--pkgs/tools/X11/xchainkeys/default.nix1
-rw-r--r--pkgs/tools/X11/xcwd/default.nix1
-rw-r--r--pkgs/tools/X11/xdotool/default.nix1
-rw-r--r--pkgs/tools/X11/xgeometry-select/default.nix1
-rw-r--r--pkgs/tools/X11/xinput_calibrator/default.nix1
-rw-r--r--pkgs/tools/X11/xkb-switch-i3/default.nix1
-rw-r--r--pkgs/tools/X11/xkb-switch/default.nix1
-rw-r--r--pkgs/tools/X11/xkbset/default.nix1
-rw-r--r--pkgs/tools/X11/xkbvalidate/default.nix1
-rw-r--r--pkgs/tools/X11/xlayoutdisplay/default.nix1
-rw-r--r--pkgs/tools/X11/xlogo/default.nix1
-rw-r--r--pkgs/tools/X11/xmcp/default.nix1
-rw-r--r--pkgs/tools/X11/xmousepasteblock/default.nix1
-rw-r--r--pkgs/tools/X11/xnotify/default.nix1
-rw-r--r--pkgs/tools/X11/xob/default.nix1
-rw-r--r--pkgs/tools/X11/xplugd/default.nix1
-rw-r--r--pkgs/tools/X11/xpointerbarrier/default.nix1
-rw-r--r--pkgs/tools/X11/xprintidle-ng/default.nix1
-rw-r--r--pkgs/tools/X11/xprintidle/default.nix1
-rw-r--r--pkgs/tools/X11/xprompt/default.nix1
-rw-r--r--pkgs/tools/X11/xrectsel/default.nix1
-rw-r--r--pkgs/tools/X11/xrestop/default.nix1
-rw-r--r--pkgs/tools/X11/xtrace/default.nix1
-rw-r--r--pkgs/tools/X11/xtruss/default.nix1
-rw-r--r--pkgs/tools/X11/xvkbd/default.nix1
-rw-r--r--pkgs/tools/X11/xwallpaper/default.nix1
-rw-r--r--pkgs/tools/X11/xwinmosaic/default.nix1
-rw-r--r--pkgs/tools/X11/xwinwrap/default.nix1
-rw-r--r--pkgs/tools/X11/xzoom/default.nix1
-rw-r--r--pkgs/tools/audio/abcm2ps/default.nix1
-rw-r--r--pkgs/tools/audio/accuraterip-checksum/default.nix1
-rw-r--r--pkgs/tools/audio/acousticbrainz-client/default.nix1
-rw-r--r--pkgs/tools/audio/audiowaveform/default.nix1
-rw-r--r--pkgs/tools/audio/bark/default.nix1
-rw-r--r--pkgs/tools/audio/botamusique/default.nix1
-rw-r--r--pkgs/tools/audio/catnip-gtk4/default.nix1
-rw-r--r--pkgs/tools/audio/catnip/default.nix1
-rw-r--r--pkgs/tools/audio/dsp/default.nix1
-rw-r--r--pkgs/tools/audio/essentia-extractor/default.nix1
-rw-r--r--pkgs/tools/audio/gvolicon/default.nix1
-rw-r--r--pkgs/tools/audio/headset-charge-indicator/default.nix1
-rw-r--r--pkgs/tools/audio/linuxwave/default.nix1
-rw-r--r--pkgs/tools/audio/mictray/default.nix1
-rw-r--r--pkgs/tools/audio/midimonster/default.nix1
-rw-r--r--pkgs/tools/audio/mp3cat/default.nix1
-rw-r--r--pkgs/tools/audio/mpd-discord-rpc/default.nix1
-rw-r--r--pkgs/tools/audio/mpd-mpris/default.nix1
-rw-r--r--pkgs/tools/audio/mpd-notification/default.nix1
-rw-r--r--pkgs/tools/audio/mpd-sima/default.nix1
-rw-r--r--pkgs/tools/audio/mpdas/default.nix1
-rw-r--r--pkgs/tools/audio/mpdris2/default.nix1
-rw-r--r--pkgs/tools/audio/nanotts/default.nix1
-rw-r--r--pkgs/tools/audio/pasystray/default.nix1
-rw-r--r--pkgs/tools/audio/patray/default.nix1
-rw-r--r--pkgs/tools/audio/picotts/default.nix1
-rw-r--r--pkgs/tools/audio/piper/default.nix1
-rw-r--r--pkgs/tools/audio/pnmixer/default.nix1
-rw-r--r--pkgs/tools/audio/pw-volume/default.nix1
-rw-r--r--pkgs/tools/audio/stt/default.nix1
-rw-r--r--pkgs/tools/audio/tidal-dl/default.nix1
-rw-r--r--pkgs/tools/audio/unflac/default.nix1
-rw-r--r--pkgs/tools/audio/video2midi/default.nix1
-rw-r--r--pkgs/tools/audio/volctl/default.nix1
-rw-r--r--pkgs/tools/audio/volumeicon/default.nix1
-rw-r--r--pkgs/tools/audio/whisper-ctranslate2/default.nix1
-rw-r--r--pkgs/tools/audio/yabridgectl/default.nix1
-rw-r--r--pkgs/tools/filesystems/dupe-krill/default.nix1
-rw-r--r--pkgs/tools/filesystems/dysk/default.nix1
-rw-r--r--pkgs/tools/filesystems/eiciel/default.nix1
-rw-r--r--pkgs/tools/filesystems/ext4magic/default.nix1
-rw-r--r--pkgs/tools/filesystems/extundelete/default.nix1
-rw-r--r--pkgs/tools/filesystems/fatresize/default.nix1
-rw-r--r--pkgs/tools/filesystems/fatsort/default.nix1
-rw-r--r--pkgs/tools/filesystems/file-rename/default.nix1
-rw-r--r--pkgs/tools/filesystems/fuse-7z-ng/default.nix1
-rw-r--r--pkgs/tools/filesystems/fuse-archive/default.nix1
-rw-r--r--pkgs/tools/filesystems/fuse-overlayfs/default.nix1
-rw-r--r--pkgs/tools/filesystems/fuseiso/default.nix1
-rw-r--r--pkgs/tools/filesystems/fwanalyzer/default.nix1
-rw-r--r--pkgs/tools/filesystems/garage/default.nix1
-rw-r--r--pkgs/tools/filesystems/genext2fs/default.nix1
-rw-r--r--pkgs/tools/filesystems/genimage/default.nix1
-rw-r--r--pkgs/tools/filesystems/genromfs/default.nix1
-rw-r--r--pkgs/tools/filesystems/gitfs/default.nix1
-rw-r--r--pkgs/tools/filesystems/go-mtpfs/default.nix1
-rw-r--r--pkgs/tools/filesystems/goofys/default.nix1
-rw-r--r--pkgs/tools/filesystems/gpart/default.nix1
-rw-r--r--pkgs/tools/filesystems/grive2/default.nix1
-rw-r--r--pkgs/tools/filesystems/httm/default.nix1
-rw-r--r--pkgs/tools/filesystems/httpdirfs/default.nix1
-rw-r--r--pkgs/tools/filesystems/ifuse/default.nix1
-rw-r--r--pkgs/tools/filesystems/ioztat/default.nix1
-rw-r--r--pkgs/tools/filesystems/jefferson/default.nix1
-rw-r--r--pkgs/tools/filesystems/jmtpfs/default.nix1
-rw-r--r--pkgs/tools/filesystems/kdiskmark/default.nix1
-rw-r--r--pkgs/tools/filesystems/mhddfs/default.nix1
-rw-r--r--pkgs/tools/filesystems/mkspiffs/default.nix1
-rw-r--r--pkgs/tools/filesystems/mount-zip/default.nix1
-rw-r--r--pkgs/tools/filesystems/mp3fs/default.nix1
-rw-r--r--pkgs/tools/filesystems/mtpfs/default.nix1
-rw-r--r--pkgs/tools/filesystems/rdfind/default.nix1
-rw-r--r--pkgs/tools/filesystems/rmfuse/default.nix1
-rw-r--r--pkgs/tools/filesystems/rmount/default.nix1
-rw-r--r--pkgs/tools/filesystems/rnm/default.nix1
-rw-r--r--pkgs/tools/filesystems/romdirfs/default.nix1
-rw-r--r--pkgs/tools/filesystems/s3backer/default.nix1
-rw-r--r--pkgs/tools/filesystems/sandboxfs/default.nix1
-rw-r--r--pkgs/tools/filesystems/sasquatch/default.nix1
-rw-r--r--pkgs/tools/filesystems/sdat2img/default.nix1
-rw-r--r--pkgs/tools/filesystems/securefs/default.nix1
-rw-r--r--pkgs/tools/filesystems/sftpman/default.nix1
-rw-r--r--pkgs/tools/filesystems/simple-mtpfs/default.nix1
-rw-r--r--pkgs/tools/filesystems/smbnetfs/default.nix1
-rw-r--r--pkgs/tools/filesystems/snapraid/default.nix1
-rw-r--r--pkgs/tools/filesystems/stratis-cli/default.nix1
-rw-r--r--pkgs/tools/filesystems/svnfs/default.nix1
-rw-r--r--pkgs/tools/filesystems/tar2ext4/default.nix1
-rw-r--r--pkgs/tools/filesystems/u3-tool/default.nix1
-rw-r--r--pkgs/tools/filesystems/ubidump/default.nix1
-rw-r--r--pkgs/tools/filesystems/wdfs/default.nix1
-rw-r--r--pkgs/tools/filesystems/wipefreespace/default.nix1
-rw-r--r--pkgs/tools/filesystems/yandex-disk/default.nix1
-rw-r--r--pkgs/tools/filesystems/zerofree/default.nix1
-rw-r--r--pkgs/tools/filesystems/zkfuse/default.nix1
-rw-r--r--pkgs/tools/filesystems/zpool-auto-expand-partitions/default.nix1
-rw-r--r--pkgs/tools/filesystems/zpool-iostat-viz/default.nix1
-rw-r--r--pkgs/tools/virtualization/alpine-make-vm-image/default.nix1
-rw-r--r--pkgs/tools/virtualization/amazon-ecs-cli/default.nix1
-rw-r--r--pkgs/tools/virtualization/distrobuilder/default.nix1
-rw-r--r--pkgs/tools/virtualization/extra-container/default.nix1
-rw-r--r--pkgs/tools/virtualization/govc/default.nix1
-rw-r--r--pkgs/tools/virtualization/jumppad/default.nix1
-rw-r--r--pkgs/tools/virtualization/kubevirt/default.nix1
-rw-r--r--pkgs/tools/virtualization/lxd-image-server/default.nix1
-rw-r--r--pkgs/tools/virtualization/marathonctl/default.nix1
-rw-r--r--pkgs/tools/virtualization/mininet/default.nix1
-rw-r--r--pkgs/tools/virtualization/nixos-shell/default.nix1
-rw-r--r--pkgs/tools/virtualization/onmetal-image/default.nix1
-rw-r--r--pkgs/tools/virtualization/ovftool/default.nix1
-rw-r--r--pkgs/tools/virtualization/reg/default.nix1
-rw-r--r--pkgs/tools/virtualization/supermin/default.nix1
-rw-r--r--pkgs/tools/virtualization/udocker/default.nix1
-rw-r--r--pkgs/tools/virtualization/uefi-run/default.nix1
-rw-r--r--pkgs/tools/virtualization/vpsfree-client/default.nix1
-rw-r--r--pkgs/tools/virtualization/xva-img/default.nix1
187 files changed, 187 insertions, 0 deletions
diff --git a/pkgs/tools/X11/alttab/default.nix b/pkgs/tools/X11/alttab/default.nix
index 7e675c250175f..99619bd88d2c4 100644
--- a/pkgs/tools/X11/alttab/default.nix
+++ b/pkgs/tools/X11/alttab/default.nix
@@ -53,5 +53,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl3Plus;
     platforms = platforms.all;
     maintainers = [ ];
+    mainProgram = "alttab";
   };
 }
diff --git a/pkgs/tools/X11/autocutsel/default.nix b/pkgs/tools/X11/autocutsel/default.nix
index 61a80bcbcdd61..e1b9a3c1c73a5 100644
--- a/pkgs/tools/X11/autocutsel/default.nix
+++ b/pkgs/tools/X11/autocutsel/default.nix
@@ -20,5 +20,6 @@ stdenv.mkDerivation rec {
     description = "Tracks changes in the server's cutbuffer and CLIPBOARD selection";
     license = lib.licenses.gpl2Plus;
     platforms = with lib.platforms; all;
+    mainProgram = "autocutsel";
   };
 }
diff --git a/pkgs/tools/X11/bgs/default.nix b/pkgs/tools/X11/bgs/default.nix
index f0150e9315515..b50f15a1929cb 100644
--- a/pkgs/tools/X11/bgs/default.nix
+++ b/pkgs/tools/X11/bgs/default.nix
@@ -23,5 +23,6 @@ stdenv.mkDerivation rec {
     license = licenses.mit;
     platforms = platforms.linux;
     maintainers = with maintainers; [ pSub ];
+    mainProgram = "bgs";
   };
 }
diff --git a/pkgs/tools/X11/ckbcomp/default.nix b/pkgs/tools/X11/ckbcomp/default.nix
index f78e43dbcc8ef..1b50b2456d0ae 100644
--- a/pkgs/tools/X11/ckbcomp/default.nix
+++ b/pkgs/tools/X11/ckbcomp/default.nix
@@ -32,5 +32,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl2Plus;
     maintainers = with lib.maintainers; [ dezgeg ];
     platforms = platforms.unix;
+    mainProgram = "ckbcomp";
   };
 }
diff --git a/pkgs/tools/X11/devour/default.nix b/pkgs/tools/X11/devour/default.nix
index 016ffa6215dbd..861eaf905f9d1 100644
--- a/pkgs/tools/X11/devour/default.nix
+++ b/pkgs/tools/X11/devour/default.nix
@@ -24,5 +24,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl2Only;
     maintainers = with maintainers; [ mazurel ];
     platforms = platforms.unix;
+    mainProgram = "devour";
   };
 }
diff --git a/pkgs/tools/X11/dex/default.nix b/pkgs/tools/X11/dex/default.nix
index 5e0ef6002ce06..c194e1543f292 100644
--- a/pkgs/tools/X11/dex/default.nix
+++ b/pkgs/tools/X11/dex/default.nix
@@ -28,5 +28,6 @@ stdenv.mkDerivation rec {
     platforms = platforms.linux;
     license = licenses.gpl3Plus;
     maintainers = with maintainers; [ nickcao ];
+    mainProgram = "dex";
   };
 }
diff --git a/pkgs/tools/X11/dispad/default.nix b/pkgs/tools/X11/dispad/default.nix
index fbb7b117d2982..11d46bf24cb64 100644
--- a/pkgs/tools/X11/dispad/default.nix
+++ b/pkgs/tools/X11/dispad/default.nix
@@ -19,5 +19,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl2;
     maintainers = with maintainers; [ zimbatm ];
     platforms = platforms.linux;
+    mainProgram = "dispad";
   };
 }
diff --git a/pkgs/tools/X11/ffcast/default.nix b/pkgs/tools/X11/ffcast/default.nix
index 9723ef69b8507..9b2611dde210f 100644
--- a/pkgs/tools/X11/ffcast/default.nix
+++ b/pkgs/tools/X11/ffcast/default.nix
@@ -36,5 +36,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl3Plus;
     maintainers = with maintainers; [ sikmir ];
     platforms = platforms.linux;
+    mainProgram = "ffcast";
   };
 }
diff --git a/pkgs/tools/X11/find-cursor/default.nix b/pkgs/tools/X11/find-cursor/default.nix
index 44a7c7662152c..3b9862a47dea2 100644
--- a/pkgs/tools/X11/find-cursor/default.nix
+++ b/pkgs/tools/X11/find-cursor/default.nix
@@ -22,5 +22,6 @@ stdenv.mkDerivation rec {
     license = licenses.mit;
     platforms = platforms.linux;
     maintainers = [ maintainers.yanganto ];
+    mainProgram = "find-cursor";
   };
 }
diff --git a/pkgs/tools/X11/gobble/default.nix b/pkgs/tools/X11/gobble/default.nix
index 46b1b2c4b482e..b61cf78f99212 100644
--- a/pkgs/tools/X11/gobble/default.nix
+++ b/pkgs/tools/X11/gobble/default.nix
@@ -33,5 +33,6 @@ rustPlatform.buildRustPackage rec {
     license = lib.licenses.gpl3Only;
     maintainers = with lib.maintainers; [ vuimuich ];
     platforms = lib.platforms.linux;
+    mainProgram = "gobble";
   };
 }
diff --git a/pkgs/tools/X11/grobi/default.nix b/pkgs/tools/X11/grobi/default.nix
index 08b0379729705..cea5fad51e555 100644
--- a/pkgs/tools/X11/grobi/default.nix
+++ b/pkgs/tools/X11/grobi/default.nix
@@ -26,5 +26,6 @@ buildGoModule rec {
     description = "Automatically configure monitors/outputs for Xorg via RANDR";
     license = with licenses; [ bsd2 ];
     platforms   = platforms.linux;
+    mainProgram = "grobi";
   };
 }
diff --git a/pkgs/tools/X11/icon-slicer/default.nix b/pkgs/tools/X11/icon-slicer/default.nix
index 37b309c54b76b..514b39496ffa4 100644
--- a/pkgs/tools/X11/icon-slicer/default.nix
+++ b/pkgs/tools/X11/icon-slicer/default.nix
@@ -25,5 +25,6 @@ stdenv.mkDerivation rec {
     license = licenses.mit;
     maintainers = with maintainers; [ zaninime ];
     platforms = platforms.linux;
+    mainProgram = "icon-slicer";
   };
 }
diff --git a/pkgs/tools/X11/imwheel/default.nix b/pkgs/tools/X11/imwheel/default.nix
index 79fbe65af1f22..bab363583a6ca 100644
--- a/pkgs/tools/X11/imwheel/default.nix
+++ b/pkgs/tools/X11/imwheel/default.nix
@@ -27,5 +27,6 @@ stdenv.mkDerivation rec {
     maintainers = with maintainers; [ jhillyerd ];
     platforms = platforms.linux;
     license = licenses.gpl2;
+    mainProgram = "imwheel";
   };
 }
diff --git a/pkgs/tools/X11/inputplug/default.nix b/pkgs/tools/X11/inputplug/default.nix
index e6bf334cf4c0a..80d97190a0cee 100644
--- a/pkgs/tools/X11/inputplug/default.nix
+++ b/pkgs/tools/X11/inputplug/default.nix
@@ -34,6 +34,7 @@ rustPlatform.buildRustPackage rec {
     # `daemon(3)` is deprecated on macOS and `pidfile-rs` needs updating
     broken = stdenv.isDarwin;
     maintainers = with maintainers; [ jecaro ];
+    mainProgram = "inputplug";
   };
 }
 
diff --git a/pkgs/tools/X11/kdocker/default.nix b/pkgs/tools/X11/kdocker/default.nix
index 21a11f8fa31a1..e8c08e4c3832b 100644
--- a/pkgs/tools/X11/kdocker/default.nix
+++ b/pkgs/tools/X11/kdocker/default.nix
@@ -50,5 +50,6 @@ stdenv.mkDerivation (finalAttrs: {
     license = licenses.gpl2Only;
     maintainers = with maintainers; [ hexclover ];
     platforms = platforms.linux;
+    mainProgram = "kdocker";
   };
 })
diff --git a/pkgs/tools/X11/keynav/default.nix b/pkgs/tools/X11/keynav/default.nix
index 4a2a0e8b59044..63732f478cbaa 100644
--- a/pkgs/tools/X11/keynav/default.nix
+++ b/pkgs/tools/X11/keynav/default.nix
@@ -58,5 +58,6 @@ stdenv.mkDerivation {
     license = licenses.bsd3;
     maintainers = with maintainers; [ pSub ];
     platforms = platforms.linux;
+    mainProgram = "keynav";
   };
 }
diff --git a/pkgs/tools/X11/ksuperkey/default.nix b/pkgs/tools/X11/ksuperkey/default.nix
index 8b77ae550300f..733022948dbda 100644
--- a/pkgs/tools/X11/ksuperkey/default.nix
+++ b/pkgs/tools/X11/ksuperkey/default.nix
@@ -22,5 +22,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl3;
     maintainers = [ ];
     platforms = platforms.linux;
+    mainProgram = "ksuperkey";
   };
 }
diff --git a/pkgs/tools/X11/nitrogen/default.nix b/pkgs/tools/X11/nitrogen/default.nix
index deefddf23cea3..6097948a7cd3c 100644
--- a/pkgs/tools/X11/nitrogen/default.nix
+++ b/pkgs/tools/X11/nitrogen/default.nix
@@ -29,5 +29,6 @@ stdenv.mkDerivation rec {
     license = lib.licenses.gpl2;
     platforms = lib.platforms.linux;
     maintainers = [ lib.maintainers.auntie ];
+    mainProgram = "nitrogen";
   };
 }
diff --git a/pkgs/tools/X11/obconf/default.nix b/pkgs/tools/X11/obconf/default.nix
index efd8b60419bee..f4f9fd433fdea 100644
--- a/pkgs/tools/X11/obconf/default.nix
+++ b/pkgs/tools/X11/obconf/default.nix
@@ -48,5 +48,6 @@ stdenv.mkDerivation rec {
     license = lib.licenses.gpl2Plus;
     maintainers = [ lib.maintainers.sfrijters ];
     platforms = lib.platforms.linux;
+    mainProgram = "obconf";
   };
 }
diff --git a/pkgs/tools/X11/paperview/default.nix b/pkgs/tools/X11/paperview/default.nix
index 790eaed53ab5a..30f04702708aa 100644
--- a/pkgs/tools/X11/paperview/default.nix
+++ b/pkgs/tools/X11/paperview/default.nix
@@ -31,5 +31,6 @@ stdenv.mkDerivation rec {
     platforms = platforms.linux;
     license = with licenses; [ mit ];
     maintainers = with maintainers; [ _3JlOy-PYCCKUi ];
+    mainProgram = "paperview";
   };
 }
diff --git a/pkgs/tools/X11/pmenu/default.nix b/pkgs/tools/X11/pmenu/default.nix
index c5f6274d988e5..278a181f5c92a 100644
--- a/pkgs/tools/X11/pmenu/default.nix
+++ b/pkgs/tools/X11/pmenu/default.nix
@@ -56,5 +56,6 @@ stdenv.mkDerivation (finalAttrs: {
     '';
     maintainers = [ lib.maintainers.azahi ];
     platforms = lib.platforms.unix;
+    mainProgram = "pmenu";
   };
 })
diff --git a/pkgs/tools/X11/ratmen/default.nix b/pkgs/tools/X11/ratmen/default.nix
index 8a07b41ac3716..0fe85a9ae452d 100644
--- a/pkgs/tools/X11/ratmen/default.nix
+++ b/pkgs/tools/X11/ratmen/default.nix
@@ -22,5 +22,6 @@ stdenv.mkDerivation rec {
     platforms = platforms.linux;
     homepage = "http://www.update.uu.se/~zrajm/programs/";
     downloadPage = "http://www.update.uu.se/~zrajm/programs/ratmen/";
+    mainProgram = "ratmen";
   };
 }
diff --git a/pkgs/tools/X11/run-scaled/default.nix b/pkgs/tools/X11/run-scaled/default.nix
index d62b38bdf2872..b9cdc20f78aa5 100644
--- a/pkgs/tools/X11/run-scaled/default.nix
+++ b/pkgs/tools/X11/run-scaled/default.nix
@@ -26,5 +26,6 @@ stdenv.mkDerivation {
     maintainers = [ maintainers.snaar ];
     license = licenses.bsd3;
     platforms = platforms.unix;
+    mainProgram = "run_scaled";
   };
 }
diff --git a/pkgs/tools/X11/sbs/default.nix b/pkgs/tools/X11/sbs/default.nix
index 02a25ba467fb2..8f16729cd2562 100644
--- a/pkgs/tools/X11/sbs/default.nix
+++ b/pkgs/tools/X11/sbs/default.nix
@@ -23,5 +23,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl2;
     platforms = platforms.linux;
     maintainers = with maintainers; [ onur-ozkan ];
+    mainProgram = "sbs";
   };
 }
diff --git a/pkgs/tools/X11/setroot/default.nix b/pkgs/tools/X11/setroot/default.nix
index bc7b468caaf8a..2c7729eab3ad3 100644
--- a/pkgs/tools/X11/setroot/default.nix
+++ b/pkgs/tools/X11/setroot/default.nix
@@ -35,5 +35,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl3Plus;
     maintainers = [ maintainers.vyp ];
     platforms = platforms.unix;
+    mainProgram = "setroot";
   };
 }
diff --git a/pkgs/tools/X11/smart-wallpaper/default.nix b/pkgs/tools/X11/smart-wallpaper/default.nix
index f992838935c7d..8f41bb7a78afa 100644
--- a/pkgs/tools/X11/smart-wallpaper/default.nix
+++ b/pkgs/tools/X11/smart-wallpaper/default.nix
@@ -34,5 +34,6 @@ stdenvNoCC.mkDerivation {
     license = licenses.bsd2;
     maintainers = with maintainers; [ baitinq ];
     platforms = platforms.linux;
+    mainProgram = "smart-wallpaper";
   };
 }
diff --git a/pkgs/tools/X11/srandrd/default.nix b/pkgs/tools/X11/srandrd/default.nix
index 84f43301bbd75..0d51bf4785ecb 100644
--- a/pkgs/tools/X11/srandrd/default.nix
+++ b/pkgs/tools/X11/srandrd/default.nix
@@ -26,6 +26,7 @@ stdenv.mkDerivation rec {
     license = licenses.mit;
     platforms = platforms.linux;
     maintainers = [ maintainers.utdemir ];
+    mainProgram = "srandrd";
   };
 
 }
diff --git a/pkgs/tools/X11/sselp/default.nix b/pkgs/tools/X11/sselp/default.nix
index d22884270dd45..de083a32028d7 100644
--- a/pkgs/tools/X11/sselp/default.nix
+++ b/pkgs/tools/X11/sselp/default.nix
@@ -23,5 +23,6 @@ stdenv.mkDerivation rec {
     license = lib.licenses.mit;
     maintainers = [lib.maintainers.magnetophon ];
     platforms = lib.platforms.linux;
+    mainProgram = "sselp";
   };
 }
diff --git a/pkgs/tools/X11/sx/default.nix b/pkgs/tools/X11/sx/default.nix
index f48e59c753eb2..d408af8245bc7 100644
--- a/pkgs/tools/X11/sx/default.nix
+++ b/pkgs/tools/X11/sx/default.nix
@@ -35,5 +35,6 @@ stdenvNoCC.mkDerivation rec {
     license = licenses.mit;
     platforms = platforms.linux;
     maintainers = with maintainers; [ figsoda thiagokokada ];
+    mainProgram = "sx";
   };
 }
diff --git a/pkgs/tools/X11/vdpauinfo/default.nix b/pkgs/tools/X11/vdpauinfo/default.nix
index a5fc87aaf6f2b..0ca3354433dce 100644
--- a/pkgs/tools/X11/vdpauinfo/default.nix
+++ b/pkgs/tools/X11/vdpauinfo/default.nix
@@ -19,5 +19,6 @@ stdenv.mkDerivation rec {
     license = licenses.mit; # expat version
     platforms = platforms.unix;
     maintainers = with maintainers; [ vcunat ];
+    mainProgram = "vdpauinfo";
   };
 }
diff --git a/pkgs/tools/X11/wayv/default.nix b/pkgs/tools/X11/wayv/default.nix
index 2bdeff6a57904..eae930de1dd9b 100644
--- a/pkgs/tools/X11/wayv/default.nix
+++ b/pkgs/tools/X11/wayv/default.nix
@@ -37,5 +37,6 @@ stdenv.mkDerivation rec {
     maintainers = [lib.maintainers.raskin];
     platforms = lib.platforms.linux;
     homepage = "https://github.com/mikemb/wayV";
+    mainProgram = "wayv";
   };
 }
diff --git a/pkgs/tools/X11/wmctrl/default.nix b/pkgs/tools/X11/wmctrl/default.nix
index 19a464aff72af..08a3e9c365f40 100644
--- a/pkgs/tools/X11/wmctrl/default.nix
+++ b/pkgs/tools/X11/wmctrl/default.nix
@@ -30,6 +30,7 @@ stdenv.mkDerivation rec {
     license = lib.licenses.gpl2;
     platforms = with lib.platforms; all;
     maintainers = [ lib.maintainers.Anton-Latukha ];
+    mainProgram = "wmctrl";
   };
 
 }
diff --git a/pkgs/tools/X11/x11vnc/default.nix b/pkgs/tools/X11/x11vnc/default.nix
index e9e9e4b4daba4..8c48951b2d42a 100644
--- a/pkgs/tools/X11/x11vnc/default.nix
+++ b/pkgs/tools/X11/x11vnc/default.nix
@@ -57,5 +57,6 @@ stdenv.mkDerivation rec {
     platforms = platforms.linux;
     license = licenses.gpl2;
     maintainers = with maintainers; [ OPNA2608 ];
+    mainProgram = "x11vnc";
   };
 }
diff --git a/pkgs/tools/X11/x2vnc/default.nix b/pkgs/tools/X11/x2vnc/default.nix
index ed4a83fc8de08..8c9648e71d37b 100644
--- a/pkgs/tools/X11/x2vnc/default.nix
+++ b/pkgs/tools/X11/x2vnc/default.nix
@@ -20,5 +20,6 @@ stdenv.mkDerivation rec {
     description = "A program to control a remote VNC server";
     platforms = platforms.unix;
     license = licenses.gpl2;
+    mainProgram = "x2vnc";
   };
 }
diff --git a/pkgs/tools/X11/x2x/default.nix b/pkgs/tools/X11/x2x/default.nix
index 3a766d63ba97e..061f1d190318a 100644
--- a/pkgs/tools/X11/x2x/default.nix
+++ b/pkgs/tools/X11/x2x/default.nix
@@ -19,5 +19,6 @@ stdenv.mkDerivation rec {
     homepage = "https://github.com/dottedmag/x2x";
     license = licenses.bsd3;
     platforms = platforms.linux;
+    mainProgram = "x2x";
   };
 }
diff --git a/pkgs/tools/X11/xannotate/default.nix b/pkgs/tools/X11/xannotate/default.nix
index fe6d5cae6ee1d..148bbcfe7af49 100644
--- a/pkgs/tools/X11/xannotate/default.nix
+++ b/pkgs/tools/X11/xannotate/default.nix
@@ -28,5 +28,6 @@ stdenv.mkDerivation rec {
     maintainers = [lib.maintainers.raskin];
     platforms = lib.platforms.linux;
     homepage = "https://github.com/blais/xannotate";
+    mainProgram = "xannotate";
   };
 }
diff --git a/pkgs/tools/X11/xbanish/default.nix b/pkgs/tools/X11/xbanish/default.nix
index 9aa7e4f5b0235..9a8780324b84e 100644
--- a/pkgs/tools/X11/xbanish/default.nix
+++ b/pkgs/tools/X11/xbanish/default.nix
@@ -38,5 +38,6 @@ stdenv.mkDerivation rec {
     license = lib.licenses.bsd3;
     maintainers = [lib.maintainers.choochootrain];
     platforms = lib.platforms.linux;
+    mainProgram = "xbanish";
   };
 }
diff --git a/pkgs/tools/X11/xbindkeys-config/default.nix b/pkgs/tools/X11/xbindkeys-config/default.nix
index e9d6d42b06892..8a5c07ef96ecd 100644
--- a/pkgs/tools/X11/xbindkeys-config/default.nix
+++ b/pkgs/tools/X11/xbindkeys-config/default.nix
@@ -24,6 +24,7 @@ stdenv.mkDerivation rec {
     license = lib.licenses.gpl2Plus;
     maintainers = with lib.maintainers; [benley];
     platforms = with lib.platforms; linux;
+    mainProgram = "xbindkeys-config";
   };
 
   patches = [ ./xbindkeys-config-patch1.patch ];
diff --git a/pkgs/tools/X11/xborders/default.nix b/pkgs/tools/X11/xborders/default.nix
index f9e78034c3c04..379f976acf451 100644
--- a/pkgs/tools/X11/xborders/default.nix
+++ b/pkgs/tools/X11/xborders/default.nix
@@ -53,5 +53,6 @@ python3Packages.buildPythonPackage rec {
     license = licenses.unlicense;
     maintainers = with maintainers; [ elnudev ];
     platforms = platforms.linux;
+    mainProgram = "xborders";
   };
 }
diff --git a/pkgs/tools/X11/xbrightness/default.nix b/pkgs/tools/X11/xbrightness/default.nix
index 1445c60ccb19e..c022371c01d98 100644
--- a/pkgs/tools/X11/xbrightness/default.nix
+++ b/pkgs/tools/X11/xbrightness/default.nix
@@ -21,5 +21,6 @@ stdenv.mkDerivation rec {
     homepage = "http://shallowsky.com/software";
     license = lib.licenses.mit;
     platforms = lib.platforms.linux;
+    mainProgram = "xbrightness";
   };
 }
diff --git a/pkgs/tools/X11/xcalib/default.nix b/pkgs/tools/X11/xcalib/default.nix
index 09d5cde88fe6d..4960aff0f7b0c 100644
--- a/pkgs/tools/X11/xcalib/default.nix
+++ b/pkgs/tools/X11/xcalib/default.nix
@@ -24,5 +24,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl2;
     maintainers = [];
     platforms = platforms.linux;
+    mainProgram = "xcalib";
   };
 }
diff --git a/pkgs/tools/X11/xcape/default.nix b/pkgs/tools/X11/xcape/default.nix
index f8d4376017bda..c62e29cedc154 100644
--- a/pkgs/tools/X11/xcape/default.nix
+++ b/pkgs/tools/X11/xcape/default.nix
@@ -37,5 +37,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl3 ;
     maintainers = with maintainers; [ raskin ];
     platforms = platforms.linux;
+    mainProgram = "xcape";
   };
 }
diff --git a/pkgs/tools/X11/xchainkeys/default.nix b/pkgs/tools/X11/xchainkeys/default.nix
index 5c154f8a1116d..7a251b30a47b9 100644
--- a/pkgs/tools/X11/xchainkeys/default.nix
+++ b/pkgs/tools/X11/xchainkeys/default.nix
@@ -16,5 +16,6 @@ stdenv.mkDerivation rec {
     description = "A standalone X11 program to create chained key bindings";
     license = lib.licenses.gpl3;
     platforms = lib.platforms.unix;
+    mainProgram = "xchainkeys";
   };
 }
diff --git a/pkgs/tools/X11/xcwd/default.nix b/pkgs/tools/X11/xcwd/default.nix
index 6dbd8606485a7..d60390952dd71 100644
--- a/pkgs/tools/X11/xcwd/default.nix
+++ b/pkgs/tools/X11/xcwd/default.nix
@@ -27,5 +27,6 @@ stdenv.mkDerivation rec {
     maintainers = [ maintainers.grburst ];
     license = licenses.bsd3;
     platforms = platforms.linux;
+    mainProgram = "xcwd";
   };
 }
diff --git a/pkgs/tools/X11/xdotool/default.nix b/pkgs/tools/X11/xdotool/default.nix
index 736c05c7c7db8..bcb48ac44fac7 100644
--- a/pkgs/tools/X11/xdotool/default.nix
+++ b/pkgs/tools/X11/xdotool/default.nix
@@ -26,5 +26,6 @@ stdenv.mkDerivation rec {
     license = lib.licenses.bsd3;
     maintainers = with lib.maintainers; [viric];
     platforms = with lib.platforms; linux;
+    mainProgram = "xdotool";
   };
 }
diff --git a/pkgs/tools/X11/xgeometry-select/default.nix b/pkgs/tools/X11/xgeometry-select/default.nix
index 9f9b50feab909..005bf302cc342 100644
--- a/pkgs/tools/X11/xgeometry-select/default.nix
+++ b/pkgs/tools/X11/xgeometry-select/default.nix
@@ -27,5 +27,6 @@ stdenv.mkDerivation rec {
     homepage    = "https://bbs.archlinux.org/viewtopic.php?pid=660837";
     maintainers = with maintainers; [ obadz ];
     platforms   = platforms.linux;
+    mainProgram = "xgeometry-select";
   };
 }
diff --git a/pkgs/tools/X11/xinput_calibrator/default.nix b/pkgs/tools/X11/xinput_calibrator/default.nix
index 25b419ade4e37..d8afb3e4a8966 100644
--- a/pkgs/tools/X11/xinput_calibrator/default.nix
+++ b/pkgs/tools/X11/xinput_calibrator/default.nix
@@ -22,5 +22,6 @@ stdenv.mkDerivation rec {
     license = lib.licenses.mit;
     maintainers = [ lib.maintainers.flosse ];
     platforms = lib.platforms.linux;
+    mainProgram = "xinput_calibrator";
   };
 }
diff --git a/pkgs/tools/X11/xkb-switch-i3/default.nix b/pkgs/tools/X11/xkb-switch-i3/default.nix
index 6333c1abc740b..975eeb9866141 100644
--- a/pkgs/tools/X11/xkb-switch-i3/default.nix
+++ b/pkgs/tools/X11/xkb-switch-i3/default.nix
@@ -30,5 +30,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl3Plus;
     maintainers = with maintainers; [ ewok ];
     platforms = platforms.linux;
+    mainProgram = "xkb-switch";
   };
 }
diff --git a/pkgs/tools/X11/xkb-switch/default.nix b/pkgs/tools/X11/xkb-switch/default.nix
index e2f15d969edd6..7db5925322346 100644
--- a/pkgs/tools/X11/xkb-switch/default.nix
+++ b/pkgs/tools/X11/xkb-switch/default.nix
@@ -20,5 +20,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl2Plus;
     maintainers = with maintainers; [ smironov ];
     platforms = platforms.linux;
+    mainProgram = "xkb-switch";
   };
 }
diff --git a/pkgs/tools/X11/xkbset/default.nix b/pkgs/tools/X11/xkbset/default.nix
index 645770f7e015a..9c4bc81744fa5 100644
--- a/pkgs/tools/X11/xkbset/default.nix
+++ b/pkgs/tools/X11/xkbset/default.nix
@@ -30,5 +30,6 @@ stdenv.mkDerivation rec {
     maintainers = with maintainers; [ drets ];
     platforms = platforms.linux;
     license = licenses.bsd3;
+    mainProgram = "xkbset";
   };
 }
diff --git a/pkgs/tools/X11/xkbvalidate/default.nix b/pkgs/tools/X11/xkbvalidate/default.nix
index 92a47aa65638b..b39e697f77414 100644
--- a/pkgs/tools/X11/xkbvalidate/default.nix
+++ b/pkgs/tools/X11/xkbvalidate/default.nix
@@ -7,6 +7,7 @@ runCommandCC "xkbvalidate" {
     license = lib.licenses.mit;
     platforms = lib.platforms.unix;
     maintainers = [ lib.maintainers.aszlig ];
+    mainProgram = "xkbvalidate";
   };
 } ''
   mkdir -p "$out/bin"
diff --git a/pkgs/tools/X11/xlayoutdisplay/default.nix b/pkgs/tools/X11/xlayoutdisplay/default.nix
index 593b40a2ade79..499bd46945925 100644
--- a/pkgs/tools/X11/xlayoutdisplay/default.nix
+++ b/pkgs/tools/X11/xlayoutdisplay/default.nix
@@ -31,5 +31,6 @@ stdenv.mkDerivation rec {
     maintainers = with maintainers; [ dtzWill ];
     license = licenses.asl20;
     platforms = platforms.linux;
+    mainProgram = "xlayoutdisplay";
   };
 }
diff --git a/pkgs/tools/X11/xlogo/default.nix b/pkgs/tools/X11/xlogo/default.nix
index 8c30b34eca754..7b8e9bf52212b 100644
--- a/pkgs/tools/X11/xlogo/default.nix
+++ b/pkgs/tools/X11/xlogo/default.nix
@@ -32,5 +32,6 @@ stdenv.mkDerivation rec {
     maintainers = with maintainers; [ raboof ];
     platforms = platforms.unix;
     license = licenses.mit;
+    mainProgram = "xlogo";
   };
 }
diff --git a/pkgs/tools/X11/xmcp/default.nix b/pkgs/tools/X11/xmcp/default.nix
index 178861d637246..228d502c4b7c2 100644
--- a/pkgs/tools/X11/xmcp/default.nix
+++ b/pkgs/tools/X11/xmcp/default.nix
@@ -29,5 +29,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl3Plus;
     maintainers = with maintainers; [ azahi ];
     platforms = platforms.linux;
+    mainProgram = "xmcp";
   };
 }
diff --git a/pkgs/tools/X11/xmousepasteblock/default.nix b/pkgs/tools/X11/xmousepasteblock/default.nix
index ec6a5b0b8e11f..121ec93b2242c 100644
--- a/pkgs/tools/X11/xmousepasteblock/default.nix
+++ b/pkgs/tools/X11/xmousepasteblock/default.nix
@@ -17,5 +17,6 @@ stdenv.mkDerivation rec {
     homepage = "https://github.com/milaq/XMousePasteBlock";
     license = lib.licenses.gpl2;
     maintainers = [ maintainers.petercommand ];
+    mainProgram = "xmousepasteblock";
   };
 }
diff --git a/pkgs/tools/X11/xnotify/default.nix b/pkgs/tools/X11/xnotify/default.nix
index e5c6c31e7dbb0..cdd7d54b52945 100644
--- a/pkgs/tools/X11/xnotify/default.nix
+++ b/pkgs/tools/X11/xnotify/default.nix
@@ -50,5 +50,6 @@ stdenv.mkDerivation rec {
     license = licenses.mit;
     maintainers = with maintainers; [ azahi ];
     platforms = platforms.unix;
+    mainProgram = "xnotify";
   };
 }
diff --git a/pkgs/tools/X11/xob/default.nix b/pkgs/tools/X11/xob/default.nix
index 71e50248df979..e6e2fc2730208 100644
--- a/pkgs/tools/X11/xob/default.nix
+++ b/pkgs/tools/X11/xob/default.nix
@@ -31,5 +31,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl3Plus;
     platforms = platforms.unix;
     maintainers = with maintainers; [ florentc ];
+    mainProgram = "xob";
   };
 }
diff --git a/pkgs/tools/X11/xplugd/default.nix b/pkgs/tools/X11/xplugd/default.nix
index aa07c7f37b1b4..f5b81571ef2db 100644
--- a/pkgs/tools/X11/xplugd/default.nix
+++ b/pkgs/tools/X11/xplugd/default.nix
@@ -26,5 +26,6 @@ stdenv.mkDerivation rec {
     license = licenses.mit;
     platforms = platforms.linux;
     maintainers = with maintainers; [ akho ];
+    mainProgram = "xplugd";
   };
 }
diff --git a/pkgs/tools/X11/xpointerbarrier/default.nix b/pkgs/tools/X11/xpointerbarrier/default.nix
index 33271090678fc..8621e76443659 100644
--- a/pkgs/tools/X11/xpointerbarrier/default.nix
+++ b/pkgs/tools/X11/xpointerbarrier/default.nix
@@ -34,5 +34,6 @@ stdenv.mkDerivation (finalAttrs: {
     license = licenses.mit;
     maintainers = with maintainers; [ AndersonTorres xzfc ];
     platforms = platforms.linux;
+    mainProgram = "xpointerbarrier";
   };
 })
diff --git a/pkgs/tools/X11/xprintidle-ng/default.nix b/pkgs/tools/X11/xprintidle-ng/default.nix
index ec8a2ed459d39..ebe3d2a619926 100644
--- a/pkgs/tools/X11/xprintidle-ng/default.nix
+++ b/pkgs/tools/X11/xprintidle-ng/default.nix
@@ -67,5 +67,6 @@ stdenv.mkDerivation rec {
     license = lib.licenses.gpl2Only;
     maintainers = [ lib.maintainers.raskin ];
     platforms = lib.platforms.linux;
+    mainProgram = "xprintidle-ng";
   };
 }
diff --git a/pkgs/tools/X11/xprintidle/default.nix b/pkgs/tools/X11/xprintidle/default.nix
index 400306db6efdb..4a0d371a7fd61 100644
--- a/pkgs/tools/X11/xprintidle/default.nix
+++ b/pkgs/tools/X11/xprintidle/default.nix
@@ -36,5 +36,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl2Only;
     maintainers = with maintainers; [ fgaz ];
     platforms = platforms.linux;
+    mainProgram = "xprintidle";
   };
 }
diff --git a/pkgs/tools/X11/xprompt/default.nix b/pkgs/tools/X11/xprompt/default.nix
index 191b0316fa807..15f7b337c8795 100644
--- a/pkgs/tools/X11/xprompt/default.nix
+++ b/pkgs/tools/X11/xprompt/default.nix
@@ -50,5 +50,6 @@ stdenv.mkDerivation rec {
     license = licenses.mit;
     maintainers = with maintainers; [ azahi ];
     platforms = platforms.unix;
+    mainProgram = "xprompt";
   };
 }
diff --git a/pkgs/tools/X11/xrectsel/default.nix b/pkgs/tools/X11/xrectsel/default.nix
index 8b37a6792424b..7eef352aea53a 100644
--- a/pkgs/tools/X11/xrectsel/default.nix
+++ b/pkgs/tools/X11/xrectsel/default.nix
@@ -20,5 +20,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl3Plus;
     maintainers = with maintainers; [ sikmir ];
     platforms = platforms.linux;
+    mainProgram = "xrectsel";
   };
 }
diff --git a/pkgs/tools/X11/xrestop/default.nix b/pkgs/tools/X11/xrestop/default.nix
index dd3766160c013..2837d2a83d736 100644
--- a/pkgs/tools/X11/xrestop/default.nix
+++ b/pkgs/tools/X11/xrestop/default.nix
@@ -18,5 +18,6 @@ stdenv.mkDerivation rec {
     maintainers = with maintainers; [ qyliss ];
     platforms = platforms.unix;
     license = licenses.gpl2Plus;
+    mainProgram = "xrestop";
   };
 }
diff --git a/pkgs/tools/X11/xtrace/default.nix b/pkgs/tools/X11/xtrace/default.nix
index dfd834e67b808..de1ea88266e2d 100644
--- a/pkgs/tools/X11/xtrace/default.nix
+++ b/pkgs/tools/X11/xtrace/default.nix
@@ -26,5 +26,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl2;
     maintainers = with maintainers; [ viric ];
     platforms = with platforms; linux;
+    mainProgram = "xtrace";
   };
 }
diff --git a/pkgs/tools/X11/xtruss/default.nix b/pkgs/tools/X11/xtruss/default.nix
index 9e2ee94efa4ac..790312335ab21 100644
--- a/pkgs/tools/X11/xtruss/default.nix
+++ b/pkgs/tools/X11/xtruss/default.nix
@@ -16,5 +16,6 @@ stdenv.mkDerivation rec {
     homepage = "https://www.chiark.greenend.org.uk/~sgtatham/xtruss";
     license = licenses.mit;
     maintainers = with maintainers; [ dtzWill ];
+    mainProgram = "xtruss";
   };
 }
diff --git a/pkgs/tools/X11/xvkbd/default.nix b/pkgs/tools/X11/xvkbd/default.nix
index 32355205d59a9..7ed6b355a7993 100644
--- a/pkgs/tools/X11/xvkbd/default.nix
+++ b/pkgs/tools/X11/xvkbd/default.nix
@@ -34,5 +34,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl2Plus;
     maintainers = [ maintainers.bennofs ];
     platforms = platforms.linux;
+    mainProgram = "xvkbd";
   };
 }
diff --git a/pkgs/tools/X11/xwallpaper/default.nix b/pkgs/tools/X11/xwallpaper/default.nix
index 051a3a0d0fe73..df93e10fe1943 100644
--- a/pkgs/tools/X11/xwallpaper/default.nix
+++ b/pkgs/tools/X11/xwallpaper/default.nix
@@ -36,5 +36,6 @@ stdenv.mkDerivation rec {
     license = licenses.isc;
     maintainers = with maintainers; [ ivar ];
     platforms = platforms.linux;
+    mainProgram = "xwallpaper";
   };
 }
diff --git a/pkgs/tools/X11/xwinmosaic/default.nix b/pkgs/tools/X11/xwinmosaic/default.nix
index 51ba815f1de45..1189fd8f86aa4 100644
--- a/pkgs/tools/X11/xwinmosaic/default.nix
+++ b/pkgs/tools/X11/xwinmosaic/default.nix
@@ -29,5 +29,6 @@ stdenv.mkDerivation rec {
     license = lib.licenses.bsd2 ;
     maintainers = [lib.maintainers.raskin];
     platforms = lib.platforms.linux;
+    mainProgram = "xwinmosaic";
   };
 }
diff --git a/pkgs/tools/X11/xwinwrap/default.nix b/pkgs/tools/X11/xwinwrap/default.nix
index e5bc5743c28db..d36d2c51de5e0 100644
--- a/pkgs/tools/X11/xwinwrap/default.nix
+++ b/pkgs/tools/X11/xwinwrap/default.nix
@@ -50,5 +50,6 @@ stdenv.mkDerivation rec {
     homepage = "https://shantanugoel.com/2008/09/03/shantz-xwinwrap/";
     maintainers = with maintainers; [ infinisil ];
     platforms = platforms.linux;
+    mainProgram = "xwinwrap";
   };
 }
diff --git a/pkgs/tools/X11/xzoom/default.nix b/pkgs/tools/X11/xzoom/default.nix
index 7ba6bbee223d7..0e368651000dc 100644
--- a/pkgs/tools/X11/xzoom/default.nix
+++ b/pkgs/tools/X11/xzoom/default.nix
@@ -32,5 +32,6 @@ stdenv.mkDerivation rec {
     license = lib.licenses.free ;
     maintainers = [lib.maintainers.raskin];
     platforms = lib.platforms.linux;
+    mainProgram = "xzoom";
   };
 }
diff --git a/pkgs/tools/audio/abcm2ps/default.nix b/pkgs/tools/audio/abcm2ps/default.nix
index 249b4ba1706cc..c914572317161 100644
--- a/pkgs/tools/audio/abcm2ps/default.nix
+++ b/pkgs/tools/audio/abcm2ps/default.nix
@@ -32,5 +32,6 @@ stdenv.mkDerivation rec {
     description = "A command line program which converts ABC to music sheet in PostScript or SVG format";
     platforms = platforms.unix;
     maintainers = [ maintainers.dotlambda ];
+    mainProgram = "abcm2ps";
   };
 }
diff --git a/pkgs/tools/audio/accuraterip-checksum/default.nix b/pkgs/tools/audio/accuraterip-checksum/default.nix
index 161e9848bea6f..8658dfb5a7aa4 100644
--- a/pkgs/tools/audio/accuraterip-checksum/default.nix
+++ b/pkgs/tools/audio/accuraterip-checksum/default.nix
@@ -27,5 +27,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl3;
     maintainers = with maintainers; [ ];
     platforms = with platforms; linux;
+    mainProgram = "accuraterip-checksum";
   };
 }
diff --git a/pkgs/tools/audio/acousticbrainz-client/default.nix b/pkgs/tools/audio/acousticbrainz-client/default.nix
index 651605679684e..1d4b59ed2c924 100644
--- a/pkgs/tools/audio/acousticbrainz-client/default.nix
+++ b/pkgs/tools/audio/acousticbrainz-client/default.nix
@@ -37,5 +37,6 @@ python3Packages.buildPythonApplication rec {
     # essentia-extractor is only available for those platforms
     platforms = [ "x86_64-linux" "i686-linux" ];
     maintainers = with maintainers; [ ];
+    mainProgram = "abzsubmit";
   };
 }
diff --git a/pkgs/tools/audio/audiowaveform/default.nix b/pkgs/tools/audio/audiowaveform/default.nix
index 11dc8541c5b93..a5fff36322e40 100644
--- a/pkgs/tools/audio/audiowaveform/default.nix
+++ b/pkgs/tools/audio/audiowaveform/default.nix
@@ -33,5 +33,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl3Plus;
     platforms = platforms.all;
     maintainers = with maintainers; [ edbentley ];
+    mainProgram = "audiowaveform";
   };
 }
diff --git a/pkgs/tools/audio/bark/default.nix b/pkgs/tools/audio/bark/default.nix
index f943b555b0102..e866b1a18a3b3 100644
--- a/pkgs/tools/audio/bark/default.nix
+++ b/pkgs/tools/audio/bark/default.nix
@@ -24,6 +24,7 @@ rustPlatform.buildRustPackage {
     license = lib.licenses.agpl3Only;
     maintainers = with lib.maintainers; [ samw ];
     platforms = lib.platforms.linux;
+    mainProgram = "bark";
   };
 }
 
diff --git a/pkgs/tools/audio/botamusique/default.nix b/pkgs/tools/audio/botamusique/default.nix
index 02460f61d93ba..85c707bda90ca 100644
--- a/pkgs/tools/audio/botamusique/default.nix
+++ b/pkgs/tools/audio/botamusique/default.nix
@@ -152,5 +152,6 @@ stdenv.mkDerivation rec {
     license = licenses.mit;
     platforms = platforms.all;
     maintainers = with maintainers; [ infinisil ];
+    mainProgram = "botamusique";
   };
 }
diff --git a/pkgs/tools/audio/catnip-gtk4/default.nix b/pkgs/tools/audio/catnip-gtk4/default.nix
index 2175edb0c5230..da677d71bc03a 100644
--- a/pkgs/tools/audio/catnip-gtk4/default.nix
+++ b/pkgs/tools/audio/catnip-gtk4/default.nix
@@ -39,5 +39,6 @@ buildGoModule {
     homepage = "https://github.com/diamondburned/catnip-gtk4";
     license = licenses.gpl3Only;
     maintainers = with maintainers; [ figsoda ];
+    mainProgram = "catnip-gtk4";
   };
 }
diff --git a/pkgs/tools/audio/catnip/default.nix b/pkgs/tools/audio/catnip/default.nix
index de299738242e3..de8a609dfd618 100644
--- a/pkgs/tools/audio/catnip/default.nix
+++ b/pkgs/tools/audio/catnip/default.nix
@@ -46,5 +46,6 @@ buildGoModule rec {
     changelog = "https://github.com/noriah/catnip/releases/tag/${src.rev}";
     license = licenses.mit;
     maintainers = with maintainers; [ figsoda ];
+    mainProgram = "catnip";
   };
 }
diff --git a/pkgs/tools/audio/dsp/default.nix b/pkgs/tools/audio/dsp/default.nix
index e17e211d34026..8c218ab70e8e9 100644
--- a/pkgs/tools/audio/dsp/default.nix
+++ b/pkgs/tools/audio/dsp/default.nix
@@ -48,5 +48,6 @@ stdenv.mkDerivation (finalAttrs: {
     license = licenses.isc;
     maintainers = with maintainers; [ aaronjheng ];
     platforms = platforms.linux;
+    mainProgram = "dsp";
   };
 })
diff --git a/pkgs/tools/audio/essentia-extractor/default.nix b/pkgs/tools/audio/essentia-extractor/default.nix
index 4fbdd02e4404c..de3bf45d10c58 100644
--- a/pkgs/tools/audio/essentia-extractor/default.nix
+++ b/pkgs/tools/audio/essentia-extractor/default.nix
@@ -35,5 +35,6 @@ stdenv.mkDerivation rec {
     license = licenses.agpl3Plus;
     maintainers = with maintainers; [ lovesegfault ];
     platforms = [ "x86_64-linux" "i686-linux" ];
+    mainProgram = "streaming_extractor_music";
   };
 }
diff --git a/pkgs/tools/audio/gvolicon/default.nix b/pkgs/tools/audio/gvolicon/default.nix
index e15a048b991ce..1e552d64cfaa2 100644
--- a/pkgs/tools/audio/gvolicon/default.nix
+++ b/pkgs/tools/audio/gvolicon/default.nix
@@ -27,5 +27,6 @@ stdenv.mkDerivation {
     platforms = lib.platforms.linux;
     license = lib.licenses.gpl3Plus;
     maintainers = [ lib.maintainers.bennofs ];
+    mainProgram = "gvolicon";
   };
 }
diff --git a/pkgs/tools/audio/headset-charge-indicator/default.nix b/pkgs/tools/audio/headset-charge-indicator/default.nix
index bed9c415c83b5..40005ea9a6e16 100644
--- a/pkgs/tools/audio/headset-charge-indicator/default.nix
+++ b/pkgs/tools/audio/headset-charge-indicator/default.nix
@@ -58,5 +58,6 @@ stdenv.mkDerivation rec {
     platforms = platforms.linux;
     maintainers = with maintainers; [ zebreus ];
     license = licenses.bsd2;
+    mainProgram = "headset-charge-indicator.py";
   };
 }
diff --git a/pkgs/tools/audio/linuxwave/default.nix b/pkgs/tools/audio/linuxwave/default.nix
index 98860675dafcc..4d86b31c854ef 100644
--- a/pkgs/tools/audio/linuxwave/default.nix
+++ b/pkgs/tools/audio/linuxwave/default.nix
@@ -33,5 +33,6 @@ stdenv.mkDerivation (finalAttrs: {
     license = lib.licenses.mit;
     maintainers = with lib.maintainers; [ figsoda ];
     inherit (zig_0_10.meta) platforms;
+    mainProgram = "linuxwave";
   };
 })
diff --git a/pkgs/tools/audio/mictray/default.nix b/pkgs/tools/audio/mictray/default.nix
index e757bac966829..d93423e66b491 100644
--- a/pkgs/tools/audio/mictray/default.nix
+++ b/pkgs/tools/audio/mictray/default.nix
@@ -49,5 +49,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl3;
     platforms = platforms.linux;
     maintainers = [ maintainers.anpryl ];
+    mainProgram = "mictray";
   };
 }
diff --git a/pkgs/tools/audio/midimonster/default.nix b/pkgs/tools/audio/midimonster/default.nix
index ec55367474f5f..8ff97968b0008 100644
--- a/pkgs/tools/audio/midimonster/default.nix
+++ b/pkgs/tools/audio/midimonster/default.nix
@@ -52,5 +52,6 @@ stdenv.mkDerivation {
     license = licenses.bsd2;
     platforms = platforms.unix;
     maintainers = with maintainers; [keldu];
+    mainProgram = "midimonster";
   };
 }
diff --git a/pkgs/tools/audio/mp3cat/default.nix b/pkgs/tools/audio/mp3cat/default.nix
index dbcc458164de6..5819eb281b2fa 100644
--- a/pkgs/tools/audio/mp3cat/default.nix
+++ b/pkgs/tools/audio/mp3cat/default.nix
@@ -30,5 +30,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl2;
     maintainers = [ maintainers.omnipotententity ];
     platforms = platforms.all;
+    mainProgram = "mp3cat";
   };
 }
diff --git a/pkgs/tools/audio/mpd-discord-rpc/default.nix b/pkgs/tools/audio/mpd-discord-rpc/default.nix
index 786f5c062daa3..17bc6c6e419f7 100644
--- a/pkgs/tools/audio/mpd-discord-rpc/default.nix
+++ b/pkgs/tools/audio/mpd-discord-rpc/default.nix
@@ -36,5 +36,6 @@ rustPlatform.buildRustPackage rec {
     changelog = "https://github.com/JakeStanger/mpd-discord-rpc/blob/${src.rev}/CHANGELOG.md";
     license = licenses.mit;
     maintainers = with maintainers; [ kranzes ];
+    mainProgram = "mpd-discord-rpc";
   };
 }
diff --git a/pkgs/tools/audio/mpd-mpris/default.nix b/pkgs/tools/audio/mpd-mpris/default.nix
index f530ffc5d6640..dcf1e467300e4 100644
--- a/pkgs/tools/audio/mpd-mpris/default.nix
+++ b/pkgs/tools/audio/mpd-mpris/default.nix
@@ -39,5 +39,6 @@ buildGoModule rec {
     homepage = "https://github.com/natsukagami/mpd-mpris";
     license = licenses.mit;
     maintainers = with maintainers; [ doronbehar ];
+    mainProgram = "mpd-mpris";
   };
 }
diff --git a/pkgs/tools/audio/mpd-notification/default.nix b/pkgs/tools/audio/mpd-notification/default.nix
index 03b632ae7e0ef..845056c61414c 100644
--- a/pkgs/tools/audio/mpd-notification/default.nix
+++ b/pkgs/tools/audio/mpd-notification/default.nix
@@ -56,5 +56,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl3Plus;
     maintainers = with maintainers; [ CaitlinDavitt ];
     platforms = platforms.unix;
+    mainProgram = "mpd-notification";
   };
 }
diff --git a/pkgs/tools/audio/mpd-sima/default.nix b/pkgs/tools/audio/mpd-sima/default.nix
index 0da82ea0b9aa1..b123d2828c4c1 100644
--- a/pkgs/tools/audio/mpd-sima/default.nix
+++ b/pkgs/tools/audio/mpd-sima/default.nix
@@ -34,5 +34,6 @@ buildPythonApplication rec {
     license = licenses.gpl3Plus;
     platforms = platforms.linux;
     maintainers = with lib.maintainers; [ apfelkuchen6 ];
+    mainProgram = "mpd-sima";
   };
 }
diff --git a/pkgs/tools/audio/mpdas/default.nix b/pkgs/tools/audio/mpdas/default.nix
index 8b12b6fc16d70..04251854d48d2 100644
--- a/pkgs/tools/audio/mpdas/default.nix
+++ b/pkgs/tools/audio/mpdas/default.nix
@@ -29,5 +29,6 @@ stdenv.mkDerivation rec {
     license = licenses.bsd3;
     maintainers = [ maintainers.taketwo ];
     platforms = platforms.all;
+    mainProgram = "mpdas";
   };
 }
diff --git a/pkgs/tools/audio/mpdris2/default.nix b/pkgs/tools/audio/mpdris2/default.nix
index fd8618d6243d9..fd4b60f13e05d 100644
--- a/pkgs/tools/audio/mpdris2/default.nix
+++ b/pkgs/tools/audio/mpdris2/default.nix
@@ -50,5 +50,6 @@ python3.pkgs.buildPythonApplication rec {
     license = licenses.gpl3;
     maintainers = with maintainers; [ ];
     platforms = platforms.unix;
+    mainProgram = "mpDris2";
   };
 }
diff --git a/pkgs/tools/audio/nanotts/default.nix b/pkgs/tools/audio/nanotts/default.nix
index a68f1593b6467..41214ffe9206a 100644
--- a/pkgs/tools/audio/nanotts/default.nix
+++ b/pkgs/tools/audio/nanotts/default.nix
@@ -33,5 +33,6 @@ stdenv.mkDerivation {
     license = lib.licenses.asl20;
     maintainers = [ lib.maintainers.strikerlulu ];
     platforms = lib.platforms.linux;
+    mainProgram = "nanotts";
   };
 }
diff --git a/pkgs/tools/audio/pasystray/default.nix b/pkgs/tools/audio/pasystray/default.nix
index c010884665993..20708e82729dc 100644
--- a/pkgs/tools/audio/pasystray/default.nix
+++ b/pkgs/tools/audio/pasystray/default.nix
@@ -42,5 +42,6 @@ stdenv.mkDerivation rec {
     license = licenses.lgpl21Plus;
     maintainers = with maintainers; [ exlevan kamilchm ];
     platforms = platforms.linux;
+    mainProgram = "pasystray";
   };
 }
diff --git a/pkgs/tools/audio/patray/default.nix b/pkgs/tools/audio/patray/default.nix
index ff7b55689b8ff..e6800d943725d 100644
--- a/pkgs/tools/audio/patray/default.nix
+++ b/pkgs/tools/audio/patray/default.nix
@@ -38,5 +38,6 @@ python3.pkgs.buildPythonApplication rec {
     homepage = "https://github.com/pohmelie/patray";
     license = licenses.mit;
     maintainers = with maintainers; [ domenkozar ];
+    mainProgram = "patray";
   };
 }
diff --git a/pkgs/tools/audio/picotts/default.nix b/pkgs/tools/audio/picotts/default.nix
index 137fa838c6292..0b470aca5f942 100644
--- a/pkgs/tools/audio/picotts/default.nix
+++ b/pkgs/tools/audio/picotts/default.nix
@@ -20,5 +20,6 @@ stdenv.mkDerivation (finalAttrs: {
     license = lib.licenses.asl20;
     maintainers = [ lib.maintainers.canndrew ];
     platforms = lib.platforms.linux;
+    mainProgram = "pico2wave";
   };
 })
diff --git a/pkgs/tools/audio/piper/default.nix b/pkgs/tools/audio/piper/default.nix
index ec55b78c4f8b7..1f565b7475292 100644
--- a/pkgs/tools/audio/piper/default.nix
+++ b/pkgs/tools/audio/piper/default.nix
@@ -70,5 +70,6 @@ stdenv.mkDerivation (finalAttrs: {
     homepage = "https://github.com/rhasspy/piper";
     license = licenses.mit;
     maintainers = with maintainers; [ hexa ];
+    mainProgram = "piper";
   };
 })
diff --git a/pkgs/tools/audio/pnmixer/default.nix b/pkgs/tools/audio/pnmixer/default.nix
index da4654a3e5fcd..a65cad09b47dc 100644
--- a/pkgs/tools/audio/pnmixer/default.nix
+++ b/pkgs/tools/audio/pnmixer/default.nix
@@ -21,5 +21,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl3;
     platforms = platforms.linux;
     maintainers = with maintainers; [ campadrenalin romildo ];
+    mainProgram = "pnmixer";
   };
 }
diff --git a/pkgs/tools/audio/pw-volume/default.nix b/pkgs/tools/audio/pw-volume/default.nix
index 1a7b6c21a5025..13e39484b5773 100644
--- a/pkgs/tools/audio/pw-volume/default.nix
+++ b/pkgs/tools/audio/pw-volume/default.nix
@@ -23,5 +23,6 @@ rustPlatform.buildRustPackage rec {
     license = licenses.mit;
     maintainers = with maintainers; [ astro figsoda ];
     platforms = platforms.linux;
+    mainProgram = "pw-volume";
   };
 }
diff --git a/pkgs/tools/audio/stt/default.nix b/pkgs/tools/audio/stt/default.nix
index 9f3fcf05b5fad..89ed5f983973f 100644
--- a/pkgs/tools/audio/stt/default.nix
+++ b/pkgs/tools/audio/stt/default.nix
@@ -36,5 +36,6 @@ stdenv.mkDerivation rec {
     license = licenses.mpl20;
     platforms = [ "x86_64-linux" ];
     maintainers = with maintainers; [ rvolosatovs ];
+    mainProgram = "stt";
   };
 }
diff --git a/pkgs/tools/audio/tidal-dl/default.nix b/pkgs/tools/audio/tidal-dl/default.nix
index 2e8ba35e8ce43..eb23a4da3ccd9 100644
--- a/pkgs/tools/audio/tidal-dl/default.nix
+++ b/pkgs/tools/audio/tidal-dl/default.nix
@@ -21,5 +21,6 @@ buildPythonApplication rec {
     license = lib.licenses.asl20;
     maintainers = [ lib.maintainers.misterio77 ];
     platforms = lib.platforms.all;
+    mainProgram = "tidal-dl";
   };
 }
diff --git a/pkgs/tools/audio/unflac/default.nix b/pkgs/tools/audio/unflac/default.nix
index 9fc44469fec9b..41068d4797064 100644
--- a/pkgs/tools/audio/unflac/default.nix
+++ b/pkgs/tools/audio/unflac/default.nix
@@ -30,5 +30,6 @@ buildGoModule rec {
     license = licenses.mit;
     platforms = platforms.all;
     maintainers = with maintainers; [ felipeqq2 ];
+    mainProgram = "unflac";
   };
 }
diff --git a/pkgs/tools/audio/video2midi/default.nix b/pkgs/tools/audio/video2midi/default.nix
index 2c2ea77de6e7d..3d8661da3cabe 100644
--- a/pkgs/tools/audio/video2midi/default.nix
+++ b/pkgs/tools/audio/video2midi/default.nix
@@ -31,5 +31,6 @@ in pythonPackages.buildPythonApplication rec {
     license = licenses.gpl3Only;
     maintainers = [ ];
     platforms = platforms.linux;
+    mainProgram = "v2m.py";
   };
 }
diff --git a/pkgs/tools/audio/volctl/default.nix b/pkgs/tools/audio/volctl/default.nix
index e0a80f90a7191..0d33c586ed375 100644
--- a/pkgs/tools/audio/volctl/default.nix
+++ b/pkgs/tools/audio/volctl/default.nix
@@ -53,5 +53,6 @@ python3Packages.buildPythonApplication rec {
     license = licenses.gpl2;
     platforms = platforms.linux;
     maintainers = [ maintainers.romildo ];
+    mainProgram = "volctl";
   };
 }
diff --git a/pkgs/tools/audio/volumeicon/default.nix b/pkgs/tools/audio/volumeicon/default.nix
index 00690d016329c..cabd145cc6e0e 100644
--- a/pkgs/tools/audio/volumeicon/default.nix
+++ b/pkgs/tools/audio/volumeicon/default.nix
@@ -31,6 +31,7 @@ stdenv.mkDerivation rec {
     platforms = platforms.linux;
     maintainers = with maintainers; [ bobvanderlinden ];
     license = licenses.gpl3;
+    mainProgram = "volumeicon";
   };
 }
 
diff --git a/pkgs/tools/audio/whisper-ctranslate2/default.nix b/pkgs/tools/audio/whisper-ctranslate2/default.nix
index dd928ab3e418e..452af0a18b402 100644
--- a/pkgs/tools/audio/whisper-ctranslate2/default.nix
+++ b/pkgs/tools/audio/whisper-ctranslate2/default.nix
@@ -45,5 +45,6 @@ python3.pkgs.buildPythonApplication {
     changelog = "https://github.com/Softcatala/whisper-ctranslate2/releases/tag/${version}";
     license = licenses.mit;
     maintainers = with maintainers; [ happysalada ];
+    mainProgram = "whisper-ctranslate2";
   };
 }
diff --git a/pkgs/tools/audio/yabridgectl/default.nix b/pkgs/tools/audio/yabridgectl/default.nix
index 06bca00fc5b0f..41d32cd282a50 100644
--- a/pkgs/tools/audio/yabridgectl/default.nix
+++ b/pkgs/tools/audio/yabridgectl/default.nix
@@ -43,5 +43,6 @@ rustPlatform.buildRustPackage {
     license = licenses.gpl3Plus;
     maintainers = with maintainers; [ kira-bruneau ];
     platforms = yabridge.meta.platforms;
+    mainProgram = "yabridgectl";
   };
 }
diff --git a/pkgs/tools/filesystems/dupe-krill/default.nix b/pkgs/tools/filesystems/dupe-krill/default.nix
index d825c1b0fb09c..ee81db5c8707a 100644
--- a/pkgs/tools/filesystems/dupe-krill/default.nix
+++ b/pkgs/tools/filesystems/dupe-krill/default.nix
@@ -21,5 +21,6 @@ rustPlatform.buildRustPackage rec {
     homepage = "https://github.com/kornelski/dupe-krill";
     license = with licenses; [ mit ];
     maintainers = with maintainers; [ urbas ];
+    mainProgram = "dupe-krill";
   };
 }
diff --git a/pkgs/tools/filesystems/dysk/default.nix b/pkgs/tools/filesystems/dysk/default.nix
index 7ab7d544ab085..2dc4698f81729 100644
--- a/pkgs/tools/filesystems/dysk/default.nix
+++ b/pkgs/tools/filesystems/dysk/default.nix
@@ -32,5 +32,6 @@ rustPlatform.buildRustPackage rec {
     changelog = "https://github.com/Canop/dysk/blob/${src.rev}/CHANGELOG.md";
     license = licenses.mit;
     maintainers = with maintainers; [ figsoda koral ];
+    mainProgram = "dysk";
   };
 }
diff --git a/pkgs/tools/filesystems/eiciel/default.nix b/pkgs/tools/filesystems/eiciel/default.nix
index dff1700d73fc2..a3f7378c205ce 100644
--- a/pkgs/tools/filesystems/eiciel/default.nix
+++ b/pkgs/tools/filesystems/eiciel/default.nix
@@ -52,5 +52,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl2Plus;
     maintainers = with maintainers; [ sersorrel ];
     platforms = platforms.linux;
+    mainProgram = "eiciel";
   };
 }
diff --git a/pkgs/tools/filesystems/ext4magic/default.nix b/pkgs/tools/filesystems/ext4magic/default.nix
index ed9fa6df969b1..bb23f58c38c61 100644
--- a/pkgs/tools/filesystems/ext4magic/default.nix
+++ b/pkgs/tools/filesystems/ext4magic/default.nix
@@ -36,5 +36,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl2;
     platforms = platforms.linux;
     maintainers = [ maintainers.rkoe ];
+    mainProgram = "ext4magic";
   };
 }
diff --git a/pkgs/tools/filesystems/extundelete/default.nix b/pkgs/tools/filesystems/extundelete/default.nix
index 276f6139b794a..0c3062fb11cac 100644
--- a/pkgs/tools/filesystems/extundelete/default.nix
+++ b/pkgs/tools/filesystems/extundelete/default.nix
@@ -25,5 +25,6 @@ stdenv.mkDerivation {
     license = licenses.gpl2;
     platforms = platforms.linux;
     maintainers = [ maintainers.domenkozar ];
+    mainProgram = "extundelete";
   };
 }
diff --git a/pkgs/tools/filesystems/fatresize/default.nix b/pkgs/tools/filesystems/fatresize/default.nix
index 8f258a79f7dea..80f7e5ecd4ae9 100644
--- a/pkgs/tools/filesystems/fatresize/default.nix
+++ b/pkgs/tools/filesystems/fatresize/default.nix
@@ -22,5 +22,6 @@ stdenv.mkDerivation rec {
     homepage = "https://github.com/ya-mouse/fatresize";
     platforms = platforms.linux;
     license = licenses.gpl3;
+    mainProgram = "fatresize";
   };
 }
diff --git a/pkgs/tools/filesystems/fatsort/default.nix b/pkgs/tools/filesystems/fatsort/default.nix
index ef7111dd72ff0..d1604e49a32e0 100644
--- a/pkgs/tools/filesystems/fatsort/default.nix
+++ b/pkgs/tools/filesystems/fatsort/default.nix
@@ -39,5 +39,6 @@ stdenv.mkDerivation rec {
     maintainers = [ maintainers.kovirobi ];
     license = licenses.gpl2Plus;
     platforms = platforms.unix;
+    mainProgram = "fatsort";
   };
 }
diff --git a/pkgs/tools/filesystems/file-rename/default.nix b/pkgs/tools/filesystems/file-rename/default.nix
index 133f446f8a98f..8bc7a899cd3ba 100644
--- a/pkgs/tools/filesystems/file-rename/default.nix
+++ b/pkgs/tools/filesystems/file-rename/default.nix
@@ -26,5 +26,6 @@ perlPackages.buildPerlPackage {
     description = "Perl extension for renaming multiple files";
     license = licenses.artistic1;
     maintainers = with maintainers; [ peterhoeg ];
+    mainProgram = "rename";
   };
 }
diff --git a/pkgs/tools/filesystems/fuse-7z-ng/default.nix b/pkgs/tools/filesystems/fuse-7z-ng/default.nix
index dad5d2dd9e6c0..86db1f4872a4a 100644
--- a/pkgs/tools/filesystems/fuse-7z-ng/default.nix
+++ b/pkgs/tools/filesystems/fuse-7z-ng/default.nix
@@ -44,5 +44,6 @@ stdenv.mkDerivation rec {
     '';
     platforms = platforms.linux;
     license = licenses.gpl3Plus;
+    mainProgram = "fuse-7z-ng";
   };
 }
diff --git a/pkgs/tools/filesystems/fuse-archive/default.nix b/pkgs/tools/filesystems/fuse-archive/default.nix
index 031232acbe38d..58f48a2644983 100644
--- a/pkgs/tools/filesystems/fuse-archive/default.nix
+++ b/pkgs/tools/filesystems/fuse-archive/default.nix
@@ -38,6 +38,7 @@ stdenv.mkDerivation rec {
     changelog = "https://github.com/google/fuse-archive/releases/tag/v${version}";
     license = licenses.asl20;
     maintainers = with maintainers; [ icyrockcom ];
+    mainProgram = "fuse-archive";
   };
 
   inherit (fuse.meta) platforms;
diff --git a/pkgs/tools/filesystems/fuse-overlayfs/default.nix b/pkgs/tools/filesystems/fuse-overlayfs/default.nix
index b417c9654292c..6afbda9f27cde 100644
--- a/pkgs/tools/filesystems/fuse-overlayfs/default.nix
+++ b/pkgs/tools/filesystems/fuse-overlayfs/default.nix
@@ -27,5 +27,6 @@ stdenv.mkDerivation rec {
     maintainers = with maintainers; [ ma9e ] ++ teams.podman.members;
     platforms = platforms.linux;
     inherit (src.meta) homepage;
+    mainProgram = "fuse-overlayfs";
   };
 }
diff --git a/pkgs/tools/filesystems/fuseiso/default.nix b/pkgs/tools/filesystems/fuseiso/default.nix
index 7e44e7c15f9cb..b731e9c7cc962 100644
--- a/pkgs/tools/filesystems/fuseiso/default.nix
+++ b/pkgs/tools/filesystems/fuseiso/default.nix
@@ -51,5 +51,6 @@ stdenv.mkDerivation rec {
     homepage = "https://sourceforge.net/projects/fuseiso";
     license = licenses.gpl2;
     platforms = platforms.linux;
+    mainProgram = "fuseiso";
   };
 }
diff --git a/pkgs/tools/filesystems/fwanalyzer/default.nix b/pkgs/tools/filesystems/fwanalyzer/default.nix
index a0b1d2df14356..26fd45fa90eaa 100644
--- a/pkgs/tools/filesystems/fwanalyzer/default.nix
+++ b/pkgs/tools/filesystems/fwanalyzer/default.nix
@@ -35,5 +35,6 @@ buildGoModule rec {
     homepage = "https://github.com/cruise-automation/fwanalyzer";
     license = with licenses; [ asl20 ];
     maintainers = with maintainers; [ fab ];
+    mainProgram = "fwanalyzer";
   };
 }
diff --git a/pkgs/tools/filesystems/garage/default.nix b/pkgs/tools/filesystems/garage/default.nix
index fe72905d0fbea..894840d2dd04f 100644
--- a/pkgs/tools/filesystems/garage/default.nix
+++ b/pkgs/tools/filesystems/garage/default.nix
@@ -73,6 +73,7 @@ let
       maintainers = with lib.maintainers; [ nickcao _0x4A6F teutat3s raitobezarius ];
       knownVulnerabilities = (lib.optional eol "Garage version ${version} is EOL");
       inherit broken;
+      mainProgram = "garage";
     };
   };
 in
diff --git a/pkgs/tools/filesystems/genext2fs/default.nix b/pkgs/tools/filesystems/genext2fs/default.nix
index ecd77781d39b6..b640c99dc82f0 100644
--- a/pkgs/tools/filesystems/genext2fs/default.nix
+++ b/pkgs/tools/filesystems/genext2fs/default.nix
@@ -31,5 +31,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl2;
     platforms = platforms.all;
     maintainers = [ maintainers.bjornfor ];
+    mainProgram = "genext2fs";
   };
 }
diff --git a/pkgs/tools/filesystems/genimage/default.nix b/pkgs/tools/filesystems/genimage/default.nix
index 0961ad904f3ff..ab93f4233d8fc 100644
--- a/pkgs/tools/filesystems/genimage/default.nix
+++ b/pkgs/tools/filesystems/genimage/default.nix
@@ -27,5 +27,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl2Plus;
     platforms = platforms.all;
     maintainers = [ maintainers.bjornfor ];
+    mainProgram = "genimage";
   };
 }
diff --git a/pkgs/tools/filesystems/genromfs/default.nix b/pkgs/tools/filesystems/genromfs/default.nix
index 3427ce54a1721..6c40c4ad94cd6 100644
--- a/pkgs/tools/filesystems/genromfs/default.nix
+++ b/pkgs/tools/filesystems/genromfs/default.nix
@@ -21,5 +21,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl2;
     maintainers = with maintainers; [ ];
     platforms = platforms.all;
+    mainProgram = "genromfs";
   };
 }
diff --git a/pkgs/tools/filesystems/gitfs/default.nix b/pkgs/tools/filesystems/gitfs/default.nix
index f49f555983f30..c5e388fc5ffbc 100644
--- a/pkgs/tools/filesystems/gitfs/default.nix
+++ b/pkgs/tools/filesystems/gitfs/default.nix
@@ -39,5 +39,6 @@ python3Packages.buildPythonApplication rec {
     license = lib.licenses.asl20;
     platforms = lib.platforms.unix;
     maintainers = [ lib.maintainers.robbinch ];
+    mainProgram = "gitfs";
   };
 }
diff --git a/pkgs/tools/filesystems/go-mtpfs/default.nix b/pkgs/tools/filesystems/go-mtpfs/default.nix
index f82e5b7c362a7..f3ed4fb6ab98a 100644
--- a/pkgs/tools/filesystems/go-mtpfs/default.nix
+++ b/pkgs/tools/filesystems/go-mtpfs/default.nix
@@ -30,5 +30,6 @@ buildGoModule rec {
     license = licenses.bsd3;
     maintainers = with maintainers; [ ];
     broken = stdenv.isDarwin;
+    mainProgram = "go-mtpfs";
   };
 }
diff --git a/pkgs/tools/filesystems/goofys/default.nix b/pkgs/tools/filesystems/goofys/default.nix
index 0c250eaeb4f42..30c78ad31993c 100644
--- a/pkgs/tools/filesystems/goofys/default.nix
+++ b/pkgs/tools/filesystems/goofys/default.nix
@@ -31,6 +31,7 @@ buildGoModule {
     license = [ lib.licenses.mit ];
     maintainers = [ lib.maintainers.adisbladis ];
     broken = stdenv.isDarwin; # needs to update gopsutil to at least v3.21.3 to include https://github.com/shirou/gopsutil/pull/1042
+    mainProgram = "goofys";
   };
 
 }
diff --git a/pkgs/tools/filesystems/gpart/default.nix b/pkgs/tools/filesystems/gpart/default.nix
index eafbe066ac94e..a8466d3462e8f 100644
--- a/pkgs/tools/filesystems/gpart/default.nix
+++ b/pkgs/tools/filesystems/gpart/default.nix
@@ -29,5 +29,6 @@ stdenv.mkDerivation rec {
     '';
     license = licenses.gpl2Plus;
     platforms = platforms.linux;
+    mainProgram = "gpart";
   };
 }
diff --git a/pkgs/tools/filesystems/grive2/default.nix b/pkgs/tools/filesystems/grive2/default.nix
index d5a19f42f3f03..41afc98e7f94e 100644
--- a/pkgs/tools/filesystems/grive2/default.nix
+++ b/pkgs/tools/filesystems/grive2/default.nix
@@ -42,5 +42,6 @@ stdenv.mkDerivation rec {
     homepage = "https://github.com/vitalif/grive2";
     license = licenses.gpl2;
     platforms = platforms.linux;
+    mainProgram = "grive";
   };
 }
diff --git a/pkgs/tools/filesystems/httm/default.nix b/pkgs/tools/filesystems/httm/default.nix
index 31ea85532462d..3a36af72462e7 100644
--- a/pkgs/tools/filesystems/httm/default.nix
+++ b/pkgs/tools/filesystems/httm/default.nix
@@ -37,5 +37,6 @@ rustPlatform.buildRustPackage rec {
     changelog = "https://github.com/kimono-koans/httm/releases/tag/${version}";
     license = licenses.mpl20;
     maintainers = with maintainers; [ wyndon ];
+    mainProgram = "httm";
   };
 }
diff --git a/pkgs/tools/filesystems/httpdirfs/default.nix b/pkgs/tools/filesystems/httpdirfs/default.nix
index e027d5dd8df52..6163e1a0158ab 100644
--- a/pkgs/tools/filesystems/httpdirfs/default.nix
+++ b/pkgs/tools/filesystems/httpdirfs/default.nix
@@ -22,5 +22,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl3Only;
     maintainers = with maintainers; [ sbruder schnusch ];
     platforms = platforms.unix;
+    mainProgram = "httpdirfs";
   };
 }
diff --git a/pkgs/tools/filesystems/ifuse/default.nix b/pkgs/tools/filesystems/ifuse/default.nix
index 010aeaefabf3b..8f2e1f2a6ffb0 100644
--- a/pkgs/tools/filesystems/ifuse/default.nix
+++ b/pkgs/tools/filesystems/ifuse/default.nix
@@ -42,5 +42,6 @@ stdenv.mkDerivation rec {
     license = licenses.lgpl21Plus;
     platforms = platforms.unix;
     maintainers = with maintainers; [ infinisil ];
+    mainProgram = "ifuse";
   };
 }
diff --git a/pkgs/tools/filesystems/ioztat/default.nix b/pkgs/tools/filesystems/ioztat/default.nix
index b28f0a36661be..b5f949ad4f2c7 100644
--- a/pkgs/tools/filesystems/ioztat/default.nix
+++ b/pkgs/tools/filesystems/ioztat/default.nix
@@ -54,5 +54,6 @@ stdenv.mkDerivation rec {
     license = licenses.bsd2;
     platforms = with platforms; linux ++ freebsd;
     maintainers = with maintainers; [ numinit ];
+    mainProgram = "ioztat";
   };
 }
diff --git a/pkgs/tools/filesystems/jefferson/default.nix b/pkgs/tools/filesystems/jefferson/default.nix
index 762541f8d27a6..948de453ec187 100644
--- a/pkgs/tools/filesystems/jefferson/default.nix
+++ b/pkgs/tools/filesystems/jefferson/default.nix
@@ -37,5 +37,6 @@ python3.pkgs.buildPythonApplication rec {
     homepage = "https://github.com/onekey-sec/jefferson";
     license = licenses.mit;
     maintainers = with maintainers; [ tnias vlaci ];
+    mainProgram = "jefferson";
   };
 }
diff --git a/pkgs/tools/filesystems/jmtpfs/default.nix b/pkgs/tools/filesystems/jmtpfs/default.nix
index 2754d223a6baa..6c5dd3d30c705 100644
--- a/pkgs/tools/filesystems/jmtpfs/default.nix
+++ b/pkgs/tools/filesystems/jmtpfs/default.nix
@@ -28,5 +28,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl3Only;
     platforms = platforms.unix;
     maintainers = [ maintainers.coconnor ];
+    mainProgram = "jmtpfs";
   };
 }
diff --git a/pkgs/tools/filesystems/kdiskmark/default.nix b/pkgs/tools/filesystems/kdiskmark/default.nix
index 6712b96f7fdd0..200705098409b 100644
--- a/pkgs/tools/filesystems/kdiskmark/default.nix
+++ b/pkgs/tools/filesystems/kdiskmark/default.nix
@@ -49,6 +49,7 @@ stdenv.mkDerivation rec {
     maintainers = [ maintainers.symphorien ];
     license = licenses.gpl3Only;
     platforms = platforms.linux;
+    mainProgram = "kdiskmark";
   };
 }
 
diff --git a/pkgs/tools/filesystems/mhddfs/default.nix b/pkgs/tools/filesystems/mhddfs/default.nix
index 2cc6f69bb0bab..58986c25dbf27 100644
--- a/pkgs/tools/filesystems/mhddfs/default.nix
+++ b/pkgs/tools/filesystems/mhddfs/default.nix
@@ -31,5 +31,6 @@ stdenv.mkDerivation rec {
     description = "Combines a several mount points into the single one";
     license = lib.licenses.gpl3;
     maintainers = [ lib.maintainers.makefu ];
+    mainProgram = "mhddfs";
   };
 }
diff --git a/pkgs/tools/filesystems/mkspiffs/default.nix b/pkgs/tools/filesystems/mkspiffs/default.nix
index 30312ec7dc7bf..2b0e2cdadb379 100644
--- a/pkgs/tools/filesystems/mkspiffs/default.nix
+++ b/pkgs/tools/filesystems/mkspiffs/default.nix
@@ -28,5 +28,6 @@ stdenv.mkDerivation rec {
     homepage = "https://github.com/igrr/mkspiffs";
     maintainers = with maintainers; [ haslersn ];
     platforms = platforms.linux;
+    mainProgram = "mkspiffs";
   };
 }
diff --git a/pkgs/tools/filesystems/mount-zip/default.nix b/pkgs/tools/filesystems/mount-zip/default.nix
index 74d9b1d370b8e..c3fea94f42f58 100644
--- a/pkgs/tools/filesystems/mount-zip/default.nix
+++ b/pkgs/tools/filesystems/mount-zip/default.nix
@@ -28,5 +28,6 @@ stdenv.mkDerivation (finalAttrs: {
     license = licenses.gpl3;
     maintainers = with maintainers; [ arti5an ];
     platforms = platforms.linux;
+    mainProgram = "mount-zip";
   };
 })
diff --git a/pkgs/tools/filesystems/mp3fs/default.nix b/pkgs/tools/filesystems/mp3fs/default.nix
index 6f872500e6b13..0412a99beee0e 100644
--- a/pkgs/tools/filesystems/mp3fs/default.nix
+++ b/pkgs/tools/filesystems/mp3fs/default.nix
@@ -46,5 +46,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl3Plus;
     platforms = platforms.unix;
     maintainers = with maintainers; [ Luflosi ];
+    mainProgram = "mp3fs";
   };
 }
diff --git a/pkgs/tools/filesystems/mtpfs/default.nix b/pkgs/tools/filesystems/mtpfs/default.nix
index 0a6623bfdc4af..d84f9cc9b9b13 100644
--- a/pkgs/tools/filesystems/mtpfs/default.nix
+++ b/pkgs/tools/filesystems/mtpfs/default.nix
@@ -19,5 +19,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl3;
     maintainers = [ maintainers.qknight ];
     broken = stdenv.isDarwin; # never built on Hydra https://hydra.nixos.org/job/nixpkgs/trunk/mtpfs.x86_64-darwin
+    mainProgram = "mtpfs";
   };
 }
diff --git a/pkgs/tools/filesystems/rdfind/default.nix b/pkgs/tools/filesystems/rdfind/default.nix
index c363ee5613745..59724c0c7c523 100644
--- a/pkgs/tools/filesystems/rdfind/default.nix
+++ b/pkgs/tools/filesystems/rdfind/default.nix
@@ -25,5 +25,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl2Plus;
     maintainers = [ maintainers.wmertens ];
     platforms = platforms.all;
+    mainProgram = "rdfind";
   };
 }
diff --git a/pkgs/tools/filesystems/rmfuse/default.nix b/pkgs/tools/filesystems/rmfuse/default.nix
index ace05d0616652..5d3a6a340dbb0 100644
--- a/pkgs/tools/filesystems/rmfuse/default.nix
+++ b/pkgs/tools/filesystems/rmfuse/default.nix
@@ -45,5 +45,6 @@ python3.pkgs.buildPythonApplication rec {
       system.
     '';
     maintainers = with lib.maintainers; [ adisbladis ];
+    mainProgram = "rmfuse";
   };
 }
diff --git a/pkgs/tools/filesystems/rmount/default.nix b/pkgs/tools/filesystems/rmount/default.nix
index 1d8ced17aae05..ec4bb13927122 100644
--- a/pkgs/tools/filesystems/rmount/default.nix
+++ b/pkgs/tools/filesystems/rmount/default.nix
@@ -28,5 +28,6 @@ stdenv.mkDerivation rec {
     license = licenses.mit;
     maintainers = [ maintainers.luis ];
     platforms = platforms.linux;
+    mainProgram = "rmount";
   };
 }
diff --git a/pkgs/tools/filesystems/rnm/default.nix b/pkgs/tools/filesystems/rnm/default.nix
index 69ba0270ecc0c..479feabb8ebc5 100644
--- a/pkgs/tools/filesystems/rnm/default.nix
+++ b/pkgs/tools/filesystems/rnm/default.nix
@@ -29,5 +29,6 @@ stdenv.mkDerivation rec {
     changelog = "https://github.com/neurobin/rnm/blob/${version}/ChangeLog";
     platforms = lib.platforms.all;
     license = licenses.gpl3Only;
+    mainProgram = "rnm";
   };
 }
diff --git a/pkgs/tools/filesystems/romdirfs/default.nix b/pkgs/tools/filesystems/romdirfs/default.nix
index 0304508d41ebc..cc711e57cdb69 100644
--- a/pkgs/tools/filesystems/romdirfs/default.nix
+++ b/pkgs/tools/filesystems/romdirfs/default.nix
@@ -20,5 +20,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl3;
     platforms = platforms.unix;
     maintainers = with maintainers; [ ];
+    mainProgram = "romdirfs";
   };
 }
diff --git a/pkgs/tools/filesystems/s3backer/default.nix b/pkgs/tools/filesystems/s3backer/default.nix
index bfe9f22747568..3585408a2f7d0 100644
--- a/pkgs/tools/filesystems/s3backer/default.nix
+++ b/pkgs/tools/filesystems/s3backer/default.nix
@@ -33,5 +33,6 @@ stdenv.mkDerivation rec {
     description = "FUSE-based single file backing store via Amazon S3";
     license = licenses.gpl2Plus;
     platforms = platforms.unix;
+    mainProgram = "s3backer";
   };
 }
diff --git a/pkgs/tools/filesystems/sandboxfs/default.nix b/pkgs/tools/filesystems/sandboxfs/default.nix
index bafa39272727a..76eb667bceaa0 100644
--- a/pkgs/tools/filesystems/sandboxfs/default.nix
+++ b/pkgs/tools/filesystems/sandboxfs/default.nix
@@ -30,5 +30,6 @@ rustPlatform.buildRustPackage rec {
     homepage = "https://github.com/bazelbuild/sandboxfs";
     license = with licenses; [ asl20 ];
     maintainers = with maintainers; [ jeremyschlatter ];
+    mainProgram = "sandboxfs";
   };
 }
diff --git a/pkgs/tools/filesystems/sasquatch/default.nix b/pkgs/tools/filesystems/sasquatch/default.nix
index 258814b8905b4..f8d66683fccbf 100644
--- a/pkgs/tools/filesystems/sasquatch/default.nix
+++ b/pkgs/tools/filesystems/sasquatch/default.nix
@@ -71,5 +71,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl2Plus;
     maintainers = [ maintainers.pamplemousse ];
     platforms = platforms.linux;
+    mainProgram = "sasquatch";
   };
 }
diff --git a/pkgs/tools/filesystems/sdat2img/default.nix b/pkgs/tools/filesystems/sdat2img/default.nix
index 4176eabad4014..93493356eb512 100644
--- a/pkgs/tools/filesystems/sdat2img/default.nix
+++ b/pkgs/tools/filesystems/sdat2img/default.nix
@@ -22,5 +22,6 @@ python3Packages.buildPythonApplication {
     license = lib.licenses.mit;
     maintainers = [ lib.maintainers.xaverdh ];
     platforms = lib.platforms.unix;
+    mainProgram = "sdat2img";
   };
 }
diff --git a/pkgs/tools/filesystems/securefs/default.nix b/pkgs/tools/filesystems/securefs/default.nix
index 791c01d8eed81..fe148e955cb2a 100644
--- a/pkgs/tools/filesystems/securefs/default.nix
+++ b/pkgs/tools/filesystems/securefs/default.nix
@@ -35,5 +35,6 @@ stdenv.mkDerivation rec {
     '';
     license = with licenses; [ bsd2 mit ];
     platforms = platforms.unix;
+    mainProgram = "securefs";
   };
 }
diff --git a/pkgs/tools/filesystems/sftpman/default.nix b/pkgs/tools/filesystems/sftpman/default.nix
index 267b2b649c302..579c03992ddef 100644
--- a/pkgs/tools/filesystems/sftpman/default.nix
+++ b/pkgs/tools/filesystems/sftpman/default.nix
@@ -21,5 +21,6 @@ python3Packages.buildPythonApplication rec {
     license = licenses.gpl3;
     platforms = platforms.unix;
     maintainers = with maintainers; [ contrun ];
+    mainProgram = "sftpman";
   };
 }
diff --git a/pkgs/tools/filesystems/simple-mtpfs/default.nix b/pkgs/tools/filesystems/simple-mtpfs/default.nix
index 3cb2aa97007b9..994b785c444e4 100644
--- a/pkgs/tools/filesystems/simple-mtpfs/default.nix
+++ b/pkgs/tools/filesystems/simple-mtpfs/default.nix
@@ -27,5 +27,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl2Plus;
     platforms = platforms.linux;
     maintainers = with maintainers; [ laalsaas ];
+    mainProgram = "simple-mtpfs";
   };
 }
diff --git a/pkgs/tools/filesystems/smbnetfs/default.nix b/pkgs/tools/filesystems/smbnetfs/default.nix
index a1831d44ada4c..120b30cbb1d1d 100644
--- a/pkgs/tools/filesystems/smbnetfs/default.nix
+++ b/pkgs/tools/filesystems/smbnetfs/default.nix
@@ -18,5 +18,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl2;
     downloadPage = "https://sourceforge.net/projects/smbnetfs/files/smbnetfs";
     homepage = "https://sourceforge.net/projects/smbnetfs/";
+    mainProgram = "smbnetfs";
   };
 }
diff --git a/pkgs/tools/filesystems/snapraid/default.nix b/pkgs/tools/filesystems/snapraid/default.nix
index d945a4a400942..3afabf8cd6435 100644
--- a/pkgs/tools/filesystems/snapraid/default.nix
+++ b/pkgs/tools/filesystems/snapraid/default.nix
@@ -24,5 +24,6 @@ stdenv.mkDerivation rec {
     license = lib.licenses.gpl3;
     maintainers = [ lib.maintainers.makefu ];
     platforms = lib.platforms.unix;
+    mainProgram = "snapraid";
   };
 }
diff --git a/pkgs/tools/filesystems/stratis-cli/default.nix b/pkgs/tools/filesystems/stratis-cli/default.nix
index e927f2daf256c..3a1838ef303eb 100644
--- a/pkgs/tools/filesystems/stratis-cli/default.nix
+++ b/pkgs/tools/filesystems/stratis-cli/default.nix
@@ -44,5 +44,6 @@ python3Packages.buildPythonApplication rec {
     homepage = "https://stratis-storage.github.io";
     license = licenses.asl20;
     maintainers = with maintainers; [ nickcao ];
+    mainProgram = "stratis";
   };
 }
diff --git a/pkgs/tools/filesystems/svnfs/default.nix b/pkgs/tools/filesystems/svnfs/default.nix
index e892d89dc3b30..8aa66de8da3fd 100644
--- a/pkgs/tools/filesystems/svnfs/default.nix
+++ b/pkgs/tools/filesystems/svnfs/default.nix
@@ -40,5 +40,6 @@ stdenv.mkDerivation rec {
     license = lib.licenses.gpl2Only;
     maintainers = [lib.maintainers.marcweber];
     platforms = lib.platforms.unix;
+    mainProgram = "svnfs";
   };
 }
diff --git a/pkgs/tools/filesystems/tar2ext4/default.nix b/pkgs/tools/filesystems/tar2ext4/default.nix
index 2168bc1aa3122..2d5a5f2ef9ff0 100644
--- a/pkgs/tools/filesystems/tar2ext4/default.nix
+++ b/pkgs/tools/filesystems/tar2ext4/default.nix
@@ -18,5 +18,6 @@ buildGoModule rec {
     description = "Convert a tar archive to an ext4 image";
     maintainers = with maintainers; [ qyliss ];
     license = licenses.mit;
+    mainProgram = "tar2ext4";
   };
 }
diff --git a/pkgs/tools/filesystems/u3-tool/default.nix b/pkgs/tools/filesystems/u3-tool/default.nix
index 6abab83b0fd0a..e666c893b7986 100644
--- a/pkgs/tools/filesystems/u3-tool/default.nix
+++ b/pkgs/tools/filesystems/u3-tool/default.nix
@@ -17,5 +17,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl2;
     platforms = with platforms; linux;
     maintainers = with maintainers; [ makefu ];
+    mainProgram = "u3-tool";
   };
 }
diff --git a/pkgs/tools/filesystems/ubidump/default.nix b/pkgs/tools/filesystems/ubidump/default.nix
index 623cef8844760..c038042b6871b 100644
--- a/pkgs/tools/filesystems/ubidump/default.nix
+++ b/pkgs/tools/filesystems/ubidump/default.nix
@@ -36,6 +36,7 @@ python3.pkgs.buildPythonApplication rec {
     homepage = "https://github.com/nlitsme/ubidump";
     license = licenses.mit;
     maintainers = with maintainers; [ sgo ];
+    mainProgram = "ubidump";
   };
 }
 
diff --git a/pkgs/tools/filesystems/wdfs/default.nix b/pkgs/tools/filesystems/wdfs/default.nix
index 29d8b4c2887b5..3f8897c091bc8 100644
--- a/pkgs/tools/filesystems/wdfs/default.nix
+++ b/pkgs/tools/filesystems/wdfs/default.nix
@@ -23,5 +23,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl2Plus;
     description = "User-space filesystem that allows to mount a webdav share";
     platforms = platforms.unix;
+    mainProgram = "wdfs";
   };
 }
diff --git a/pkgs/tools/filesystems/wipefreespace/default.nix b/pkgs/tools/filesystems/wipefreespace/default.nix
index f9d586d91d68b..bf2ddb391c86e 100644
--- a/pkgs/tools/filesystems/wipefreespace/default.nix
+++ b/pkgs/tools/filesystems/wipefreespace/default.nix
@@ -49,5 +49,6 @@ stdenv.mkDerivation rec {
     license = licenses.gpl2Plus;
     platforms = platforms.linux;
     maintainers = with maintainers; [ catap ];
+    mainProgram = "wipefreespace";
   };
 }
diff --git a/pkgs/tools/filesystems/yandex-disk/default.nix b/pkgs/tools/filesystems/yandex-disk/default.nix
index 109781f612a26..94907ee4fd2fd 100644
--- a/pkgs/tools/filesystems/yandex-disk/default.nix
+++ b/pkgs/tools/filesystems/yandex-disk/default.nix
@@ -67,5 +67,6 @@ stdenv.mkDerivation rec {
        * faster syncing with Disk's server;
        * no need to be constantly connected to work with files.
     '';
+    mainProgram = "yandex-disk";
   };
 }
diff --git a/pkgs/tools/filesystems/zerofree/default.nix b/pkgs/tools/filesystems/zerofree/default.nix
index 1447ca36a1364..d44e92a33c46d 100644
--- a/pkgs/tools/filesystems/zerofree/default.nix
+++ b/pkgs/tools/filesystems/zerofree/default.nix
@@ -29,5 +29,6 @@ in stdenv.mkDerivation rec {
     platforms = lib.platforms.linux;
     license = lib.licenses.gpl2;
     maintainers = [ lib.maintainers.theuni ];
+    mainProgram = "zerofree";
   };
 }
diff --git a/pkgs/tools/filesystems/zkfuse/default.nix b/pkgs/tools/filesystems/zkfuse/default.nix
index 320ccde4cc539..00d78af0146fd 100644
--- a/pkgs/tools/filesystems/zkfuse/default.nix
+++ b/pkgs/tools/filesystems/zkfuse/default.nix
@@ -37,5 +37,6 @@ stdenv.mkDerivation rec {
     platforms = platforms.linux;
     maintainers = with maintainers; [ ztzg ];
     license = licenses.asl20;
+    mainProgram = "zkfuse";
   };
 }
diff --git a/pkgs/tools/filesystems/zpool-auto-expand-partitions/default.nix b/pkgs/tools/filesystems/zpool-auto-expand-partitions/default.nix
index 9af487b59c4e1..8fced13e93db4 100644
--- a/pkgs/tools/filesystems/zpool-auto-expand-partitions/default.nix
+++ b/pkgs/tools/filesystems/zpool-auto-expand-partitions/default.nix
@@ -46,5 +46,6 @@ rustPlatform.buildRustPackage rec {
     homepage = "https://github.com/DeterminateSystems/zpool-auto-expand-partitions";
     license = licenses.asl20;
     maintainers = teams.determinatesystems.members;
+    mainProgram = "zpool_part_disks";
   };
 }
diff --git a/pkgs/tools/filesystems/zpool-iostat-viz/default.nix b/pkgs/tools/filesystems/zpool-iostat-viz/default.nix
index a9e4dfe8ab744..4f546e544e66c 100644
--- a/pkgs/tools/filesystems/zpool-iostat-viz/default.nix
+++ b/pkgs/tools/filesystems/zpool-iostat-viz/default.nix
@@ -37,5 +37,6 @@ python3Packages.buildPythonApplication rec {
     homepage = "https://github.com/chadmiller/zpool-iostat-viz";
     license = licenses.bsd2;
     maintainers = with maintainers; [ julm ];
+    mainProgram = "zpool-iostat-viz";
   };
 }
diff --git a/pkgs/tools/virtualization/alpine-make-vm-image/default.nix b/pkgs/tools/virtualization/alpine-make-vm-image/default.nix
index 95cfaea90e43c..c06efa3617f0e 100644
--- a/pkgs/tools/virtualization/alpine-make-vm-image/default.nix
+++ b/pkgs/tools/virtualization/alpine-make-vm-image/default.nix
@@ -32,5 +32,6 @@ stdenv.mkDerivation rec {
     maintainers = with maintainers; [ qyliss ];
     license = licenses.mit;
     platforms = platforms.unix;
+    mainProgram = "alpine-make-vm-image";
   };
 }
diff --git a/pkgs/tools/virtualization/amazon-ecs-cli/default.nix b/pkgs/tools/virtualization/amazon-ecs-cli/default.nix
index fa74aa26cec39..16b43012e2600 100644
--- a/pkgs/tools/virtualization/amazon-ecs-cli/default.nix
+++ b/pkgs/tools/virtualization/amazon-ecs-cli/default.nix
@@ -34,5 +34,6 @@ stdenv.mkDerivation rec {
     license = licenses.asl20;
     maintainers = with maintainers; [ Scriptkiddi ];
     platforms = [ "x86_64-linux" "x86_64-darwin" ];
+    mainProgram = "ecs-cli";
   };
 }
diff --git a/pkgs/tools/virtualization/distrobuilder/default.nix b/pkgs/tools/virtualization/distrobuilder/default.nix
index 3619d2f25a14b..a1a0cfde0fe73 100644
--- a/pkgs/tools/virtualization/distrobuilder/default.nix
+++ b/pkgs/tools/virtualization/distrobuilder/default.nix
@@ -69,5 +69,6 @@ buildGoModule rec {
     license = licenses.asl20;
     maintainers = with maintainers; [ megheaiulian ];
     platforms = platforms.linux;
+    mainProgram = "distrobuilder";
   };
 }
diff --git a/pkgs/tools/virtualization/extra-container/default.nix b/pkgs/tools/virtualization/extra-container/default.nix
index 894622d74eb0c..71ba276f4bd42 100644
--- a/pkgs/tools/virtualization/extra-container/default.nix
+++ b/pkgs/tools/virtualization/extra-container/default.nix
@@ -35,5 +35,6 @@ stdenv.mkDerivation rec {
     license = licenses.mit;
     platforms = platforms.linux;
     maintainers = [ maintainers.erikarvstedt ];
+    mainProgram = "extra-container";
   };
 }
diff --git a/pkgs/tools/virtualization/govc/default.nix b/pkgs/tools/virtualization/govc/default.nix
index a2c37dfb679eb..18d5a83a591d4 100644
--- a/pkgs/tools/virtualization/govc/default.nix
+++ b/pkgs/tools/virtualization/govc/default.nix
@@ -26,5 +26,6 @@ buildGoModule rec {
     homepage = "https://github.com/vmware/govmomi/tree/master/govc";
     license = lib.licenses.asl20;
     maintainers = with lib.maintainers; [ nicknovitski ];
+    mainProgram = "govc";
   };
 }
diff --git a/pkgs/tools/virtualization/jumppad/default.nix b/pkgs/tools/virtualization/jumppad/default.nix
index 174fe292f4592..c10b6887aeecc 100644
--- a/pkgs/tools/virtualization/jumppad/default.nix
+++ b/pkgs/tools/virtualization/jumppad/default.nix
@@ -25,5 +25,6 @@ buildGoModule rec {
     homepage = "https://jumppad.dev";
     license = licenses.mpl20;
     maintainers = with maintainers; [ cpcloud ];
+    mainProgram = "jumppad";
   };
 }
diff --git a/pkgs/tools/virtualization/kubevirt/default.nix b/pkgs/tools/virtualization/kubevirt/default.nix
index a9e49cc75c347..67027dc4bd284 100644
--- a/pkgs/tools/virtualization/kubevirt/default.nix
+++ b/pkgs/tools/virtualization/kubevirt/default.nix
@@ -49,5 +49,6 @@ buildGoModule rec {
     homepage = "https://kubevirt.io/";
     license = licenses.asl20;
     maintainers = with maintainers; [ haslersn ];
+    mainProgram = "virtctl";
   };
 }
diff --git a/pkgs/tools/virtualization/lxd-image-server/default.nix b/pkgs/tools/virtualization/lxd-image-server/default.nix
index aeb6ac336932c..43f46a8a72fcd 100644
--- a/pkgs/tools/virtualization/lxd-image-server/default.nix
+++ b/pkgs/tools/virtualization/lxd-image-server/default.nix
@@ -46,5 +46,6 @@ python3.pkgs.buildPythonApplication rec {
     license = licenses.asl20;
     platforms = platforms.unix;
     maintainers = with maintainers; [ mkg20001 ];
+    mainProgram = "lxd-image-server";
   };
 }
diff --git a/pkgs/tools/virtualization/marathonctl/default.nix b/pkgs/tools/virtualization/marathonctl/default.nix
index e8f27e00d851c..85576b4f66402 100644
--- a/pkgs/tools/virtualization/marathonctl/default.nix
+++ b/pkgs/tools/virtualization/marathonctl/default.nix
@@ -20,5 +20,6 @@ buildGoModule rec {
     description = "CLI tool for Marathon";
     license = licenses.mit;
     maintainers = with maintainers; [ manveru ];
+    mainProgram = "marathonctl";
   };
 }
diff --git a/pkgs/tools/virtualization/mininet/default.nix b/pkgs/tools/virtualization/mininet/default.nix
index ccc79d36c8f62..7372d51a62fa3 100644
--- a/pkgs/tools/virtualization/mininet/default.nix
+++ b/pkgs/tools/virtualization/mininet/default.nix
@@ -47,5 +47,6 @@ stdenv.mkDerivation rec {
     platforms = platforms.linux;
     homepage = "https://github.com/mininet/mininet";
     maintainers = with maintainers; [ teto ];
+    mainProgram = "mnexec";
   };
 }
diff --git a/pkgs/tools/virtualization/nixos-shell/default.nix b/pkgs/tools/virtualization/nixos-shell/default.nix
index 59225a5162e38..6f7340835523f 100644
--- a/pkgs/tools/virtualization/nixos-shell/default.nix
+++ b/pkgs/tools/virtualization/nixos-shell/default.nix
@@ -26,5 +26,6 @@ stdenv.mkDerivation rec {
     license = licenses.mit;
     maintainers = with maintainers; [ mic92 ];
     platforms = platforms.unix;
+    mainProgram = "nixos-shell";
   };
 }
diff --git a/pkgs/tools/virtualization/onmetal-image/default.nix b/pkgs/tools/virtualization/onmetal-image/default.nix
index 7e324fc03cc35..2b535dfb6d938 100644
--- a/pkgs/tools/virtualization/onmetal-image/default.nix
+++ b/pkgs/tools/virtualization/onmetal-image/default.nix
@@ -35,5 +35,6 @@ buildGoModule rec {
     homepage = "https://github.com/onmetal/onmetal-image";
     license = licenses.asl20;
     maintainers = with maintainers; [ ];
+    mainProgram = "onmetal-image";
   };
 }
diff --git a/pkgs/tools/virtualization/ovftool/default.nix b/pkgs/tools/virtualization/ovftool/default.nix
index 5cc8fb01b41b3..9bdf4429ff165 100644
--- a/pkgs/tools/virtualization/ovftool/default.nix
+++ b/pkgs/tools/virtualization/ovftool/default.nix
@@ -145,5 +145,6 @@ stdenv.mkDerivation rec {
     license = licenses.unfree;
     maintainers = with maintainers; [ numinit wolfangaukang ];
     platforms = builtins.attrNames ovftoolSystems;
+    mainProgram = "ovftool";
   };
 }
diff --git a/pkgs/tools/virtualization/reg/default.nix b/pkgs/tools/virtualization/reg/default.nix
index 84aecc3ff671d..545b208035b3c 100644
--- a/pkgs/tools/virtualization/reg/default.nix
+++ b/pkgs/tools/virtualization/reg/default.nix
@@ -37,5 +37,6 @@ buildGoModule rec {
     homepage = "https://github.com/genuinetools/reg";
     license = licenses.mit;
     maintainers = with maintainers; [ ereslibre ];
+    mainProgram = "reg";
   };
 }
diff --git a/pkgs/tools/virtualization/supermin/default.nix b/pkgs/tools/virtualization/supermin/default.nix
index b970b66a8f64b..b7600f6bb898f 100644
--- a/pkgs/tools/virtualization/supermin/default.nix
+++ b/pkgs/tools/virtualization/supermin/default.nix
@@ -26,5 +26,6 @@ stdenv.mkDerivation (finalAttrs: {
     maintainers = with maintainers; [ qyliss ];
     license = licenses.gpl2Plus;
     platforms = platforms.linux;
+    mainProgram = "supermin";
   };
 })
diff --git a/pkgs/tools/virtualization/udocker/default.nix b/pkgs/tools/virtualization/udocker/default.nix
index 4fbccf813f2f3..e13376211a895 100644
--- a/pkgs/tools/virtualization/udocker/default.nix
+++ b/pkgs/tools/virtualization/udocker/default.nix
@@ -53,6 +53,7 @@ python3Packages.buildPythonApplication rec {
     license = licenses.asl20;
     maintainers = [ maintainers.bzizou ];
     platforms = platforms.linux;
+    mainProgram = "udocker";
   };
 
 }
diff --git a/pkgs/tools/virtualization/uefi-run/default.nix b/pkgs/tools/virtualization/uefi-run/default.nix
index 9486995538ce5..9d954d9ed03d8 100644
--- a/pkgs/tools/virtualization/uefi-run/default.nix
+++ b/pkgs/tools/virtualization/uefi-run/default.nix
@@ -21,5 +21,6 @@ rustPlatform.buildRustPackage rec {
     homepage = "https://github.com/Richard-W/uefi-run";
     license = licenses.mit;
     maintainers = with maintainers; [ ];
+    mainProgram = "uefi-run";
   };
 }
diff --git a/pkgs/tools/virtualization/vpsfree-client/default.nix b/pkgs/tools/virtualization/vpsfree-client/default.nix
index 749f6820320bf..cffdc267e53c1 100644
--- a/pkgs/tools/virtualization/vpsfree-client/default.nix
+++ b/pkgs/tools/virtualization/vpsfree-client/default.nix
@@ -13,5 +13,6 @@ bundlerApp {
     maintainers = with maintainers; [ aither64 zimbatm ];
     license = licenses.gpl3;
     platforms = platforms.unix;
+    mainProgram = "vpsfreectl";
   };
 }
diff --git a/pkgs/tools/virtualization/xva-img/default.nix b/pkgs/tools/virtualization/xva-img/default.nix
index e4f75c8ad3ca4..bb5c9d5a59929 100644
--- a/pkgs/tools/virtualization/xva-img/default.nix
+++ b/pkgs/tools/virtualization/xva-img/default.nix
@@ -20,5 +20,6 @@ stdenv.mkDerivation rec {
     description = "Tool for converting Xen images to raw and back";
     license = lib.licenses.gpl2;
     platforms = lib.platforms.unix;
+    mainProgram = "xva-img";
   };
 }