From f2544dc85f4532fe8fabde0dce3a061b3dd336c7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sandro=20J=C3=A4ckel?= Date: Fri, 17 Feb 2023 14:05:18 +0100 Subject: [PATCH] mdcat: add mdless symlink and install completions Closes #215459 --- pkgs/tools/text/mdcat/default.nix | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/pkgs/tools/text/mdcat/default.nix b/pkgs/tools/text/mdcat/default.nix index 47f74684c6f1..e8a7e4ecf5a2 100644 --- a/pkgs/tools/text/mdcat/default.nix +++ b/pkgs/tools/text/mdcat/default.nix @@ -42,10 +42,14 @@ rustPlatform.buildRustPackage rec { postInstall = '' installManPage $releaseDir/build/mdcat-*/out/mdcat.1 - installShellCompletion \ - --bash $releaseDir/build/mdcat-*/out/completions/mdcat.bash \ - --fish $releaseDir/build/mdcat-*/out/completions/mdcat.fish \ - --zsh $releaseDir/build/mdcat-*/out/completions/_mdcat + ln -sr $out/bin/{mdcat,mdless} + + for bin in mdcat mdless; do + installShellCompletion \ + --bash $releaseDir/build/mdcat-*/out/completions/$bin.bash \ + --fish $releaseDir/build/mdcat-*/out/completions/$bin.fish \ + --zsh $releaseDir/build/mdcat-*/out/completions/_$bin + done ''; meta = with lib; {