1
0
Fork 0
mirror of https://github.com/alacritty/alacritty.git synced 2024-11-25 14:05:41 -05:00
Commit graph

12 commits

Author SHA1 Message Date
Christian Duerr
437f42f8d3
Migrate from structopt to clap 3 2022-01-04 18:25:26 +00:00
Kirill Chibisov
ce59fa4165
Add title/class CLI parameters to create-window
This adds the ability to pass title and class over IPC via the
create-window subcommand, so users can run only one instance for windows
of different spurposes in the window managers of their choice.
2022-01-03 18:55:22 +00:00
Kirill Chibisov
8681f71084
Add parameters to msg create-window subcommand
Alacritty's `msg create-window` subcommand would previously inherit all
the CLI parameters from the original executable. However not only could
this lead to unexpected behavior, it also prevents multi-window users
from making use of parameters like `-e`, `--working-directory`, or
`--hold`.

This is solved by adding a JSON-based message format to the IPC socket
messages which instructs the Alacritty server on which CLI parameters
should be used to create the new window.

Fixes #5562.
Fixes #5561.
Fixes #5560.
2021-11-22 18:34:09 +00:00
Christian Duerr
c89939b5d1
Switch to clap-generated completions
The current completions required a lot of domain-specific knowledge
about each individual shell and their completion functionality. Much of
which is sparsely documented.

While clap does not generate perfect completions, since parameters like
`-e` are missing completions, it does a reasonable job while requiring
no work on writing these completions.

Since access to `cli.rs` isn't possible from the `build.rs`, these
completions aren't always generated on build. Instead a test verifies
that there has been no changes to these completions and provides a
simple code sample for re-generating them. This should provide a simple
solution with minimal overhead.
2021-11-19 23:34:40 +00:00
Christian Duerr
1df7dc5171
Add multi-window support
Previously Alacritty would always initialize only a single terminal
emulator window feeding into the winit event loop, however some
platforms like macOS expect all windows to be spawned by the same
process and this "daemon-mode" can also come with the advantage of
increased memory efficiency.

The event loop has been restructured to handle all window-specific
events only by the event processing context with the associated window
id. This makes it possible to add new terminal windows at any time using
the WindowContext::new function call.

Some preliminary tests have shown that for empty terminals, this reduces
the cost of additional terminal emulators from ~100M to ~6M. However at
this point the robustness of the daemon against issues with individual
terminals has not been refined, making the reliability of this system
questionable.

New windows can be created either by using the new `CreateNewWindow`
action, or with the `alacritty msg create-window` subcommand. The
subcommand sends a message to an IPC socket which Alacritty listens on,
its location can be found in the `ALACRITTY_SOCKET` environment
variable.

Fixes #607.
2021-10-23 07:16:47 +00:00
Ben Denhartog
cb46f0e1ac
Remove --dimensions/-d from bash completions 2021-01-29 20:29:26 +00:00
Jason
34435ed776
Update shell completions
This fixes the shell completion by removing the flags removed from the
CLI in 0768428 and adding the new options flag.
2021-01-17 11:22:06 +00:00
Valentin Ignatev
4cb5566a9c Add --hold CLI flag
This implements --hold flag which keeps Alacritty open after
its child process exits.

Fixes #1165.
2019-10-09 23:37:48 +02:00
mkosem
c1f089970f Add Xembed support
Fixes #631.
2019-09-24 19:43:54 +02:00
Oliver Kiddle
d86eff6f14 Follow zsh conventions in zsh completion
Declaring curcontext etc local is superfluous as _arguments states are
not used. It is also superfluous to include an outer function definition
syntax in zsh autoloadable functions. Zsh convention is not to
capitalize descriptions. It is also better to use the imperative mood
verb form for descriptions as this allows them to start with the
shortest form of the verb - e.g. "reduce" instead of "reduces" and
results in better grammar in the absence of a sentence subject. I'd
recommend this in the --help output too. Using _guard for the position
and dimensions was unnecessary given that the values are not mixed with
other matches.
2019-08-25 02:45:48 +02:00
Kirill Chibisov
7331e89122 Add class and short title completions
Fixes #2612.
2019-07-08 15:19:42 +00:00
Christian Duerr
6f4d1afcf8
Add official logo 2019-04-01 22:41:20 +00:00