An optional feature that suggests you install Python is okay;
core-dumping is not.
The note on tests was about fish development tests, not the `test`
builtin for conditional syntax.
Specifically mention git, hg, and svn in the VCS section.
getopt doesn't work very well in the BSDs, and getent has plenty of
fallbacks to replace it when it's not available.
<https://github.com/terrycloth/fish-shell/commit/
47a768ceeaef1d702624802d83338edbcc0f377c#commitcomment-23613921>
Newer versions of GCC and Clang are not satisfied by a cast to void,
this fix is adapted from glibc's solution.
New wrapper function ignore_result should be used when a function with
explicit _unused_attribute_ wrapper is called whose result will not be
handled.
This reverts commit ee15f1b987.
The test relies on undefined behaviour (checking for errno in the
absence of an error condition) and was broken on OpenBSD.
Closes#4184.
Make the `env_var_t::missing_var()` object a singleton rather than a
dynamically constructed object. This requires some discipline in its use
since C++ doesn't directly support immutable objects. But it is slightly
more efficient and helps identify code that incorrectly mutates `env_var_t`
objects that should not be modified.
It's bugged me forever that the scope is the second arg to `env_get()`
but not `env_set()`. And since I'll be introducing some helper functions
that wrap `env_set()` now is a good time to change the order of its
arguments.
Specifically closes#4313.
Not being as agressive in what we ignore/blacklist, but can be revisited
easily in the future to add more characters to the argument blacklist.
By far the most common problem with universal variables being overridden
by global variables is other values being imported from the environment;
the `set -q; or set -gx` is much more of an edge case.
My previous change to eliminate `class var_entry_t` caused me to notice
that `env_get()` turned a set but empty var into a missing var. Which
is wrong. Fixing that brought to light several other pieces of code that
were wrong as a consequence of the aforementioned bug.
Another step to fixing issue #4200.
* Fix clearing abandoned line with VTE
With VTE-based terminals, resizing currently causes multi-line prompts
to go weird.
This changes the sequence we use to clear the line to one suggested by
a VTE
developer (https://bugzilla.gnome.org/show_bug.cgi?id=763390#c4).
It changes nothing in konsole 17.04.3 and urxvt 9.22, but they already
work.
Note that this does not fix the case where output did not end in a
newline, but that doesn't seem to be up to us. Also, it only affects
those lines.
Fixes#2320.
* Use terminfo definition instead of hardcoding
Thanks to @ixjlyons.
These completions never actually worked and always fell back to the
builtin path completion. But a recent fix means that these now keep the
fallback from happening resulting in no completions for these commands.
Doing `set -U var` when a global named `var` exists can result in
confusing behavior. Try to limit the confusion by improving the warning
we write. Also, only write the warning if interactive.
Fixes#4267