From d0e2daac6b87e2977b3782170f138434b22b8a62 Mon Sep 17 00:00:00 2001 From: Christoph Schlosser Date: Tue, 17 Jun 2025 07:23:30 +0000 Subject: Add z plugin --- fish/functions/__z_complete.fish | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 fish/functions/__z_complete.fish (limited to 'fish/functions/__z_complete.fish') diff --git a/fish/functions/__z_complete.fish b/fish/functions/__z_complete.fish new file mode 100644 index 0000000..a626456 --- /dev/null +++ b/fish/functions/__z_complete.fish @@ -0,0 +1,13 @@ +function __z_complete -d "add completions" + complete -c $Z_CMD -a "(__z -l | string replace -r '^\\S*\\s*' '')" -f -k + complete -c $ZO_CMD -a "(__z -l | string replace -r '^\\S*\\s*' '')" -f -k + + complete -c $Z_CMD -s c -l clean -d "Cleans out $Z_DATA" + complete -c $Z_CMD -s e -l echo -d "Prints best match, no cd" + complete -c $Z_CMD -s l -l list -d "List matches, no cd" + complete -c $Z_CMD -s p -l purge -d "Purges $Z_DATA" + complete -c $Z_CMD -s r -l rank -d "Searches by rank, cd" + complete -c $Z_CMD -s t -l recent -d "Searches by recency, cd" + complete -c $Z_CMD -s h -l help -d "Print help" + complete -c $Z_CMD -s x -l delete -d "Removes the current directory from $Z_DATA" +end -- cgit v1.2.3