first
This commit is contained in:
42
pkgs/zellij-ps/default.nix
Normal file
42
pkgs/zellij-ps/default.nix
Normal file
@@ -0,0 +1,42 @@
|
||||
{
|
||||
lib,
|
||||
stdenv,
|
||||
fetchFromGitea,
|
||||
fish,
|
||||
fd,
|
||||
fzf,
|
||||
zellij,
|
||||
}:
|
||||
with lib;
|
||||
stdenv.mkDerivation {
|
||||
pname = "zellij-ps";
|
||||
version = "0.1.0";
|
||||
|
||||
src = fetchFromGitea {
|
||||
domain = "code.m3ta.dev";
|
||||
owner = "m3tam3re";
|
||||
repo = "helper-scripts";
|
||||
rev = "08a3217b83391c1110545c1ee3161eecd5dbe5e9";
|
||||
sha256 = "1sc4i58mwcg3qsq0wwl5rvk08ykbxc497bq7mrxiirndsarskby7";
|
||||
};
|
||||
|
||||
propagatedBuildInputs = [fish fd fzf zellij];
|
||||
|
||||
nativeBuildInputs = [];
|
||||
installPhase = ''
|
||||
mkdir -p $out/bin
|
||||
substitute zellij-ps.fish $out/bin/zellij-ps \
|
||||
--replace-fail 'fd --type' '${fd}/bin/fd --type' \
|
||||
--replace-fail 'fzf --preview' '${fzf}/bin/fzf --preview' \
|
||||
--replace-fail 'zellij --layout' '${zellij}/bin/zellij --layout' \
|
||||
--replace-fail 'pgrep -c zellij' 'pgrep -c ${zellij}/bin/zellij'
|
||||
chmod +x $out/bin/zellij-ps
|
||||
'';
|
||||
|
||||
meta = {
|
||||
description = "A small project script for zellij";
|
||||
license = lib.licenses.mit;
|
||||
platforms = platforms.unix;
|
||||
mainProgram = "zelli-ps";
|
||||
};
|
||||
}
|
Reference in New Issue
Block a user