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.
If the theme says "brgreen", that's what we want the variable to say
after.
This used to translate it through our palette, so it ended up as
00ff00, which isn't the same.
This still keeps the idea that colors that aren't in the palette are
better, and it does it in a slightly roundabout way (translate color
string to rgb string, see if the rgb string is a key in that
translation dictionary), but it should work for now.
* add --bold, --italics, all of them,
* and we add them as arguments so that they are do not
render like long options, they are just self-descriptive
literal strings in this context.
* solve an unneccessary global var.
Fixes#8518
Theoretically if this only includes simple characters, it won't cause
any issues. We already validate in other places but it doesn't hurt to
do this twice.
Now that we have modifiers and can have backgrounds and such, simply
setting it as css style doesn't cut it.
So let's stop validating for now, the worst that can happen is that
the color isn't rendered.
This just simply passed the "color" value, which is just the
foreground color string.
Instead, we pass the actual object back, with the modifiers as bools
and foreground/background separate.
Our themes don't use background a lot, except in the pager, so this
never really came up.