config: add "initial-command" config, "-e" sets that

Fixes #2601

It is more expected behavior that `-e` affects only the first window. By
introducing a dedicated configuration we avoid making `-e` too magical:
its simply syntax sugar for setting the "initial-command" configuration.
This commit is contained in:
Mitchell Hashimoto
2024-11-05 16:51:13 -08:00
parent 98c4c453ee
commit 65f1cefb4e
3 changed files with 43 additions and 10 deletions

View File

@@ -66,6 +66,11 @@ font_grid_set: font.SharedGridSet,
last_notification_time: ?std.time.Instant = null,
last_notification_digest: u64 = 0,
/// Set to false once we've created at least one surface. This
/// never goes true again. This can be used by surfaces to determine
/// if they are the first surface.
first: bool = true,
pub const CreateError = Allocator.Error || font.SharedGridSet.InitError;
/// Initialize the main app instance. This creates the main window, sets