aboutsummaryrefslogtreecommitdiff
path: root/alacritty/src/main.rs
diff options
context:
space:
mode:
Diffstat (limited to 'alacritty/src/main.rs')
-rw-r--r--alacritty/src/main.rs14
1 files changed, 2 insertions, 12 deletions
diff --git a/alacritty/src/main.rs b/alacritty/src/main.rs
index 6219dd78..da50c3e4 100644
--- a/alacritty/src/main.rs
+++ b/alacritty/src/main.rs
@@ -172,16 +172,6 @@ fn alacritty(mut options: Options) -> Result<(), Box<dyn Error>> {
#[cfg(target_os = "macos")]
locale::set_locale_environment();
- // Create a config monitor when config was loaded from path.
- //
- // The monitor watches the config file for changes and reloads it. Pending
- // config changes are processed in the main loop.
- let mut config_monitor = None;
- if config.live_config_reload {
- config_monitor =
- ConfigMonitor::new(config.config_paths.clone(), window_event_loop.create_proxy());
- }
-
// Create the IPC socket listener.
#[cfg(unix)]
let socket_path = if config.ipc_socket {
@@ -199,7 +189,7 @@ fn alacritty(mut options: Options) -> Result<(), Box<dyn Error>> {
};
// Event processor.
- let processor = Processor::new(config, options, &window_event_loop);
+ let mut processor = Processor::new(config, options, &window_event_loop);
// Start event loop and block until shutdown.
let result = processor.run(window_event_loop);
@@ -219,7 +209,7 @@ fn alacritty(mut options: Options) -> Result<(), Box<dyn Error>> {
// FIXME: Change PTY API to enforce the correct drop order with the typesystem.
// Terminate the config monitor.
- if let Some(config_monitor) = config_monitor.take() {
+ if let Some(config_monitor) = processor.config_monitor.take() {
config_monitor.shutdown();
}