Reorganize imports
Signed-off-by: Nikolaos Karaolidis <nick@karaolidis.com>
This commit is contained in:
31
hosts/common/configs/user/gui/cliphist/rofi.nix
Normal file
31
hosts/common/configs/user/gui/cliphist/rofi.nix
Normal file
@@ -0,0 +1,31 @@
|
||||
{
|
||||
rofi ? throw "rofi package is required",
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
let
|
||||
copy = lib.meta.getExe (
|
||||
pkgs.writeShellApplication {
|
||||
name = "copy";
|
||||
runtimeInputs = with pkgs; [
|
||||
cliphist
|
||||
wl-clipboard
|
||||
];
|
||||
text = builtins.readFile ./scripts/copy.sh;
|
||||
}
|
||||
);
|
||||
|
||||
delete = lib.meta.getExe (
|
||||
pkgs.writeShellApplication {
|
||||
name = "delete";
|
||||
runtimeInputs = with pkgs; [ cliphist ];
|
||||
text = builtins.readFile ./scripts/delete.sh;
|
||||
}
|
||||
);
|
||||
in
|
||||
pkgs.writeShellApplication {
|
||||
name = "cliphist-rofi";
|
||||
runtimeInputs = [ rofi ];
|
||||
text = "rofi -modi \"copy:${copy},delete:${delete}\" -show copy";
|
||||
}
|
Reference in New Issue
Block a user