Commit Graph

3664 Commits

Author SHA1 Message Date
Fabian Homborg
edbb8ad0a4 completions/fish: Add --debug-output, remove debug levels
The levels don't do anything anymore, so we can remove them.
2020-12-14 19:36:18 +01:00
Fabian Homborg
6e9364ab50 fish_indent: Change --debug-level to --debug with flog categories
The "debug-level" flag makes little sense since we have no more
debug *levels* left.
2020-12-14 19:36:18 +01:00
Daniel Hoekwater
e8dcef5a71
completions: Fix some more overlong descriptions (#7550)
* Fix overlong completion descriptions for wget

* Fix overlong completion descriptions for valgrind

* Fix overlong completion descriptions for mocha

* Fix overlong completion descriptions for adduser

* Shorten and clean up completion descriptions
2020-12-14 19:01:04 +01:00
Fabian Homborg
c065d24632 completions: More short descriptions
Work on #6981.
2020-12-14 17:42:04 +01:00
Johannes Altmanninger
f1478137dc __fish_complete_path: guard against non-matching input 2020-12-12 08:22:45 +01:00
Johannes Altmanninger
f0f21bdecd Minor refactoring to __fish_git_local_branches 2020-12-12 08:22:24 +01:00
Jason
7e3d3cc30f completions: git switch only takes branch names
Trying to switch to a remote branch like "upstream/ver2" will error with "fatal: a branch is expected, got remote branch 'upstream/ver2'", so these completions should only print the branch name. There doesn't seem to be a function for printing just the branch names for remotes (branch names can have forward-slashes in them), so I have just left them out for now.
2020-12-12 07:19:55 +01:00
Fabian Homborg
952f1971ad completions/mount: Allow files
This can use files/directories in a variety of ways, and it's
basically impossible to enumerate all of them - basically *any file*
could be mounted, if only there is a filesystem for it.

We still give the blockdevices and predefined mountpoints, so they can
still be used.
2020-12-11 23:09:16 +01:00
Fabian Homborg
0fdef958b6 __fish_complete_blockdevice: Default to /dev
This gives all the blockdevices for `mount `

Fixes #7543.
2020-12-11 23:09:16 +01:00
Fabian Homborg
2aaa51e02e Repaint also for fish_color_{host_remote,error}
These are used in our prompts as well.
2020-12-11 20:55:09 +01:00
Fabian Homborg
a4e2a3c049 Reformat web_config css with prettier
I'm not a fan of how prettier formats code, but this file was a mess
with inconsistent indentation, and the result is okay.

[ci skip]
2020-12-10 16:27:00 +01:00
Fabian Homborg
1d7978d282 web_config/colors: Fix div tag
This wasn't closed correctly, and by closed I mean it lacked a `>`.

[ci skip]
2020-12-10 16:27:00 +01:00
Vadim Zyamalov
0200fc0fbc
Creating cache for xbps-query in __fish_print_packages.fish (#7534)
* Completions for xbps were not showed on cache file creation

* Completions for xbps were not showed on cache file creation, small typo
2020-12-08 20:59:56 +01:00
Fabian Homborg
ab5d7f80d0 Restyle codebase
And again clang-format does something I don't like:

-    if (found != end && std::strncmp(found->name, name, len) == 0 && found->name[len] == 0) return found;
+    if (found != end && std::strncmp(found->name, name, len) == 0 && found->name[len] == 0)
+        return found;

I *know* this is a bit of a long line. I would still quite like having
no brace-less multi-line if *ever*. Either put the body on the same
line, or add braces.

Blergh
2020-12-06 15:39:54 +01:00
Jason
9140fc7931
pactl completions: guard call to other pulseaudio tools (#7532)
At least on Arch Linux, pacmd and pulseaudio aren't necessarily available just because pactl is (pipewire is now a thing, and it installs libpulse but not pulseaudio)
2020-12-06 14:54:41 +01:00
Mahmoud Al-Qudsi
a614a19b07 [apt] Dynamic completions for source repo
Dynamically complete the possible candidates for `apt install -t <repo>`
by "parsing" the installed configuration files.

[ci skip]
2020-12-05 10:45:04 -06:00
Fabian Homborg
d9b7cdc43b Webconfig: Move the style to the body, not the ancestor
This allow box shadows to work and removes the last margins when under
700px wide.

I'm not entirely sure we need the ancestor anymore.
2020-12-05 14:47:26 +01:00
Fabian Homborg
96dd8d511e Webconfig: Let it work better on small screens
This allows it to basically work down to quite small widths.
2020-12-04 17:08:45 +01:00
Fabian Homborg
8c5f733e20 Webconfig: Fix error message
For some reason this didn't like the min-height inside the ng-style
thing.
2020-12-04 17:08:45 +01:00
Fabian Homborg
6418e8ea68 Webconfig: Let theme match help and fishshell.com
More consistency is nice.
2020-12-04 17:08:45 +01:00
Fabian Homborg
aaf5bfc25f Webconfig: Support reading term24bit colors for the prompt display
Otherwise this would break colors if fish detected a truecolor terminal.
2020-12-04 17:08:45 +01:00
Fabian Homborg
672fdde1f0 __fish_print_packages: Better parse apt-cache's weird format
Fixes #7521.
2020-12-04 16:45:14 +01:00
Fabian Homborg
eb592092a6 fixup! Only disable WINCH handling in VTE
Apparently iTerm doesn't reflow?

See #7491
2020-11-30 20:50:02 +01:00
Fabian Homborg
df137695bb Disable WINCH handler in reflowing terminals
Fixes #7491.
2020-11-30 20:01:33 +01:00
Enrico Maria De Angelis
2a86099cfd
fish_vi_key_bindings: Implement "d;" and "d," (#7516) 2020-11-29 21:24:42 +01:00
Johannes Altmanninger
4ed22246c3 completions/gem: do not execute completion description 2020-11-29 06:07:00 +01:00
Fabian Homborg
9de809ee98 webconfig: Remove LooseVersion
This writes super cheesy version checking, but allows us to remove
distutils.

Fixes #7514.

Hat tip @zanchey for the check.
2020-11-28 16:12:21 +01:00
Fabian Homborg
eb517e0bdd webconfig: Determine if we're termux without distutils
Just copy that "find an executable" code we already have,
the one that was commented with "oh, btw, distutils.spawn.find_executable is bad",
and use it here as well.

Work towards #7514.
2020-11-28 16:11:09 +01:00
Mahmoud Al-Qudsi
a3cb1e2dcd Fix setting terminal title after fg
The code to override the `(status current-command) was present`, but not
handled in either the default `fish_title` function or the fallback.

Closes #7444.
2020-11-28 00:56:10 -06:00
Marcel Hellwig
c7dc2c5a58 add completion for icdiff
icdiff is a diff command that uses colors by default and is an advances
version of the original diff command

https://github.com/jeffkaufman/icdiff
2020-11-24 19:25:51 +01:00
Milan Zink
f1a5fa82a0 Adding 'dnf versionlock' completions 2020-11-23 21:34:07 -08:00
Fabian Homborg
2e55e34544 Reformat 2020-11-22 14:39:48 +01:00
Mahmoud Al-Qudsi
6c8c8bf819 [zfs] Dynamically complete possible zfs property values
Use the man pages to dynamically generate possible completions for `zfs
set property=` payloads.

[ci skip] // Does that even work for GitHub actions?
2020-11-21 11:05:00 -06:00
Akatsuki Rui
df4114fb93 homectl.fish: fix Expected argument for option a
And a mistake space in description

[ci skip]
2020-11-20 23:08:50 +01:00
Mahmoud Al-Qudsi
01f239188d [zfs] Limit snapshots to spelled-out dataset
Use the `-d` parameter to `zfs list` to limit snapshots to the dataset
named in the current token being completed. Thanks to @Debilski for the
tip.

Closes #7472
2020-11-20 15:28:19 -06:00
Érico Rolim
31870e774a share/functions: account for the possibility of mktemp failure. 2020-11-14 15:57:42 +01:00
Érico Rolim
036ed36887 share/completions/ls: remove double whitespace.
Small typo in the description for one of the options.
2020-11-13 14:34:42 +01:00
Érico Rolim
943ead2598 share/completions: fix non-standard capitalization.
Use "Installed package" instead of "Installed Package".
2020-11-13 14:34:42 +01:00
Mahmoud Al-Qudsi
6bd4f52b0d [zfs] Optimize enumeration of snapshots
Only generate the list of snapshots when
a) the argument must be a snapshot and nothing else, or
b) the argument as typed contains a literal @, or
c) a snapshot is a valid completion and there is only one dataset
   matching the argument as entered.

Unfortunately, it seems the `zfs` command itself is extremely primitive
and doesn't support listing snapshots by dataset so when we need to
generate completions, we end up needing to enumerate all snapshots
(ever) across all datasets. I'd be very happy to be proven wrong, but I
think the only other way would be manually parse `zdb` output.

See #7472
2020-11-12 22:24:29 -06:00
Shawn LeMaster
e4b64448fa Don't assume $__fish_git_prompt_char_cleanstate is non-empty
This fixes the case where an empty "clean state" character
can cause a spurious space character at the end of the git prompt.
2020-11-10 18:55:15 +01:00
Shun Sakai
36337fc45d Add completions for julia 2020-11-09 00:41:38 +09:00
Ayooluwa Isaiah
ea1dffd53d Add support for copy and paste in WSL
- clip.exe is used to copy to the Windows clipboard
- There's no binary for pasting from the Windows clipboard so
  `Get-Clipboard` from powershell is used as a workaround. The
  superflous carriage return is stripped from the output.
2020-11-06 22:10:04 +01:00
Sean Wei
ca0f5686ff Fix typo 2020-10-31 13:27:05 +01:00
Jan-Jaap Korpershoek
4b74fbf1b7
Make mysql completions work with log-in (#7397)
Complete databases using credentials specified on the commandline.
2020-10-30 18:34:23 +01:00
Mahmoud Al-Qudsi
3471db51c8 [completions] Add completions for pidof
[ci skip]
2020-10-30 11:16:22 -05:00
Clément Martinez
5a0bc0a516 Add bluetoothctl completions 2020-10-30 16:38:26 +01:00
Akatsuki Rui
f73808a0fa
Add completions for homect (#7435)
systemd-homed control tool

based on the systemd v246.6-1 manpage
2020-10-30 04:25:54 +01:00
Akatsuki Rui
d9b39b0d51 hostnamectl.fish: new completion
systemd-hostnamed control tools
2020-10-28 19:38:45 +01:00
Akatsuki Rui
9910bdf07a coredumpctl.fish: new completion
systemd-coredump control tools
2020-10-28 19:38:45 +01:00
Akatsuki Rui
91d6e50ed8 bootctl.fish: new completion
systemd-boot control tools
2020-10-28 19:38:45 +01:00