repositories / dotfiles

dotfiles

bugabingas dorkfiles

owned by bugabinga

wezterm: remove mux server for now

552ff709766d4a31b2c08c48ef7238d35a7397fa

Oliver Krylow <o.krylow@isp-insoft.de> ·

unsigned

Browse filesCompare with HEAD

Changed files (2)

wezterm/bugabinga/workspaces.lua

Modified
1 1 local wez = require 'wezterm'
2 2 local mux = wez.mux
3 +local win32 = wez.target_triple:find'windows'
5 5 local get_my_code_workspace = function()
6 - if wez.target_triple:find('windows') then
6 + if win32 then
7 7 return 'W:'
8 8 else
9 9 return os.getenv 'HOME' .. '/Workspace'
13 13 local WORKSPACE = get_my_code_workspace()
15 -wez.on('gui-attached', function()
16 - -- maximize all displayed windows on startup
15 +-- maximize all displayed windows
16 +local maximize_window = function()
17 17 local workspace = mux.get_active_workspace()
18 18 for _, window in ipairs(mux.all_windows()) do
19 19 if window:get_workspace() == workspace then
20 20 window:gui_window():maximize()
23 -end)
23 +end
25 --- NOTE(oli): errors in here do not show up as configuration errors
26 --- check the log file in the wezterm mux server runtime directory
27 --- e.g. /run/user/1000/wezterm/log
28 -wez.on('mux-startup', function()
25 +local setup_workspaces = function()
29 26 local dork_ws = 'dorkfiles editing'
30 27 local dork_cwd = WORKSPACE .. '/dotfiles'
31 28 local dork_tab, dork_pane, dork_window = mux.spawn_window { cwd = dork_cwd, workspace = dork_ws }
51 48 default_top_pane:activate()
53 50 mux.set_active_workspace(default_ws)
51 +end
53 +wez.on('gui-attached', function()
54 + maximize_window()
55 + -- mux server seems very slow on windows...
56 + if win32 then setup_workspaces() end
57 +end)
59 +-- NOTE(oli): errors in here do not show up as configuration errors
60 +-- check the log file in the wezterm mux server runtime directory
61 +-- e.g. /run/user/1000/wezterm/log
62 +wez.on('mux-startup', function()
63 + setup_workspaces()
54 64 end)

wezterm/wezterm.lua

Modified
3 3 local wez = require 'wezterm'
4 4 local nugu = require 'bugabinga.nugu'
6 6 local key_binds = require 'bugabinga.key_binds'
7 7 local dark_mode = require 'bugabinga.dark_mode'
8 -local workspaces = require 'bugabinga.workspaces'
8 +-- TODO mux server seems slow.
9 +-- local workspaces = require 'bugabinga.workspaces'
9 10 local status = require 'bugabinga.status'
11 12 local hostname = wez.hostname()
33 34 warn_about_missing_glyphs = false,
34 35 color_scheme = dark_mode,
35 36 color_schemes = nugu,
36 - window_background_opacity = 1.0,
37 + window_background_opacity = 0.69,
37 38 -- nightly
38 - -- win32_system_backdrop = 'Acrylic',
39 - --default_cwd = wez.home_dir,
39 + win32_system_backdrop = 'Acrylic',
40 + default_cwd = wez.home_dir,
40 41 default_prog = { 'nu' },
41 42 default_cursor_style = 'SteadyBlock',
42 43 cursor_blink_rate = 0,
70 71 leader = key_binds.leader,
71 72 keys = key_binds.keys,
72 73 key_tables = key_binds.key_tables,
73 - unix_domains = {
74 - {
75 - name = 'unix',
76 - } },
77 - default_domain = 'unix',
78 - default_gui_startup_args = { 'connect', 'unix' },
79 - -- TODO(oli): create different launchers per OS
80 - launch_menu = {
81 - {
82 - label = 'Bash',
83 - args = {'bash', '-l'},
84 - }
85 - }