Mahmoud Al-Qudsi
1db861b4db
Clean & slightly optimize SSH hostnames handling in __fish_print_hostnames
2019-09-05 22:44:09 -05:00
Mahmoud Al-Qudsi
06317f0a98
Optimize __fish_print_hostnames
hosts file loading/parsing
...
Reordering the `getent hosts` and read from `/etc/hosts` combined with
minimizing shelling and job invocations for parsing the output results
in a profiled and benchmarked ~42% decrease in the time it takes to run,
and that's on a machine with a very small hosts list in the first place.
This update also fixes the hadling of IPv6 addresses in the hosts
output, which were previously ignored, and ignores 127.* loopback
addresses in addition to the 0.0.0.0 address (plus adds support for
shorter IPv4 notations).
2019-09-05 22:44:09 -05:00
ridiculousfish
b760fd9064
Correctly set g_use_posix_spawn at launch again
2019-09-05 11:00:52 -07:00
LawAbidingCactus
c20a9ea477
fix compatibility with BSD sed
...
Closes #6087 .
2019-09-03 15:35:04 +08:00
Johannes Altmanninger
f7dac82ed6
Escape separators (colon and equals) to improve completion
...
Fish completes parts of words split by the separators, so things like
`dd if=/dev/sd<TAB>` work.
This commit improves interactive completion if completion strings legitimately
contain '=' or ':'. Consider this example where completion will suggest
a🅰️ 1 and other files in the cwd in addition to a:1
touch a:1; complete -C'ls a:'
This behavior remains unchanged, but this commit allows to quote or escape
separators, so that e.g. `ls "a:<TAB>` and `ls a\:<TAB>` successfully complete
the filename.
This also makes the completion insert those escapes automatically unless
already quoted.
So `ls a<TAB>` will give `ls a\:1`.
Both changes match bash's behavior.
2019-09-02 14:27:21 -07:00
David Adam
54ed2ad440
history: implement exact matching by default for delete
...
Brings behaviour into line with documented and intended behaviour.
Closes #6070 .
2019-09-02 22:59:52 +08:00
Nathan Galt
8b84f4f117
Add completions/tokei.fish
...
Closes #6085 .
2019-09-02 22:37:01 +08:00
Nathan Galt
76195dfe1d
Update bat completions from 0.11.0 to 0.12.0
...
Closes #6084 .
2019-09-02 22:35:08 +08:00
Nathan Galt
635dafeb9c
Update bat completion to support cache command
...
Closes #6076 .
2019-09-02 22:32:47 +08:00
Shun Sakai
5221d723ca
Added patool completions
2019-09-01 17:28:46 -07:00
ridiculousfish
9fd9f70346
Restore terminal modes after sending SIGCONT
...
Fixes #2214
Thanks to @bruce-hill for the patch.
2019-09-01 17:24:23 -07:00
Johannes Altmanninger
068aba1902
remove redundant call (done in constructor of completion_t)
2019-08-31 12:05:49 -07:00
Shun Sakai
42c6b9c176
Implemented the completions of all options of git restore
and git switch
( #6054 )
...
* Implemented the completions of all options of `git restore` and `git switch`
* Apply requested changes
2019-08-30 11:31:35 +02:00
Sergei Morozov
753f49dba9
Added git rebase --rebase-merges[=(rebase-cousins|no-rebase-cousins)] to completion
...
See https://git-scm.com/docs/git-rebase/2.18.0#git-rebase--r
2019-08-27 22:04:55 +02:00
LawAbidingCactus
35b64b0470
add completions for qubes-gpg-client
2019-08-27 15:20:07 +08:00
Mahmoud Al-Qudsi
af4b54e635
Change WSL version check to a hard error, but include a bypass
...
Instead of warning (debug level 1), we now emit an error (debug level 0) if a known bad version of
WSL is detected. However, `FISH_NO_WSL_CHECK` can now be defined to skip both the check and the
startup message.
2019-08-25 18:50:17 -05:00
Mahmoud Al-Qudsi
44022e65c2
Revert "Remove the WSL warning"
...
This reverts commit 5101bdeb9f
.
2019-08-25 18:29:46 -05:00
ridiculousfish
99c498d3d7
Use move semantics in trim and history_item_t
2019-08-25 13:37:06 -07:00
adiabatic
dd34bf0ba6
Create bat.fish
2019-08-23 21:49:55 -07:00
Fabian Homborg
4c656dd43e
docs/fish_git_prompt: showupstream is a proper list
...
"space-delimited" sounds like you'd set it like `set
__fish_git_prompt_showupstream "auto verbose"`. This will not work.
It's a real actual proper list, which aren't space-delimited.
[ci skip]
2019-08-23 19:35:39 +02:00
LawAbidingCactus
1a361cd3ff
specify that __fish_git_prompt_describe_style only takes one argument
2019-08-23 10:25:58 -07:00
LawAbidingCactus
ea041e6668
specify that __fish_git_prompt_showupstream takes multiple arguments
2019-08-23 10:25:58 -07:00
LawAbidingCactus
b0e9317dd2
document auto option for __fish_git_prompt_showupstream
2019-08-23 10:25:58 -07:00
David Adam
225b1204d6
read: add --list as synonym for --array
...
Work on #5846 .
2019-08-22 21:24:17 +08:00
David Adam
e3eb8f758b
README: note that chsh requires logout/login
...
Suggested in #6051 .
[ci skip]
2019-08-22 21:24:17 +08:00
Shun Sakai
ecacf34693
Added git restore
and git switch
completions
...
These commands were added in version 2.23.
2019-08-22 20:25:02 +08:00
ridiculousfish
903e7c6d5e
history_lru_cache_t to use move semantics
2019-08-18 12:14:07 -07:00
ridiculousfish
9b2b7f787e
Migrate history profiling to flog
2019-08-18 11:14:45 -07:00
ridiculousfish
0da87d3e5f
Equip history_item_t with a default constructor
2019-08-17 20:01:44 -07:00
adiabatic
85f57d1d33
Create hledger.fish
2019-08-16 21:25:41 -07:00
ridiculousfish
5101bdeb9f
Remove the WSL warning
...
This warning is annoying and there is no way to disable it.
Ping #5661 . Ping #5298 . Closes #6038
2019-08-16 20:59:53 -07:00
ridiculousfish
f137f24d75
Initialize a const variable
...
Fixes #6041
2019-08-16 17:50:41 -07:00
ridiculousfish
124def8f4b
Un-changelog the history fix
...
Turns out the bug never actually shipped in a release; it bisected to
3ae5b23971
2019-08-15 19:59:35 -07:00
ridiculousfish
a87e0183df
Stop rewriting the history file on every command
...
fish is designed to append to the history file in most cases. However
save_internal_via_appending was never returning success, so we were
always doing the slow rewrite path. Correctly return success.
Fixes #6042
2019-08-15 13:49:17 -07:00
ridiculousfish
7ab291775a
Add flog logging to history
2019-08-15 13:42:23 -07:00
Tobias Hernstig
332b305f81
Documentation: Initialization files paths
...
Adds slash to end of example paths to align with that
~/.config/fish/conf.d/ had a slash at the end.
2019-08-14 20:36:08 +02:00
Aaron Gyes
47798510bd
tests, CHANGELOG: regex-easyesc
...
Oops, missed these the first time around.
2019-08-13 22:56:31 -07:00
Aaron Gyes
edc8d5d7a3
string-replace-fewer-backslashes -> regex-easyesc
...
This shortens a very long feature name.
See discussion in #5805
2019-08-13 22:32:04 -07:00
ridiculousfish
ce178fd6fd
Make escape_yaml_fish_2_0 and unescape_yaml_fish_2_0 static
...
They no longer need to be exposed.
2019-08-12 09:22:21 -07:00
ridiculousfish
3ae5b23971
Migrate append_history_item_to_buffer to history_file.cpp
...
Also eliminate history_output_buffer_t, which no longer does anything useful.
2019-08-12 09:17:10 -07:00
ridiculousfish
6eebe4cc83
Eliminate history_lru_item_t
...
history_item_t is enough
2019-08-11 14:26:22 -07:00
ridiculousfish
6b008c3eae
Stop caching the lowercase string contents in history items
2019-08-11 13:41:04 -07:00
ridiculousfish
92e9a34b47
Simplify history_output_buffer_t
2019-08-11 13:08:31 -07:00
ridiculousfish
2ddde381d4
Clean up next_line() interface and implementation
2019-08-11 12:57:09 -07:00
ridiculousfish
91987a4548
Migrate history file format stuff into new file history_file.cpp
...
Breaks up the history.cpp monolith.
2019-08-11 12:45:04 -07:00
ridiculousfish
74357bac91
Remove an errant semicolon
2019-08-10 16:47:45 -07:00
ridiculousfish
fd5d8c1949
Remove __packed
...
We can use the new C++11 enum type feature to stop using this non-portable
__packed.
2019-08-10 16:04:05 -07:00
ridiculousfish
30fd526fc1
Correct an out-of-bounds index in screen
...
Fixes #6037
2019-08-10 14:32:55 -07:00
adiabatic
ab6fd6554f
Add completions/cwebp.fish
2019-08-08 18:51:13 +02:00
LawAbidingCactus
cc6a82c878
clean up formatting
2019-08-08 18:49:26 +02:00