We have now entirely switched the script tests to littlecheck.
Note: This adjusts the complete_directories test, because it removes a
directory that was created before by a .in test. There's no real
change in behavior.
This does require the test directory be cleaned, or the tests will fail.
test_util gets to stay for a while longer, because it sets up the
testing env (locale and such).
This, together with the other testX, really just tests some basic
syntax. So let's just call it "basic".
Note that this file uses escaped newlines on purpose, so restyling it
would currently break it. I'm not sure what the best thing to do here is.
Instead of invoking littlecheck.py independently for each file, pass
all files at once. This amortizes the Python startup cost, and reduces
the total test time by ~15 seconds (!).
Commit b2f40783a2b5b0663409c4daa90b794b02dd37a6
This has better progress reporting, and the exit status of littlecheck
indicates how many test failures there were.
This isn't quite the old-style test, but it checks some of the line
continuation stuff.
Note that littlecheck ignores leading whitespace, so testing the
actual indentation requires some more effort.
Things like
```fish
\
echo foo
```
or
```fish
echo foo; \
echo bar
```
are a formatting blunder and should be handled.
This makes it so the escaped newline is removed, and the
semicolon/token_type_end handling will then put the statements on
different lines.
One case this doesn't handle brilliantly is an escaped newline after a
pipe:
```fish
echo foo | \
cat
```
is turned into
```fish
echo foo | cat
```
which here works great, but in long pipelines can cause issues.
Pipes at the end of the line cause fish to continue parsing on the
next line, so this can just be written as
```fish
echo foo |
cat
```
for now.
Add completions for `downgrade` tool
Add new `--installed` option for printing Arch packages
Change Arch Linux package related completions to use `--installed`
add newline
1. When the wall time and cpu time rows has different units
e.x. running multiple cores
2. When duration is around 1E3 or 1E6 microseconds
printf("%6.2F", 999.995) gives 1000.00 which is 7 digits
The output of
systemctl list-units
seems to include a marker of '●' or '*' for some units, even if the
output is not going to a terminal and "--no-legend" and "--no-pager"
are given. This appears
to be a recent development, and there does not appear to be a flag to
disable it.
So we simply filter it out in the completions to once again hopefully
offer the actual units.
Fixes#6740
The output of
systemctl list-units
seems to include a marker of '●' or '*' for some units, even if the
output is not going to a terminal and "--no-legend" and "--no-pager"
are given. This appears
to be a recent development, and there does not appear to be a flag to
disable it.
So we simply filter it out in the completions to once again hopefully
offer the actual units.
Fixes#6740
Even if $DISPLAY is unset, xdg-open can be useful, and on systems that
have xdg-open, "open" is most likely some god awful outdated thing
called "openvt" elsewhere.
Fixes#6739
[ci skip]
Even if $DISPLAY is unset, xdg-open can be useful, and on systems that
have xdg-open, "open" is most likely some god awful outdated thing
called "openvt" elsewhere.
Fixes#6739
[ci skip]
If given a prompt that includes a non-ascii char and a C locale, fish
currently fails to properly display it.
So you set `function fish_prompt; echo 😃; end` and it shows empty
space.
While the underlying cause is obviously using a C locale and non-C
characters to begin with, this is an unacceptable failure mode.
Apparently I misunderstood wcstombs, so I inadvertently broke this in
2b0b3d3 while trying to fix 5134949's crash.
Just return the offending bit to pre-5134949 levels, so instead of an
infinite recursion we just call a lame function a couple of times.
If given a prompt that includes a non-ascii char and a C locale, fish
currently fails to properly display it.
So you set `function fish_prompt; echo 😃; end` and it shows empty
space.
While the underlying cause is obviously using a C locale and non-C
characters to begin with, this is an unacceptable failure mode.
Apparently I misunderstood wcstombs, so I inadvertently broke this in
2b0b3d3 while trying to fix 5134949's crash.
Just return the offending bit to pre-5134949 levels, so instead of an
infinite recursion we just call a lame function a couple of times.