I hope this is now complete.
Also, shorten enough descriptions to make `string match --<TAB>`
show a two column pager with 80 cols.
We really should have shown more retraint in the design of `string`,
not all of the flags required both a long and short option created.
A person stuck installing it just for fish on their server
doesn't want to waste time installing the wrong one, so assuage that.
Also tweak to look nicer with 80 columns
As discussed in #5492, it would be good if running fish_config without
Python actually told the user to install Python.
Further, let's give the person some hints on how to configure these
things by hand, since they may have to.
Don't do it when the relative path is simple (purely descending),
unless the token starts with ":/".
Also stop offering directories - if they need to be disambiguated, the
normal completion logic will take care of that.
Fixes#5574.
[ci skip]
Previously, using special regex characters or slashes would result in an
error message, when pressing tab in a command-line such as
"man /usr/bin/time ".
This broke when --preset was introduced.
We allow a "--preset" or "--user" to appear right after the "bind",
and save the value, but don't use it yet.
Fixes#5534.
[ci skip]
We can't complete these, and now the user can do
```
set -g __fish_git_alias_$alias $command
```
e.g.
```
set -g __fish_git_alias_co checkout
```
if the arguments in the alias end up going to `git alias`.
Fixes#5412.
[ci skip]
This was an oversight from the previous commit. Not that it matters
much, because we already removed $files.
Still, this would fail if someone defined a global $files, so let's fix it.
[ci skip]
Our weird %-expanding function wrappers around kill et all defined
"--wraps" for the same name.
As it turns out, fish follows that one, and executes the completion
multiple times.
I didn't notice because these tend to be rather quick on linux, but on
macOS that's apparently a real issue.
Fixes#5541.
[ci skip]
This enables fuzzy-matching outside of the current directory again.
As it turns out, the performance impact here isn't as large as I
thought - it's massively dependent on caching.
Fixes#5476.
(cherry picked from commit 73bae383e0)
Instead of maybe adding "-s" and "-M" if "-s" hasn't already been
given, just add "-s" to _every_ bind invocation, and "-M" to those who
need it.
Fixes#5028.
Largely reverts 007d794b6e.
fish_indent is extremely resource-intensive on large inputs and can crash; it also does not handle
invalid characters gracefully.
Work on #5402.
The solarized themes now define pager colors, while other schemes
don't.
So if a user picks one of them, and then another, they'd keep the
pager colors.
Instead, since the default theme is now complete, any theme that does
not define its own pager colors will always get the default ones.
[ci skip]
This was missing a bunch of variables from __fish_config_interactive.
Ideally we wouldn't have to duplicate this info, but I don't have a
great solution either.
This removes ~140ms from every single prompt.
When not in a git repo, this prompt now takes ~9ms, as opposed to
~150ms before.
Fixes#5266 harder.
[ci skip]
This is quite ugly, but in lieu of putting in a proper ansi
parser (i.e. the output part of a terminal), since this is the only
such sequence we have seen until now, let's just match it.
Fixes#5312.
[ci skip]
- Remove use of `eval`
- Use `git rev-parse` instead of `git status` as its faster,
- especially in large repos. (in qt5: 600ms vs 1ms)
- Use return status instead of test -n
This should change nothing about the output.
This uses some more string, but the main improvement is using "git
rev-list" instead of parsing "git branch" output that happens to be localized.
[ci skip]
I can't see the value in this, given that we have a bunch of minimalist ones.
The "escaping" here is gnarly enough that I don't want to attempt to clean it up.
man.fish can be clarified a bit, by removing a superfluous early return. Additionally, performance can be
(ever so slightly) improved, by using the empty string to suffix an extra colon when `$MANPATH` is empty, as
described in `manpath(1)`. As `man` will internally call `manpath` as it starts, this eliminates a redundancy.