feat(fish): Abbr to execute a .txt file

This commit is contained in:
punkfairie 2024-04-15 09:49:03 -07:00
parent 91cc7ea6e1
commit 1a21be56c0
No known key found for this signature in database
GPG key ID: 284B78B49C058673

View file

@ -25,6 +25,15 @@ end
abbr -a _cd_up --position command --regex "\.{2,}" --function _cd_up_func
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# Execute .txt files as a command.
function _edit_txt_func --argument-names file
echo "$EDITOR $file"
end
abbr -a _edit_txt --position command --regex ".+\.txt" --function _edit_txt_func
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# Default command options.