Commit Graph

3270 Commits

Author SHA1 Message Date
239
3cd662e9ae Add completions for fd 2020-03-21 16:45:31 +01:00
239
69c8496cb8 Update completion for cryptsetup 2020-03-21 16:44:04 +01:00
Fabian Homborg
8ddd512fba Refine when we expand abbreviations
- ctrl-space will insert a space without expanding abbrs
- ")" or alt-enter will expand abbrs

Fixes #6658
2020-03-21 13:55:15 +01:00
Jon Cinque
23a21eb318 Add vi 'y' bindings and some i / a support
Many people have mentioned wanting support for changing / yanking /
deleting between "" and '', meaning the commands `ci' ci" yi' yi" di' di"`,
so this adds that support in a generic, and thus potentially confusing way.
The concept is that we check for the character backwards and forwards
before making the selection.  Unfortunately, this will also work for *any*
character that isn't `w` or `W`, so `cia` could change everything between
two `a` characters.
Looking through the [bind documentation](https://fishshell.com/docs/current/cmds/bind.html)
and input handler at `src/input.cpp`,
this is the best possible solution I could come up with until
`forward-jump` and `backward-jump` can accept input in the call to `bind`,
and not just from stdin, meaning we can write a binding as:
```
bind di\" backward-jump-till \" and repeat-jump-reverse ...`
```
If that were done, then other commands such as `di)` to go between `()` would
be possible.
There are also some added `y` bindings not part of #6648.
Let me know if you need anything else.
2020-03-21 13:52:12 +01:00
Jason Nader
c4156677cc Remove unnecessary use of begin 2020-03-21 13:26:58 +01:00
Jason Nader
eba099bf77 Fix abook completions 2020-03-21 13:22:32 +01:00
Delapouite
6b73079e27 feat: add missing 'save' completion for funced 2020-03-19 21:55:40 +01:00
Jason Nader
0d43615af2 Update completions for read builtin 2020-03-19 18:23:17 +01:00
Sam Yu
bbb4a63d67 Fix zypper completion
Fix packages completion for `zypper download`
2020-03-16 19:09:16 +01:00
Fabian Homborg
1e2e511570 fish_default_key_bindings: Remove outdated stderr silencing
We *always* silence `bind` here, so we don't need to specifically
silence for these keys.
2020-03-15 21:01:11 +01:00
Fabian Homborg
aa629c5aca Reformat fish scripts with escaped newline changes to fish_indent 2020-03-15 21:01:11 +01:00
Fabian Homborg
463b9b99c6 Move ctrl-left/right forward-word to shared bindings
These also work in vim.

Fixes #6755.
2020-03-15 13:24:45 +01:00
Jason Nader
266ce7c940 Improve Arch Linux package completions
Add completions for `downgrade` tool
Add new `--installed` option for printing Arch packages
Change Arch Linux package related completions to use `--installed`

add newline
2020-03-15 13:19:25 +01:00
Jason Nader
0f681190ba Fix screen optarg completions as they require a space 2020-03-15 10:21:33 +01:00
Johannes Altmanninger
f665cd6367 completions/kak.fish: use old style instead of short options
Kakoune does not accept grouped short options, or option
arguments without a separating space.
2020-03-15 08:50:21 +01:00
Tim Sampson
5cf24b7733 completions: add basic completions for 'ip netns' 2020-03-14 15:47:25 +01:00
Johannes Altmanninger
651f3cf863 Fix VSCode not blocking in edit_command_buffer 2020-03-14 14:15:10 +01:00
Delapouite
a7f62df958 feat: add missing 'current-selection' completion for commandline
Related to #4255
2020-03-14 12:50:40 +01:00
exploide
a2a12ffda2 removed wrong escaping in completion descriptions 2020-03-14 12:07:58 +01:00
Fabian Homborg
db7dfddc3b completions/systemctl: Remove annoying marker
The output of

systemctl list-units

seems to include a marker of '●' or '*' for some units, even if the
output is not going to a terminal and "--no-legend" and "--no-pager"
are given. This appears
to be a recent development, and there does not appear to be a flag to
disable it.

So we simply filter it out in the completions to once again hopefully
offer the actual units.

Fixes #6740
2020-03-12 18:37:32 +01:00
Fabian Homborg
5ab1e2dc0f help: Always use xdg-open if available
Even if $DISPLAY is unset, xdg-open can be useful, and on systems that
have xdg-open, "open" is most likely some god awful outdated thing
called "openvt" elsewhere.

Fixes #6739

[ci skip]
2020-03-12 17:27:37 +01:00
Johannes Altmanninger
c5e4419097 Add "--" safeguards at string length [ci skip] 2020-03-10 21:01:00 +01:00
Johannes Altmanninger
208b0f9dd5 Interactive config: remove useless argument and correct redirection 2020-03-10 20:56:45 +01:00
Johannes Altmanninger
685b668958 Complete IDs for unix users and groups that start with _ 2020-03-10 20:56:45 +01:00
Fabian Homborg
0af6d36bb8
Merge pull request #6731 from ammgws/complete-gvim
update gvim completions
2020-03-10 18:24:26 +01:00
Jason Nader
7fb3880b96 completions: remove unnecessary use of --erase 2020-03-10 18:10:49 +01:00
Jason Nader
faa75d74d2
Update gvim completions 2020-03-10 23:52:00 +09:00
Fabian Homborg
9367d4ff71 Reindent functions to remove useless quotes
This does not include checks/function.fish because that currently
includes a "; end" in a message that indent would remove, breaking the test.
2020-03-09 19:46:43 +01:00
Fabian Homborg
750e6fa663 completions/openocd: Stop using "which"
"which" is useless.
2020-03-09 19:46:43 +01:00
rnhmjoj
81668b3f86 completions: fix scp remote path when /bin/ls does not exist 2020-03-09 19:21:43 +01:00
exploide
eac6252ab9 improved find completions 2020-03-08 17:24:14 +01:00
exploide
f39cba1d9f added functions to complete user and group IDs 2020-03-08 17:24:14 +01:00
Johannes Altmanninger
660182cfb3 completions/zfs: finish renaming from 05038fc8 2020-03-08 10:00:57 +01:00
Johannes Altmanninger
01d9e56bdd completions/zfs: fix syntax error from f507f4ad 2020-03-08 10:00:57 +01:00
ridiculousfish
29c2bce704 Use self-insert-notfirst on spaces during paste
This changes a5a643f854 to use the new self-insert-notfirst binding.
It also adds a test.
2020-03-07 13:31:55 -08:00
Jason Nader
926c1f1016 Privatise completion-only funtions 2020-03-07 13:26:27 -08:00
Johannes Altmanninger
52dfb146d1 Fix vscode completion
[ci skip]
2020-03-07 21:24:14 +01:00
Johannes Altmanninger
87728c4d0d Pass cursor position to edit_command_buffer for some editors
Fixes #6138

Naturally this does not work for many other editors/aliases,
but it's still nice that we can make it work for some common
editors without requiring any configuration.

Of course this approach is not terribly flexible; but it's
alwyas possible to just wrap edit_command_buffer and set an
EDITOR that knows about the cursor position. It doesn't
feel important enough to add a configuration option.
2020-03-07 21:24:14 +01:00
Johannes Altmanninger
27e88adcd5 Re-fix cargo completions
Using a local variable means we have to expand it when loading the
completion.  With this approach, the content of the variable will be
expanded, so escape it.
2020-03-07 19:54:50 +01:00
Fabian Homborg
db62953e0f completions/cargo: Add remaining bits of #6717
A nicer variable scope and no more erasing completions.

[ci skip]
2020-03-07 19:38:23 +01:00
Mahmoud Al-Qudsi
4a3ffe741c Partilaly revert 0b7bbb5654
The changes to the `cargo` completions resulted in screenfuls of junk
being dumped to the tty on `cargo pu<TAB>`.
2020-03-07 08:44:00 -06:00
Johannes Altmanninger
917f759a1a prompt: don't consider SIGPIPE a failure
Reproduce by running git log and press "q".
This regressed in master in 5d135d5.

[ci skip]
2020-03-07 14:13:58 +01:00
Johannes Altmanninger
da7b762f4a Make default hg prompt leaner
The default hg prompt is slow on large repositories (hg status takes
2-3 seconds on mozilla-central) which is unacceptable as a default.

Mimick our git prompt: by default, only show the current branch.
If the new variable $fish_prompt_hg_show_informative_status is set,
then use the old behavior.

[ci skip]
2020-03-07 13:02:58 +01:00
Jason Nader
b4626468ec completion helper functions: do not use gettext
remove package
2020-03-06 22:23:50 +01:00
Jason Nader
12ce66684e completions: add mpv 2020-03-06 22:22:52 +01:00
exploide
61de39bd68 updated grep completion
added group-seperator options to grep completion
distinguished between -r and -R
removed deprecated option
2020-03-04 11:31:05 -08:00
Jason Nader
97d5f68cdf completions: update ftp 2020-03-04 10:26:54 -08:00
Jason Nader
3774edba93 completions: add imv 2020-03-03 18:32:53 +01:00
Jason Nader
4b95f2c5ee completions: add ps2pdf wrapper functions 2020-03-03 18:32:13 +01:00
exploide
e48ef850b9 added completions for tcpdump 2020-03-03 18:31:42 +01:00