Commit Graph

10304 Commits

Author SHA1 Message Date
ridiculousfish
b8170ec1ce Clarify return value of job_reap and process_clean_after_marking 2019-05-01 16:32:14 -07:00
ridiculousfish
9700800ecf Factor disowned job removal into its own function
This helps break up process_clean_after_marking.
2019-05-01 16:31:21 -07:00
ridiculousfish
c05e72749a Rename PENDING_REMOVAL to DISOWN_REQUESTED
A commend implied that PENDING_REMOVAL was broader than it was. In practice
only disown() sets this flag. Rename the flag for clarity.
2019-05-01 15:37:53 -07:00
Aaron Gyes
b5865d2cba Spruce up fish_config output, show transcript of commands run
run_fish_cmd() now prints every command we run in a subshell

Fixes #5584
2019-04-30 14:08:11 -07:00
Fabian Homborg
05b2d4ee54 Docs: Document path vars more
Fixes #5741.

[ci skip]
2019-04-30 13:18:56 +02:00
Fabian Homborg
17116366dc docs: Remove explicit .html links
Instead, we link to rst labels, which could also work in non-html
output, or if the section ever moves elsewhere.

See #5696.

[ci skip]
2019-04-30 13:11:33 +02:00
Fabian Homborg
1377f71331 docs: Remove some more html
See #5696.

[ci skip]
2019-04-30 12:56:30 +02:00
Fabian Homborg
03431ae9a2 docs: Default to fish highlighting
This fixes highlighting in cmds/.

See #5696.

[ci skip]
2019-04-30 12:49:04 +02:00
Fabian Homborg
d8f922fd70 docs: Remove <outp> tags
fish_indent_lexer formats lines not starting with a prompt indicator
as output, as long as there is a prompt indicator elsewhere.

So these tags are useless and wrong.

See #5696.

[ci skip]
2019-04-30 12:44:55 +02:00
Fabian Homborg
6f45b8d632 docs/fish_indent_lexer: Support >_ as prompt indicator
This was widely used in the old docs, and currently it just allowed `>`.

See #5696.

[ci skip]
2019-04-30 12:44:49 +02:00
Fabian Homborg
3b532fc793 functions/fish_vi_key_bindings: Pass "-s" to shared bindings
Fixes #5853.

[ci skip]
2019-04-30 11:41:26 +02:00
David Adam
665ae3787a Switch to runtime check for /proc/self/stat
Removes a compile-time check that may have affected cross-compilation.

Work on #1067.
2019-04-30 16:23:28 +08:00
Fabian Homborg
e8fd83ca25 docs/index: Remove wrong "configuration variables"
Hat-tip to @enzotib on gitter.

[ci skip]
2019-04-29 21:19:43 +02:00
Wilke Schwiedop
95346770d3 Update emaint.fish 2019-04-29 18:33:37 +02:00
Wilke Schwiedop
78e6631e53 formatting 2019-04-29 18:33:37 +02:00
Wilke Schwiedop
05f79335cc completions/emerge: add verbose-conflicts 2019-04-29 18:33:37 +02:00
Wilke Schwiedop
1b3643270d completions/epkginfo: add completion 2019-04-29 18:33:37 +02:00
Wilke Schwiedop
d0c3a4f33f completions/equery: shorten descriptions 2019-04-29 18:33:37 +02:00
Wilke Schwiedop
34f50883a4 completions/ebuild: add pretend command 2019-04-29 18:33:37 +02:00
Wilke Schwiedop
52450dc864 completions/emaint: fix logs command 2019-04-29 18:33:37 +02:00
Fabian Homborg
389f5074ad Add test for argparse crash
43929ced9
2019-04-29 17:03:16 +02:00
Fabian Homborg
43929ced90 src/builtin_argparse: Work around wgetopt crash
If on the last argument, and it was an unrecognized option, we can't
call `wgetopt_long()` again, or it'll crash.
2019-04-29 16:55:55 +02:00
Fabian Homborg
8c9359fdd4 src/builtin_argparse: Add --ignore-unknown flag
This keeps all unknown options in $argv, so

```fish
argparse -i a/alpha -- -a banana -o val -w
```

results in $_flag_a set to banana, and $argv set to `-o val -w`.

This allows users to use multiple argparse passes, or to simply avoid
specifying all options e.g. in completions - `systemctl` has 46 of
them, most not having any effect on the completions.

Fixes #5367.
2019-04-29 15:57:56 +02:00
ridiculousfish
d8ac051f89 Move selection_direction_t to pager.h and make it a class enum 2019-04-28 14:06:03 -07:00
ridiculousfish
3c9f95594a Update Dockerfile for cmake3 2019-04-28 11:41:37 -07:00
ridiculousfish
2507162f80 Revert "Add a test for autoload_t"
This reverts commit 51c62d6cc6.

