Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local wezterm = require 'wezterm'
- local config = wezterm.config_builder()
- local is_windows = wezterm.target_triple:find('windows') ~= nil
- -- ============================================================
- -- Common settings
- -- ============================================================
- config = {
- automatically_reload_config = true,
- default_cursor_style = 'BlinkingBar',
- initial_cols = 110,
- initial_rows = 28,
- line_height = 1.0,
- window_padding = {
- left = 10,
- right = 10,
- top = 5,
- bottom = 5,
- },
- font = wezterm.font("Maple Mono", { weight = "Medium" }),
- font_size = 14,
- color_scheme = 'Powershell (Gogh)',
- window_background_opacity = 0.90,
- window_close_confirmation = "NeverPrompt"
- }
- -- ============================================================
- -- Shells
- -- ============================================================
- if is_windows then
- -- Default Windows shell
- config.default_prog = {
- 'powershell.exe',
- '-NoLogo',
- }
- config.launch_menu = {
- {
- label = 'PowerShell',
- args = {
- 'powershell.exe',
- '-NoLogo',
- },
- set_environment_variables = {
- WEZTERM_SHELL = 'powershell',
- },
- },
- {
- label = 'CMD',
- args = {
- 'cmd.exe',
- },
- set_environment_variables = {
- WEZTERM_SHELL = 'cmd',
- },
- },
- }
- else
- -- Default Linux shell
- config.default_prog = {
- 'bash',
- '-l',
- }
- config.launch_menu = {
- {
- label = 'Bash',
- args = {
- 'bash',
- '-l',
- },
- set_environment_variables = {
- WEZTERM_SHELL = 'bash',
- },
- },
- {
- label = 'Zsh',
- args = {
- 'zsh',
- '-l',
- },
- set_environment_variables = {
- WEZTERM_SHELL = 'zsh',
- },
- },
- {
- label = 'Fish',
- args = {
- 'fish',
- '-l',
- },
- set_environment_variables = {
- WEZTERM_SHELL = 'fish',
- },
- },
- }
- end
- -- ============================================================
- -- Keybindings
- -- ============================================================
- config.keys = {
- {
- key = 'h',
- mods = 'ALT|SHIFT',
- action = wezterm.action.SplitHorizontal { domain = 'CurrentPaneDomain' },
- },
- {
- key = 'v',
- mods = 'ALT|SHIFT',
- action = wezterm.action.SplitVertical { domain = 'CurrentPaneDomain' },
- },
- {
- key = 'Enter',
- mods = 'CTRL|SHIFT',
- action = wezterm.action.ShowLauncherArgs {
- flags = 'FUZZY|LAUNCH_MENU_ITEMS',
- },
- },
- }
- return config
Advertisement