ncurses since 6.0 sends the "E3" sequence along with "clear", even for
just `clear` or `tput clear`. This deletes the scrollback buffer which
is usually not what you want.
Fixes#2855.
Some things like pyenv can change what `python` refers to, so what we
detect when we load the completions can become invalid later.
Also mentioned in #3840.
The issue here was that the `python` completion did a version check on
the `python` binary, so it would complete python2 stuff if system
python was py2, even if the user tried to complete `python3`.
This isn't beautiful, but it's more resilient than e.g. doing magic
with `commandline`.
Fixes#3840.
Before this change the function `__fish_print_filesystems` would print
an error message about an empty wildcard match for the pattern
`$PATH/mount.*`, if the current operating system does not include any
helper binaries for the command `mount`. An example for such an OS is
the current version of macOS (version 10.12).
Change the escape key binding in insert mode (in vi key bindings)
to check if we are in paging mode. If so, emit cancel and stay in
insert mode. Otherwise perform the current behavior of switching
back to default mode and adjusting the cursor.
Fixes#2871
* Add completions for minikube
This adds basic completions for minikube, the subcommands and their options.
* Improve minikube completions
- Use more consistent and shorter descriptions.
- Fix subcommand options
- Add more semantic completions
* Fix named variable for option value
* Add completions for minikube addons enable/disable
* Add completions for minikube addons open
This commit addresses many of the style problems with the previous
commit. If this introduces any bugs they are solely my fault. The style
of this code needs more improvement. Some of which could be done today.
Others will have to wait until `fish_indent` is improved.
Add IPV6 /etc/hosts completion support. Parses columns rather than values which produces improved output.
Support ssh -F and Include completion
Ignore ssh Hostname and Host with wildcard. The following only get in the way:
- Hostname: Host resolves to Hostname
- Wildcard Host: Cannot ssh to a glob pattern
Improve scp completions
* complete only local files when no host provided
* complete only remote files when host is provided
* complete local files or hosts when no separator
Disable username completion for ssh/scp
Username completion only provides local users which will unlikely be
useful on a remote machine. ssh will use the current username (the only
useful one) or one provided in the ssh config.
Haiku only has `man --path`.
Still doesn't support OpenBSD.
Use $MANPATH if available. This needs to:
- Ignore stderr (we pipe it and throw it away)
- Read the subprocess returncode, since `man --path` is an existing
command that fails instead of a non-existent one (that raises an
exception)
- Properly set up the fallback
Fixes#2194.
* Improve bzr completion. Closes#3661
* Add basic completion for bzr commands
* Include short and log options for common commands
* Removed not so common commands
* Remove trailing '.' as requested by #3769
* Remove '=' as suggested by #3769
* We don't need '=' in long options
* Use fish helper functions for autocomplete
To avoid issues pointed out in #3769 helper functions included in fish
are used (__fish_use_subcommand and __fish_seen_subcommand).
* Fixed typo
* Added new function for the default prompt mode
Now fish mode prompt will call fish_default_mode_prompt, this will solve #3641
* Added function description
* Change wording for documentation about default mode prompt
* Finish changes requested in code review
This would fail on very long numbers, e.g.
`math "1 + 1233242342353453463458972349873489273984873289472914712894791824712941"`
would now return "42", where it previously returned the correct "1233242342353453463458972349873489273984873289472914712894791824712942".
This reverts commit 26e781ef5a.
It's not the case that macOS and old BC doesn't respect this environment
variable, just that they don't have special behavior when it's set to 0.
However, there is rather universal favorable behavior with a value of 2.
Output is of the form:
\
999999999999999999999999999999999...
with the second line being arbitrarily long. So just grab that line
instead of stitching with `string`.
This can yield a 25-30% speedup.
This commit adds a feature that after typing "git add" and pressing
"alt+h", the manpage for "git-add" instead of "git" would be displayed.
The new logic takes the first argument which doesn't start with a dash
and tries to display manpage for "command-argument"; it falls back to
"man command" it the first try doesn't succeed.
Fixes#3618.
* Only append paths if `MANPATH` is already set, to match behavior of macOS
`path_helper` utility.
* Use the same technique as is used above to set PATH from /etc/paths and
/etc/paths.d/*.
- Support completing dynamic make targets.
- Support completing make targets when using -C/--directory.
- Support `-Cdir/path`, `-C dir/path`
- Support `--directory=dir/path`, `--directory dir/path`
This detects if the make command have the `-p` switch otherwise it
assumes it is BSD make and will run a different command to try to figure
out the available targets.
Commits 48aa92900 and 77d4d21ca each added two files with the same name
differing only in letter case. That causes problems on systems like
macOS and MS Windows. Remove the lowercase file names. Anyone needing
those completions can do (same for VBoxHeadless):
function vboxsdl --wraps VBoxSDL
VBoxSDL $argv
end
The previous implementation didn't take into account that a lexer could
have multiple names and gave `cpp, c++` instead of `cpp` and `c++` when
completing `pygmentize -l c`.
--authoritative and --unauthoritative 'complete' builtin switches have no effect anymore.
This commit removes usage of --unautoritative/-u in completions.
--authoritative and --unauthoritative 'complete' builtin switches have no effect anymore.
This commit removes usage of --autoritative/-A in completions.
The recent refactoring to separate default (emacs) from vi key bindings
overlooked adding `\cH` bindings to vi mode. This also fixes the
behavior of the [del] key bindings (\x7F).
Fixes#3653