init repo

This commit is contained in:
System administrator 2024-12-25 10:59:37 +08:00
commit 9a525dadfc
39 changed files with 2709 additions and 0 deletions

View file

@ -0,0 +1,17 @@
local wezterm = require("wezterm")
local M = {
-- front_end = 'WebGpu',
webgpu_power_preference = "HighPerformance",
}
for _, gpu in ipairs(wezterm.gui.enumerate_gpus()) do
if gpu.backend == "Vulkan" and gpu.device_type == "DiscreteGpu" then
M.webgpu_preferred_adapter = gpu
break
elseif gpu.backend == "Vulkan" and M.webgpu_preferred_adapter == nil then
M.webgpu_preferred_adapter = gpu
end
end
return M

View file

@ -0,0 +1,28 @@
local wezterm = require("wezterm")
return {
automatically_reload_config = true,
cell_width = 1.0,
audible_bell = "Disabled",
tab_bar_at_bottom = true,
use_fancy_tab_bar = false,
hide_tab_bar_if_only_one_tab = true,
window_decorations = "RESIZE|TITLE",
underline_thickness = 3.0,
enable_scroll_bar = true,
color_scheme = "MaterialOcean",
window_background_image = wezterm.config_dir .. [[/background/background.png]],
window_background_image_hsb = {
brightness = 0.02,
hue = 1.0,
saturation = 1.0,
},
window_padding = {
left = "0.5cell",
right = 0,
top = "0cell",
bottom = "0cell",
},
window_background_opacity = 0.9,
text_background_opacity = 0.6,
}

View file

@ -0,0 +1,5 @@
if require("fn").is_windows() then
return require("options.os.windows")
else
return require("options.os.other_os")
end

View file

@ -0,0 +1,30 @@
local wezterm = require("wezterm")
local fonts = {
require("fonts.firacode_nerd_font"),
require("fonts.noto_sans_cjk_sc"),
require("fonts.noto_color_emoji"),
}
return {
term = "wezterm",
font_size = 14.0,
animation_fps = 1,
max_fps = 1,
font = wezterm.font_with_fallback(fonts),
font_rules = {
{
italic = true,
font = wezterm.font_with_fallback({
require("fonts.victor_mono_nerd_font"),
}),
},
{
italic = false,
font = wezterm.font_with_fallback({
require("fonts.firacode_nerd_font"),
require("fonts.noto_sans_cjk_sc"),
}),
},
},
}

View file

@ -0,0 +1,31 @@
local wezterm = require("wezterm")
local fonts = {
require("fonts.firacode_nerd_font"),
require("fonts.segoe_ui_emoji"),
}
return {
font_size = 16.0,
animation_fps = 144,
max_fps = 144,
default_prog = {
[[pwsh]],
},
font = wezterm.font_with_fallback(fonts),
font_rules = {
{
italic = true,
font = wezterm.font_with_fallback({
require("fonts.victor_mono_nerd_font"),
}),
},
{
italic = false,
font = wezterm.font_with_fallback({
require("fonts.firacode_nerd_font"),
require("fonts.noto_sans_cjk_sc"),
}),
},
},
}