Commit Graph

11767 Commits

Author SHA1 Message Date
Johannes Altmanninger
0bb3efb1ad Docs: add missing backticks 2020-03-07 18:33:39 +01:00
Mahmoud Al-Qudsi
4a3ffe741c Partilaly revert 0b7bbb5654
The changes to the `cargo` completions resulted in screenfuls of junk
being dumped to the tty on `cargo pu<TAB>`.
2020-03-07 08:44:00 -06:00
Johannes Altmanninger
917f759a1a prompt: don't consider SIGPIPE a failure
Reproduce by running git log and press "q".
This regressed in master in 5d135d5.

[ci skip]
2020-03-07 14:13:58 +01:00
Johannes Altmanninger
da7b762f4a Make default hg prompt leaner
The default hg prompt is slow on large repositories (hg status takes
2-3 seconds on mozilla-central) which is unacceptable as a default.

Mimick our git prompt: by default, only show the current branch.
If the new variable $fish_prompt_hg_show_informative_status is set,
then use the old behavior.

[ci skip]
2020-03-07 13:02:58 +01:00
ridiculousfish
6f22aadaf7 Merge branch 'debounce'
This adds 'debounce' support to highlighting and autosuggestions, so
that we do not spawn excessive threads.
2020-03-06 18:13:57 -08:00
ridiculousfish
e334becefb Adopt debounce for highlighting and autosuggestions
This prevents a thundering herd of threads for certain interactive
scenarios.
2020-03-06 17:15:23 -08:00
ridiculousfish
bde2f2111d Introduce debounce_t
debounce_t will be used to limit thread creation from background highlighting
and autosuggestion scenarios. This is a one-element queue backed by a
single thread. New requests displace any existing queued request; this
reflects the fact that autosuggestions and highlighting only care about
the most recent result.

A timeout allows for abandoning hung threads, which may happen if you
attempt to e.g. access a dead hard-mounted NFS server. We don't want
this to defeat autosuggestions and highlighting permanently, so allow
spawning a new thread after the timeout (here 500 ms).
2020-03-06 17:15:21 -08:00
ridiculousfish
a6b565d502 Optimize parse_util_compute_indents
Exploit the fact that most input strings will not contain newlines,
in which case we do not have to parse anything.
2020-03-06 16:15:37 -08:00
Jason Nader
b4626468ec completion helper functions: do not use gettext
remove package
2020-03-06 22:23:50 +01:00
Jason Nader
12ce66684e completions: add mpv 2020-03-06 22:22:52 +01:00
afg
f0d42ea602 time: decide unit using largest value 2020-03-06 22:16:24 +01:00
Delapouite
5e3328ef1f doc(end): mention the 'function' command and add links to all block starters 2020-03-06 22:14:53 +01:00
Fabian Homborg
17f989edf4 docs: Move completion tutorial out into its own document
This is useful, but it's a rather large thing that's uninteresting to
many users. So we put it into its own (top-level, for now) document.
2020-03-06 22:14:30 +01:00
ridiculousfish
f10ef4f948 Remove cancellable.h
This should never have been checked in, it's unused. Mea culpa.
2020-03-04 21:11:39 -08:00
exploide
61de39bd68 updated grep completion
added group-seperator options to grep completion
distinguished between -r and -R
removed deprecated option
2020-03-04 11:31:05 -08:00
Delapouite
fba6da983b doc: add section about abbreviations in the index
Fix: #3861
2020-03-04 11:13:59 -08:00
Jason Nader
19e43a5df7 docs: remove undefined label 2020-03-04 10:39:55 -08:00
Jason Nader
97d5f68cdf completions: update ftp 2020-03-04 10:26:54 -08:00
Norio Nomura
60fca97523 Add test to verify that the fish_postexec handler is called after SIGINT 2020-03-03 21:49:15 -08:00
Norio Nomura
4f0fab04ad Clear cancellation_signal before firing fish_postexec event
Fix #2356
2020-03-03 21:35:29 -08:00
ridiculousfish
17c569f6d5 Disable SIGINT handling expect test
The problem is that under TSAN, the timing of signals becomes very weird and
exposes some real race conditions. We will need to re-design how signal
event handlers work.
2020-03-03 18:15:24 -08:00
Delapouite
8530a4bd9e doc: add interlinks between echo ←→ printf commands 2020-03-03 20:01:48 +01:00
ridiculousfish
593c43663c Add a bit of a delay to signals.expect test
Unclear why this is needed.
2020-03-03 10:52:16 -08:00
Jason Nader
3774edba93 completions: add imv 2020-03-03 18:32:53 +01:00
Jason Nader
4b95f2c5ee completions: add ps2pdf wrapper functions 2020-03-03 18:32:13 +01:00
exploide
e48ef850b9 added completions for tcpdump 2020-03-03 18:31:42 +01:00
Fabian Homborg
4f47636838 fish_print_hostnames: Fix multiple host aliases
Fixes #6698.

