-
Notifications
You must be signed in to change notification settings - Fork 0
/
.wezterm.lua
83 lines (70 loc) · 1.68 KB
/
.wezterm.lua
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
-- Pull in the wezterm API
local wezterm = require 'wezterm'
-- This will hold the configuration.
local config = wezterm.config_builder()
config.exit_behavior = 'Close'
-- For example, changing the color scheme:
config.color_scheme = 'Ayu Mirage'
-- Tab config
config.use_fancy_tab_bar = true
config.hide_tab_bar_if_only_one_tab = true
-- Background tranparent
config.window_background_opacity = 0.85
-- boot full screen when login
-- local mux = wezterm.mux
-- wezterm.on("gui-startup", function(cmd)
-- local tab, pane, window = mux.spawn_window(cmd or {})
-- window:gui_window():toggle_fullscreen()
-- end)
-- font config
config.font = wezterm.font("SauceCodePro Nerd Font", {weight="Medium", stretch="Normal", style="Normal"})
-- font config
config.font_size = 16
config.line_height = 1.1
-- shortcut key config
local act = wezterm.action
config.keys = {
-- cmd+t to create new tab
{
key = 't',
mods = 'CMD',
action = act.SpawnTab 'CurrentPaneDomain',
},
-- cmd+d to create new pain
{
key = 'd',
mods = 'CMD',
action = wezterm.action.SplitHorizontal { domain = 'CurrentPaneDomain' },
},
{
key = '[',
mods = 'CMD',
action = act.ActivateTabRelative(-1)
},
{
key = ']',
mods = 'CMD',
action = act.ActivateTabRelative(1)
},
{
key = '[',
mods = 'CMD|SHIFT',
action = act.ActivatePaneDirection 'Left',
},
{
key = ']',
mods = 'CMD|SHIFT',
action = act.ActivatePaneDirection 'Right',
},
{
key = 'UpArrow',
mods = 'CMD|SHIFT',
action = act.ActivatePaneDirection 'Up',
},
{
key = 'DownArrow',
mods = 'CMD|SHIFT',
action = act.ActivatePaneDirection 'Down',
}
}
return config