Back out the test while I attempt to fix it
2019-04-27 20:14:06 -07:00
ridiculousfish
51c62d6cc6 Add a test for autoload_t 2019-04-27 16:16:48 -07:00
ridiculousfish
4ff50eba41 Remove autoload_t, rename autoloader_t to autoload_t
Now that there are no more clients of autoload_t, delete it and
rename autoloader_t to autoload_t. Also clean up the headers.
2019-04-27 15:47:08 -07:00
ridiculousfish
68a28106b2 Reimplement completion autoloading via autoloader_t
This switches the completion autoloading machinery to autoloader_t.
2019-04-27 15:37:24 -07:00
ridiculousfish
960266fe24 Reimplement the function store and autoloading
This cleans up how functions are stored and autoloaded. It eliminates the
recursive lock. Instead there is a single normal owning_lock that protects
the entirety of the function data. Autoloading is re-implemented via the
new autoloader_t.
2019-04-27 15:30:11 -07:00
ridiculousfish
3950dab9ff Add autoloader_t
autoloader_t will be the reimplementation of autoloading. Crucically it no
longer manages any locking or loading itself; instead all locking and loading
is performed by clients. This makes it easier to test and helps limit its
responsibilities.
2019-04-27 15:26:18 -07:00
ridiculousfish
b7ad6b5bdc Add autoload_file_cache_t
This will provide the "backing store" for autoloading.
2019-04-27 15:09:24 -07:00
ridiculousfish
6ec7c50ace Stop removing functions and completions in autoload
autoloading has a "feature" where functions are removed in an LRU-fashion.
But there's hardly any benefit in removing autoloaded functions. Just stop
doing it.
2019-04-27 14:49:05 -07:00
ridiculousfish
7b44b5ef15 Titlecase LRU template parameters 2019-04-27 12:07:16 -07:00
ridiculousfish
f297543ca1 Make owning_lock's template parameter titlecase instead of uppercase 2019-04-27 12:04:36 -07:00
Fabian Homborg
af0e08e9f1 argparse: Use the current function name by default
This makes the `--name` option usually unnecessary.

See #5835.
2019-04-27 15:55:49 +02:00
Fabian Homborg
eb0e0a4ab4 docs/argparse: Fix links
Fixes #5847.

[ci skip]
2019-04-27 12:16:53 +02:00
puenka
30f040ed36 Add speedtest-cli/speedtest completion (#5840)
* Add speedtest-cli/speedtest completion

Added a completion file for speedtest-cli utility (https://github.com/sivel/speedtest-cli) as shipped from various package repositories.

* added no-files parameter

* Remove inheritance to speedtest

* Create speedtest.fish
2019-04-27 09:34:28 +02:00
ridiculousfish
9bc5d60eaf Clean up enum_set.h header
Include a missing array header, and switch to idiomatic include guards.
2019-04-26 16:08:19 -07:00
Fabian Homborg
e084d097d5 docs: Remove <asis> markup
This isn't needed anymore.

[ci skip]
2019-04-26 19:25:30 +02:00
Fabian Homborg
ff62f2ae08 docs/bind: Document path-component and word
Plus fix some formatting.

[ci skip]
2019-04-26 19:23:24 +02:00
Fabian Homborg
94ece96bce CHANGELOG path-component
I should really add this immediately.

[ci skip]
2019-04-26 19:17:27 +02:00
Fabian Homborg
009ecfd7e6 src/tokenizer: Add ":@" to the list of non-path-component chars
This makes kill-path-component stop there.

Fixes #5841.
2019-04-26 19:16:21 +02:00
Fabian Homborg
ebf1914a35 CHANGELOG complete -C change
[ci skip]
2019-04-26 16:11:43 +02:00
David Gowers
38cadc9d4f Variables as commands are in fact supported, eval docs should not claim otherwise. (#5819)
Provide an example that somewhat justifies eval's existence in light of this change.

Also correct similar misinformation found in a comment.
2019-04-26 15:30:13 +02:00
Fabian Homborg
22ce8c23c6 builtin_complete: Allow complete -C something
This is a long-standing issue with how `complete --do-complete` does
its argument parsing: It takes an optional argument, so it has to be
attached to the token like `complete --do-complete=foo` or (worse)
`complete -Cfoo`.

But since `complete` doesn't take any bare arguments otherwise (it
would error with "too many arguments" if you did `complete -C foo`) we
can just take one free argument as the argument to `--do-complete`.

It's more of a command than an option anyway, since it entirely
changes what the `complete` call _does_.
2019-04-26 15:02:29 +02:00
ridiculousfish
cd86c0ee88 Remove the COMPLETE_SEP define
It was unused.
2019-04-25 14:23:37 -07:00
ridiculousfish
96bc8a14ca Promote completion_mode_t to a real type
Eliminate big #defines like NO_COMMON.
2019-04-25 14:21:06 -07:00
ridiculousfish
d962668aa0 Remove PATH and COMMAND defines
Also clean up a bit of builtin_complete
2019-04-25 13:26:43 -07:00
ridiculousfish
496529b20a Remove EXPAND prefix from expand_flags and lowercase them 2019-04-25 11:34:49 -07:00