[ci skip]
2020-03-03 18:30:06 +01:00
Jason Nader
86b7c1034c Prevent prompt from spewing errors if cwd has disappeared 2020-03-03 18:06:20 +01:00
Sacha Delanoue
0fac2e0496 Fix 256 color detection on xterm-like
bbc3fecbe introduced a regression where support for 256 color was not
detected on xterm-like terminals that did not define the TERM_PROGRAM
env variable. Almost no terminal on linux define this variable.
2020-03-03 18:03:15 +01:00
ridiculousfish
f6e5a5c521 Thread a cancellation function into is_potential_path
Allows sooner cancellation of redundant operations like highlighting.
2020-03-02 22:10:43 -08:00
ridiculousfish
a65e3f1876 Check for cancellation more often in highlighting 2020-03-02 22:02:03 -08:00
ridiculousfish
8355285736 Add a category for screen repainting 2020-03-02 18:31:24 -08:00
ridiculousfish
b0c2eda3b4 Revert "Revert "Enable job-control in pipeline-pgroup test""
This reverts commit c9f450a93e.

Puts back job-control in this test.
2020-03-02 14:01:59 -08:00
ridiculousfish
1c5b1ff5c2 Correct a race condition in pipeline-pgroup test
This test launches two background processes and is sensitive to
interleaving of output. Fix it so that newlines are not output by
the background process.

Hopefully this fixes the flakiness of this test.
2020-03-02 14:00:57 -08:00
ridiculousfish
bd17262e17 Reduce iteration count in thread torture test
Helps the test pass on 32 bit.
2020-03-02 13:46:08 -08:00
Jason Nader
c5d6a54462 completions: update GNU wc options 2020-03-02 22:21:12 +01:00
ridiculousfish
bb4e36da47 Do not remove jobs that need to print a status message
55e3270 introduced a regression where we would remove all completed
jobs. But jobs that want to print a status message get skipped, so
the status message (and associated event handlers) might not get run.

Fix this by making it explicit which jobs are safe to process, and which
should be skipped.

Fixes #6679.
2020-03-02 12:34:07 -08:00
Jason Nader
9c8fff08c1 fish_npm_helper: fix typo in comments 2020-03-02 21:36:11 +08:00
ridiculousfish
c9f450a93e Revert "Enable job-control in pipeline-pgroup test"
This reverts commit cdbf0a9d20.

Reverting until the tests pass consistently.
2020-03-01 23:35:53 -08:00
ridiculousfish
bc702ccb31 Fix interactive --on-signal INT handlers
f8ba0ac5bf introduced a bug where INT handlers would themselves be
cancelled, due to the signal. Defer processing handlers until the
parser is ready to execute more fish script.

Fixes the interactive case of #6649.
2020-03-01 13:31:59 -08:00
Fabian Homborg
bfc1de9ef4 argparse: Pass validation variables as exported
This was written before local-exported variables did anything useful.

Passing these vars as local-exports removes the need to define the
validation function with `--no-scope-shadowing` which is quite the
hack.
2020-03-01 19:28:51 +01:00
Fabian Homborg
0f34459fce Disable svn prompt by default
This is apparently quite slow on large svn repos (like 40 seconds
slow), and we don't have a good thing to display other than the full
file information.

So we'll have to disable it for now.

Fixes #6681.

[ci skip]
2020-03-01 17:04:02 +01:00
Jason Nader
f897948442 completions: update rfkill 2020-03-01 13:48:36 +01:00
Jason Nader
49bdab4898 completions: update timeout 2020-03-01 13:47:53 +01:00
exploide
41e6d4cc9c added completion for dhclient 2020-03-01 13:46:21 +01:00
akspecs
23f942b315 added uncompressed pkg.tar files for completion 2020-03-01 13:45:20 +01:00
Jason Nader
fed0e0833d Run fish_indent on completions 2020-03-01 13:44:51 +01:00
mczoden
5d03ca9de0
Fix expand.cpp compile failed with old SDK version (#6688)
* Fix expand.cpp compile failed with old SDK version

* add a comment to stop clang-format from recording
2020-03-01 13:44:06 +01:00
ridiculousfish
cdbf0a9d20 Enable job-control in pipeline-pgroup test
Otherwise it's not testing anything interesting
2020-02-29 18:00:19 -08:00
ridiculousfish
d4103d582b Correct the speeling of sentinel 2020-02-29 15:56:52 -08:00