Age | Commit message (Collapse) | Author |
|
Afaik fish shell completions don't need a shebang
(plus the script is not executable anyway)
|
|
"__fish_pass_print" enumerates all files in the password store and
uses sed to strip their common prefix - the password store directory.
If $PASSWORD_STORE_DIR had a trailing slash, sed would fail to remove
the prefix. Fix this by canonicalizing $PASSWORD_STORE_DIR.
|
|
This makes fish complete commands starting with "pass git" as if they were
starting with "git".
|
|
fish only loads pass.fish once, so there is no point to erasing them.
|
|
Unfortunately, a command "set x" without explicit scope overwrites the variable
"x" in the innermost scope it is defined in, if any. This can cause problems
if the user defines the variable "x" as global or universal variable (which is
visible in all fishes). Make sure to define a local variable so we use that.
|
|
There is no point to checking the command name, fish already does that.
Additionally fish knows about commands that "wrap" pass; those commands
should inherit pass's completions.
This commit enables fish>=3.1.0 to provide proper completions for this function:
alias p="PASSWORD_STORE_DIR=$HOME/.my-passwords pass"
or, equivalently,
function p --wraps "PASSWORD_STORE_DIR=$HOME/.my-passwords pass"
PASSWORD_STORE_DIR=$HOME/.my-passwords pass $argv
end
|
|
The -A/--authoritative flag no longer has an effect since fish 2.5 which
was released in 2017.
|
|
Reproduce by typing "pass <TAB>" in a shell launched like: HOME=`mktemp -d` fish
Fish prints an error on failing globs - except when used in one of the commands
"set", "for" or "count". Also quotes are unnecessary here.
|
|
Fish completion spends most of the time in calls to `sed` in for loops over
entries and directories. This patch removes the repeated calls to `sed`.
Signed-off-by: Mathis Antony <sveitser@gmail.com>
|
|
|
|
|
|
|
|
|
|
Based-on-work-by: Matthieu Weber <mweber@free.fr>
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
|
|
|
|
This relies on a patched version of tree to work, unfortunately.
Hopefully upstream will accept our patch.
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
|
|
|
|
|
|
|
|
|