{ pkgs , scdoc , xclip , stdenvNoCC , ... }: stdenvNoCC.mkDerivation rec { pname = "irs"; version = "0.3"; src = ./src; nativeBuildInputs = with pkgs; [ scdoc ]; buildPhase = '' for page in $(find manpages -type f); do scdoc < $page > $(basename $page .scd) done ''; installPhase = '' mkdir -p $out/{share/man/man1,bin,share/zsh/site-functions} cp bin/* $out/bin/ cp completions/* $out/share/zsh/site-functions/ cp *.1 $out/share/man/man1/ ''; }