Created
September 20, 2023 10:49
-
-
Save rochacbruno/415a4e39e120c2dee660d4fab55437de to your computer and use it in GitHub Desktop.
Helix file picker
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### requires the script lf-pick on path | |
### Requires lf installed https://github.com/gokcehan/lf | |
### lf has the keybindings: <space> select file, lowercase `l` accept selection | |
### or use arrow right to open the file | |
### This allows selecting multiple files with space and then hit `l` to open | |
# touch ~/.local/bin/lf-pick | |
# chmod +x ~/.local/bin/lf-pick | |
# function lfp(){ | |
# local TEMP=$(mktemp) | |
# lf -selection-path=$TEMP | |
# cat $TEMP | |
# } | |
# lfp | |
e = [ | |
":new", | |
":insert-output lf-pick", | |
"select_all", | |
"split_selection_on_newline", | |
"goto_file", | |
"goto_last_modified_file", | |
":buffer-close!", | |
":redraw", | |
] | |
### File Picker |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment