Few more scripts
This commit is contained in:
parent
13eedd1a1c
commit
e17b945863
10 changed files with 305 additions and 0 deletions
17
default.nix
17
default.nix
|
@ -1,7 +1,10 @@
|
|||
{ pkgs
|
||||
, scdoc
|
||||
, xclip
|
||||
, maim
|
||||
, stdenvNoCC
|
||||
, nushell
|
||||
, xdotool
|
||||
, ...
|
||||
}:
|
||||
stdenvNoCC.mkDerivation rec {
|
||||
|
@ -10,6 +13,7 @@ stdenvNoCC.mkDerivation rec {
|
|||
src = ./src;
|
||||
nativeBuildInputs = with pkgs; [
|
||||
scdoc
|
||||
nushell
|
||||
];
|
||||
|
||||
buildPhase = ''
|
||||
|
@ -18,11 +22,24 @@ stdenvNoCC.mkDerivation rec {
|
|||
done
|
||||
'';
|
||||
|
||||
preConfig = ''
|
||||
patchShebangs ./bin/*
|
||||
'';
|
||||
|
||||
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/
|
||||
|
||||
runHook postInstall
|
||||
'';
|
||||
|
||||
postInstall = ''
|
||||
substituteInPlace $out/bin/* \
|
||||
--replace "xclip" "${xclip}/bin/xclip" \
|
||||
--replace "maim" "${maim}/bin/maim" \
|
||||
--replace "xdotool" "${xdotool}/bin/xdotool"
|
||||
'';
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue