lf config
This commit is contained in:
parent
f3685dcbf5
commit
026035fe52
2 changed files with 41 additions and 38 deletions
|
|
@ -1,26 +1,34 @@
|
|||
{pkgs, ...}: let
|
||||
readScript = path: '' ''${{
|
||||
${builtins.readFile path}
|
||||
}}'';
|
||||
readScript = path: ''
|
||||
''${{
|
||||
${builtins.readFile path}
|
||||
}}'';
|
||||
in {
|
||||
home.packages = with pkgs; [
|
||||
# previewer
|
||||
|
||||
## get file type
|
||||
file
|
||||
|
||||
## convert to sixels
|
||||
chafa
|
||||
|
||||
## get file info
|
||||
exiftool
|
||||
|
||||
## pretty print text files
|
||||
bat
|
||||
|
||||
## format json
|
||||
jq
|
||||
|
||||
## get thumbnails from videos
|
||||
ffmpegthumbnailer
|
||||
|
||||
# commands
|
||||
|
||||
## trash utility
|
||||
trash-cli
|
||||
imagemagick
|
||||
gnumeric
|
||||
poppler_utils
|
||||
odt2txt
|
||||
python311Packages.docx2txt
|
||||
catdoc
|
||||
libcdio
|
||||
p7zip
|
||||
file
|
||||
gnome-epub-thumbnailer
|
||||
];
|
||||
|
||||
programs.lf.enable = true;
|
||||
|
|
@ -37,12 +45,13 @@ in {
|
|||
drag = "%${pkgs.ripdrag}/bin/ripdrag -x \"$fx\"";
|
||||
trash = "%trash-put \"$fx\"";
|
||||
open = "$set -f; ${pkgs.ranger}/bin/rifle -p 0 \"$fx\"";
|
||||
open-with = '' ''${{
|
||||
set -f
|
||||
${pkgs.ranger}/bin/rifle -l "$fx"
|
||||
read -p "Open with: " method
|
||||
${pkgs.ranger}/bin/rifle -p "$method" "$fx"
|
||||
}}'';
|
||||
open-with = ''
|
||||
''${{
|
||||
set -f
|
||||
${pkgs.ranger}/bin/rifle -l "$fx"
|
||||
read -p "Open with: " method
|
||||
${pkgs.ranger}/bin/rifle -p "$method" "$fx"
|
||||
}}'';
|
||||
bulk-rename = readScript ./bulk-rename.sh;
|
||||
};
|
||||
programs.lf.previewer.source = ./preview.sh;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue