Remove some nonexistent options (my gcc does not know "-mdata"), fix
the longest description in all of fish and remove some argument
markers from the option.
This sets the variable to the background value of
$fish_color_search_match, which fixes the case where you switch from a
theme with a set selected background (like our default, now) to one without.
It's using GNU specific flags, which doesn't work on BSDs like macOS.
Instead this just formats the current time into
seconds and then the `math` builtin for calculating the 5 min timeout.
Unfortunately the normal font families like "sans-serif" and
"monospace" are basically broken because the browser defaults are
decades old.
TODO: Inline code is barely distinguishable.
GNU tr is not Unicode-aware, and was corrupting descriptions that had
non-ASCII characters.
Additionally, rather than using the Unicode private use characters, use
the ASCII/UTF-8 record separator character as it was intended.
The sed command could probably be rewritten to do all the heavy lifting
here, but would be even less readable.
Closes#8575.
Instead of weirdly smearing the color, simply increase the values
until they are bright enough.
This prevents /tmp from being white, and guarantees visible colors for
all directories.
fish_git_prompt may run certain git commands which may invoke certain
external programs as specified `.git/config`. Prevent this by suppressing
certain git config options.
The `name` attribute I used in commit f725cd402d
is undocumented, and [someone discovered] that it does not exist for one
possible browser on MacOS. This should make the code work correctly even in that case.
This probably doesn't currently cause a problem, at least when
`isMacOS10_12_5_OrLater()` is true, because of the ordering of the if
statements in the `runThing` function.
[someone discovered]: https://bugs.python.org/issue43424#msg409087
Git completions use wrapper function __fish_git instead of directly
running git. This allows them to be aware of Git's global options, like
--git-dir. Let's use __fish_git also for listing config keys & values,
so it can more accurately list local (= per repo) git configuration.
We don't provide completions on "git config " because we require
"fish_is_nth_token 3". Confusingly, fish_is_nth_token only counts
tokens *before* the cursor, so 2 is the right number here.
While at it, fix a typo and delete an unused completion entry (it
ran conditional on __fish_is_first_arg, which is always false for a
git subcommand).
This patch introduces basic completion of the -pl|--projects switch for
mvn. The implementation is quite naive but it's better than nothing. A more
robust implementation would require either scanning the filesystem or running
mvn which might slow down completion significantly.
This solution can be improved by using an XML parser instead of grep/sed.
This is a stop gap. Ideally setting a theme would be idempotent. You
set it, all colors change to match it, even the ones it does not
specify.
However, I do not believe we can *erase* colors that aren't set, and
we don't currently do so in the CLI version. So skip setting these at
all, for now.
If a color is mentioned but empty, it will be set to empty.