Nix add man (#1148)

* update(nix): add manpage to `man` output

* fmt(nix): nixpkgs-fmt
This commit is contained in:
a-kenji 2022-02-28 13:42:53 +01:00 committed by GitHub
parent 04ce772673
commit 4132b747ca
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -19,7 +19,8 @@
"i686-linux" "i686-linux"
"x86_64-darwin" "x86_64-darwin"
"x86_64-linux" "x86_64-linux"
] (system: ]
(system:
let let
overlays = [ (import rust-overlay) ]; overlays = [ (import rust-overlay) ];
@ -50,6 +51,9 @@
]; ];
nativeBuildInputs = [ nativeBuildInputs = [
# generates manpages
pkgs.mandown
pkgs.installShellFiles pkgs.installShellFiles
pkgs.copyDesktopItems pkgs.copyDesktopItems
@ -61,13 +65,12 @@
pkgs.cargo-make pkgs.cargo-make
pkgs.rust-analyzer pkgs.rust-analyzer
pkgs.nixpkgs-fmt pkgs.nixpkgs-fmt
# generates manpages
pkgs.mandown
# optimizes wasm binaries # optimizes wasm binaries
pkgs.binaryen pkgs.binaryen
]; ];
in rec { in
rec {
packages.zellij = packages.zellij =
(pkgs.makeRustPlatform { inherit cargo rustc; }).buildRustPackage { (pkgs.makeRustPlatform { inherit cargo rustc; }).buildRustPackage {
@ -78,6 +81,8 @@
''; '';
postInstall = '' postInstall = ''
mandown ./docs/MANPAGE.md > ./zellij.1
installManPage ./zellij.1
# explicit behavior # explicit behavior
$out/bin/zellij setup --generate-completion bash > ./completions.bash $out/bin/zellij setup --generate-completion bash > ./completions.bash