Files

74 lines
3.9 KiB
Ruby

# frozen_string_literal: true
# @param config [Vamp::Config]
Vamp.configure do |config|
config.leader = "space"
config.clipboard_mode = "system" # "separate" keeps ordinary y/d/c/p/P internal
config.git_blame = true # false disables current-line inline blame
config.cursor = {} # mode colors enabled; block cursor in every mode
# config.cursor = { mode_colors: false, insert: :bar, visual: :underline }
config.scroll_distance = 0 # nonnegative edge distance, or nil to center
config.scroll_step_lines = nil # Ctrl+u/d: half viewport, or a positive screen-row count
config.highlight_trailing_whitespace = false # true marks line-end whitespace in red
config.whitespace_characters = {} # opt in: { " " => "·", "\t" => "→", "\n" => "↵" }
config.whitespace_scope = "all" # or "leading" for indentation only; newline markers remain independent
config.tab_spaces = nil # opt in: 4 inserts four spaces per Tab
# config.language_tab_spaces.merge!("ruby" => 2, "makefile" => nil)
config.file_explorer_side = "right"
config.file_explorer_view = "tree"
config.file_picker_view = "tree"
config.diff_view_mode = "split" # or "unified"
config.diff_split_orientation = "vertical" # or "horizontal"
config.diff_follow_working_copy = true # false keeps the selected Working After endpoint
config.pull_request_review_requested_symbol = "🙏"
config.pull_request_approved_symbol = "👍"
config.resolve_history_layout = "columns" # or "base_below" for left/right above the base
# config.popup.command = { anchor: :bottom_left }
# config.popup.search = { anchor: :center }
# Status above, tabs, live battery and pending shell command below.
config.bar.top = {
left: [:mode, :path, :diagnostics, :selections, :count, :pending, :buffer],
center: [], right: [:language, :lsp, :position],
mode: { padding: 1, leading_edge: "", trailing_edge: "▓░" },
position: { padding: 1, leading_edge: "░▓", trailing_edge: "" }
}
config.bar.bottom = {
left: [:tabs], center: [], right: [:diff, :shell, :battery],
tabs: {
title: "{index} {view}{name}{changes}{modified}", padding: 1,
leading_edge: "░▓", trailing_edge: "▓░", first_leading_edge: ""
},
battery: { padding: 1, leading_edge: "░▓", trailing_edge: "" }
}
config.bind "ctrl+j", config.core.down, mode: config.modes.selection
config.bind "ctrl+k", config.core.up, mode: config.modes.selection
config.plugin "plugins/greeting.rb"
# Native LSP is disabled by default; install a server and explicitly opt in.
# config.lsp["rust"] = true # built-in rust-analyzer preset
# config.lsp["ruby"] = true # built-in Solargraph stdio preset (gem install solargraph)
# config.lsp["python"] = true # built-in ty + Ruff stack (install both separately)
# config.lsp["typst"] = true # built-in Tinymist LSP preset (install tinymist separately)
# config.lsp["my-language"] = {
# command: ["my-language-server", "--stdio"], extensions: ["myl"],
# initialization_options: {}, settings: {}
# }
# config.bind "leader d", config.core.lsp.definition
# config.bind "leader D", config.core.lsp.diagnostics
# config.bind "K", config.core.lsp.hover
config.bind "g", "greet"
config.bind "leader g", "greet"
config.bind "leader q", config.core.quit
config.bind "leader d", config.core.diff
config.bind "ctrl+r", config.core.redo
config.bind "leader r", config.core.repeat_last_edit
config.bind "ctrl+c", config.core.normal, mode: config.modes.insert
config.bind "ctrl+f", config.core.search
config.bind "ctrl+c", config.core.normal, mode: config.modes.search
config.bind "ctrl+w", config.core.word_next
config.bind "ctrl+b", config.core.word_previous, mode: config.modes.insert
config.bind "ctrl+v", config.core.select
config.bind "ctrl+c", config.core.copy, mode: config.modes.visual
config.bind "ctrl+x", config.core.cut, mode: config.modes.visual
config.bind "ctrl+r", config.core.change, mode: config.modes.visual
end