Compare commits
7 Commits
b07e2a2699
...
ab7595214f
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
ab7595214f | ||
|
|
2b5a09d902 | ||
|
|
9e32359f2d | ||
|
|
e73ffa5e75 | ||
|
|
b1a6b49f99 | ||
|
|
b27b0cce5a | ||
|
|
dcba4841fd |
@@ -1,6 +1,10 @@
|
|||||||
|
Xft.dpi: 96
|
||||||
Xcursor.size: 16
|
Xcursor.size: 16
|
||||||
! URxvt
|
! URxvt
|
||||||
URxvt.font:xft:xos4 Terminus:size=8
|
URxvt.font:xft:IBM Plex Mono:size=8
|
||||||
|
URxvt.boldFont:xft:IBM Plex Mono:size=8
|
||||||
|
URxvt.italicFont:xft:IBM Plex Mono:size=8
|
||||||
|
URxvt.boldItalicFont:xft:IBM Plex Mono:size=8
|
||||||
URxvt.secondaryScreen: 1
|
URxvt.secondaryScreen: 1
|
||||||
URxvt.secondaryScroll: 0
|
URxvt.secondaryScroll: 0
|
||||||
|
|
||||||
|
|||||||
@@ -26,9 +26,10 @@
|
|||||||
#window:
|
#window:
|
||||||
# Window dimensions (changes require restart)
|
# Window dimensions (changes require restart)
|
||||||
#
|
#
|
||||||
# Number of lines/columns (not pixels) in the terminal. The number of columns
|
# Number of lines/columns (not pixels) in the terminal. Both lines and columns
|
||||||
# must be at least `2`, while using a value of `0` for columns and lines will
|
# must be non-zero for this to take effect. The number of columns must be at
|
||||||
# fall back to the window manager's recommended size.
|
# least `2`, while using a value of `0` for columns and lines will fall back
|
||||||
|
# to the window manager's recommended size
|
||||||
#dimensions:
|
#dimensions:
|
||||||
# columns: 0
|
# columns: 0
|
||||||
# lines: 0
|
# lines: 0
|
||||||
@@ -93,11 +94,12 @@
|
|||||||
# General application class
|
# General application class
|
||||||
#general: Alacritty
|
#general: Alacritty
|
||||||
|
|
||||||
# GTK theme variant (Linux/BSD only)
|
# Decorations theme variant (Linux/BSD only)
|
||||||
#
|
#
|
||||||
# Override the variant of the GTK theme. Commonly supported values are `dark`
|
# Override the variant of the GTK theme/Wayland client side decorations.
|
||||||
# and `light`. Set this to `None` to use the default theme variant.
|
# Commonly supported values are `dark` and `light`. Set this to `None` to use
|
||||||
#gtk_theme_variant: None
|
# the default theme variant.
|
||||||
|
#decorations_theme_variant: None
|
||||||
|
|
||||||
#scrolling:
|
#scrolling:
|
||||||
# Maximum number of lines in the scrollback buffer.
|
# Maximum number of lines in the scrollback buffer.
|
||||||
@@ -172,12 +174,6 @@ font:
|
|||||||
# x: 0
|
# x: 0
|
||||||
# y: 0
|
# y: 0
|
||||||
|
|
||||||
# Thin stroke font rendering (macOS only)
|
|
||||||
#
|
|
||||||
# Thin strokes are suitable for retina displays, but for non-retina screens
|
|
||||||
# it is recommended to set `use_thin_strokes` to `false`.
|
|
||||||
#use_thin_strokes: true
|
|
||||||
|
|
||||||
# Use built-in font for box drawing characters.
|
# Use built-in font for box drawing characters.
|
||||||
#
|
#
|
||||||
# If `true`, Alacritty will use a custom built-in font for box drawing
|
# If `true`, Alacritty will use a custom built-in font for box drawing
|
||||||
@@ -237,11 +233,7 @@ font:
|
|||||||
# foreground: '#ffffff'
|
# foreground: '#ffffff'
|
||||||
# background: '#000000'
|
# background: '#000000'
|
||||||
|
|
||||||
#bar:
|
# Keyboard hints
|
||||||
# background: '#c5c8c6'
|
|
||||||
# foreground: '#1d1f21'
|
|
||||||
|
|
||||||
# Keyboard regex hints
|
|
||||||
#hints:
|
#hints:
|
||||||
# First character in the hint label
|
# First character in the hint label
|
||||||
#
|
#
|
||||||
@@ -269,6 +261,15 @@ font:
|
|||||||
# foreground: None
|
# foreground: None
|
||||||
# background: None
|
# background: None
|
||||||
|
|
||||||
|
# Footer bar
|
||||||
|
#
|
||||||
|
# Color used for the footer bar on the bottom, used by search regex input,
|
||||||
|
# hyperlink URI preview, etc.
|
||||||
|
#
|
||||||
|
#footer_bar:
|
||||||
|
# background: '#c5c8c6'
|
||||||
|
# foreground: '#1d1f21'
|
||||||
|
|
||||||
# Selection colors
|
# Selection colors
|
||||||
#
|
#
|
||||||
# Colors which should be used to draw the selection area.
|
# Colors which should be used to draw the selection area.
|
||||||
@@ -446,6 +447,11 @@ colors:
|
|||||||
# Cursor blinking interval in milliseconds.
|
# Cursor blinking interval in milliseconds.
|
||||||
#blink_interval: 750
|
#blink_interval: 750
|
||||||
|
|
||||||
|
# Time after which cursor stops blinking, in seconds.
|
||||||
|
#
|
||||||
|
# Specifying '0' will disable timeout for blinking.
|
||||||
|
#blink_timeout: 5
|
||||||
|
|
||||||
# If this is `true`, the cursor will be rendered as a hollow box when the
|
# If this is `true`, the cursor will be rendered as a hollow box when the
|
||||||
# window is not focused.
|
# window is not focused.
|
||||||
#unfocused_hollow: true
|
#unfocused_hollow: true
|
||||||
@@ -464,8 +470,7 @@ colors:
|
|||||||
# shell.
|
# shell.
|
||||||
#
|
#
|
||||||
# Default:
|
# Default:
|
||||||
# - (macOS) /bin/bash --login
|
# - (Linux/BSD/macOS) `$SHELL` or the user's login shell, if `$SHELL` is unset
|
||||||
# - (Linux/BSD) user login shell
|
|
||||||
# - (Windows) powershell
|
# - (Windows) powershell
|
||||||
#shell:
|
#shell:
|
||||||
# program: /bin/bash
|
# program: /bin/bash
|
||||||
@@ -496,18 +501,22 @@ colors:
|
|||||||
# If this is `true`, the cursor is temporarily hidden when typing.
|
# If this is `true`, the cursor is temporarily hidden when typing.
|
||||||
#hide_when_typing: false
|
#hide_when_typing: false
|
||||||
|
|
||||||
# Regex hints
|
# Hints
|
||||||
#
|
#
|
||||||
# Terminal hints can be used to find text in the visible part of the terminal
|
# Terminal hints can be used to find text or hyperlink in the visible part of
|
||||||
# and pipe it to other applications.
|
# the terminal and pipe it to other applications.
|
||||||
hints:
|
hints:
|
||||||
# Keys used for the hint labels.
|
# Keys used for the hint labels.
|
||||||
#alphabet: "jfkdls;ahgurieowpq"
|
#alphabet: "jfkdls;ahgurieowpq"
|
||||||
|
|
||||||
# List with all available hints
|
# List with all available hints
|
||||||
#
|
#
|
||||||
# Each hint must have a `regex` and either an `action` or a `command` field.
|
# Each hint must have any of `regex` or `hyperlinks` field and either an
|
||||||
# The fields `mouse`, `binding` and `post_processing` are optional.
|
# `action` or a `command` field. The fields `mouse`, `binding` and
|
||||||
|
# `post_processing` are optional.
|
||||||
|
#
|
||||||
|
# The `hyperlinks` option will cause OSC 8 escape sequence hyperlinks to be
|
||||||
|
# highlighted.
|
||||||
#
|
#
|
||||||
# The fields `command`, `binding.key`, `binding.mods`, `binding.mode` and
|
# The fields `command`, `binding.key`, `binding.mods`, `binding.mode` and
|
||||||
# `mouse.mods` accept the same values as they do in the `key_bindings` section.
|
# `mouse.mods` accept the same values as they do in the `key_bindings` section.
|
||||||
@@ -517,7 +526,8 @@ hints:
|
|||||||
#
|
#
|
||||||
# If the `post_processing` field is set to `true`, heuristics will be used to
|
# If the `post_processing` field is set to `true`, heuristics will be used to
|
||||||
# shorten the match if there are characters likely not to be part of the hint
|
# shorten the match if there are characters likely not to be part of the hint
|
||||||
# (e.g. a trailing `.`). This is most useful for URIs.
|
# (e.g. a trailing `.`). This is most useful for URIs and applies only to
|
||||||
|
# `regex` matches.
|
||||||
#
|
#
|
||||||
# Values for `action`:
|
# Values for `action`:
|
||||||
# - Copy
|
# - Copy
|
||||||
@@ -529,13 +539,14 @@ hints:
|
|||||||
# - MoveViModeCursor
|
# - MoveViModeCursor
|
||||||
# Move the vi mode cursor to the beginning of the hint.
|
# Move the vi mode cursor to the beginning of the hint.
|
||||||
enabled:
|
enabled:
|
||||||
- regex: "(ipfs:|ipns:|magnet:|mailto:|gemini:|gopher:|https:|http:|news:|file:|git:|ssh:|ftp:)\
|
- regex: "(ipfs:|ipns:|magnet:|mailto:|gemini:|gopher:|https:|http:|news:|file:|git:|ssh:|ftp:)\
|
||||||
[^\u0000-\u001F\u007F-\u009F<>\"\\s{-}\\^⟨⟩`]+"
|
[^\u0000-\u001F\u007F-\u009F<>\"\\s{-}\\^⟨⟩`]+"
|
||||||
command: xdg-open
|
hyperlinks: true
|
||||||
post_processing: true
|
command: xdg-open
|
||||||
mouse:
|
post_processing: true
|
||||||
enabled: true
|
mouse:
|
||||||
mods: Control
|
enabled: true
|
||||||
|
mods: Control
|
||||||
# binding:
|
# binding:
|
||||||
# key: U
|
# key: U
|
||||||
# mods: Control|Shift
|
# mods: Control|Shift
|
||||||
@@ -659,6 +670,8 @@ hints:
|
|||||||
# - ToggleBlockSelection
|
# - ToggleBlockSelection
|
||||||
# - ToggleSemanticSelection
|
# - ToggleSemanticSelection
|
||||||
# Toggle semantic selection based on `selection.semantic_escape_chars`.
|
# Toggle semantic selection based on `selection.semantic_escape_chars`.
|
||||||
|
# - CenterAroundViCursor
|
||||||
|
# Center view around vi mode cursor
|
||||||
#
|
#
|
||||||
# - Vi mode exclusive cursor motion actions:
|
# - Vi mode exclusive cursor motion actions:
|
||||||
#
|
#
|
||||||
@@ -785,9 +798,9 @@ key_bindings:
|
|||||||
#- { key: Copy, action: Copy }
|
#- { key: Copy, action: Copy }
|
||||||
#- { key: L, mods: Control, action: ClearLogNotice }
|
#- { key: L, mods: Control, action: ClearLogNotice }
|
||||||
#- { key: L, mods: Control, mode: ~Vi|~Search, chars: "\x0c" }
|
#- { key: L, mods: Control, mode: ~Vi|~Search, chars: "\x0c" }
|
||||||
#- { key: PageUp, mods: Shift, mode: ~Alt, action: ScrollPageUp, }
|
#- { key: PageUp, mods: Shift, mode: ~Alt, action: ScrollPageUp }
|
||||||
#- { key: PageDown, mods: Shift, mode: ~Alt, action: ScrollPageDown }
|
#- { key: PageDown, mods: Shift, mode: ~Alt, action: ScrollPageDown }
|
||||||
#- { key: Home, mods: Shift, mode: ~Alt, action: ScrollToTop, }
|
#- { key: Home, mods: Shift, mode: ~Alt, action: ScrollToTop }
|
||||||
#- { key: End, mods: Shift, mode: ~Alt, action: ScrollToBottom }
|
#- { key: End, mods: Shift, mode: ~Alt, action: ScrollToBottom }
|
||||||
|
|
||||||
# Vi Mode
|
# Vi Mode
|
||||||
@@ -813,6 +826,7 @@ key_bindings:
|
|||||||
#- { key: V, mods: Control, mode: Vi|~Search, action: ToggleBlockSelection }
|
#- { key: V, mods: Control, mode: Vi|~Search, action: ToggleBlockSelection }
|
||||||
#- { key: V, mods: Alt, mode: Vi|~Search, action: ToggleSemanticSelection }
|
#- { key: V, mods: Alt, mode: Vi|~Search, action: ToggleSemanticSelection }
|
||||||
#- { key: Return, mode: Vi|~Search, action: Open }
|
#- { key: Return, mode: Vi|~Search, action: Open }
|
||||||
|
#- { key: Z, mode: Vi|~Search, action: CenterAroundViCursor }
|
||||||
#- { key: K, mode: Vi|~Search, action: Up }
|
#- { key: K, mode: Vi|~Search, action: Up }
|
||||||
#- { key: J, mode: Vi|~Search, action: Down }
|
#- { key: J, mode: Vi|~Search, action: Down }
|
||||||
#- { key: H, mode: Vi|~Search, action: Left }
|
#- { key: H, mode: Vi|~Search, action: Left }
|
||||||
|
|||||||
@@ -6,6 +6,7 @@ alias .5='cd ../../../../..'
|
|||||||
|
|
||||||
alias v='nvim'
|
alias v='nvim'
|
||||||
alias n='nnn -e'
|
alias n='nnn -e'
|
||||||
|
alias pdf='zathura'
|
||||||
|
|
||||||
if type -q exa
|
if type -q exa
|
||||||
alias lsl="exa -l -g --icons"
|
alias lsl="exa -l -g --icons"
|
||||||
|
|||||||
@@ -4,6 +4,8 @@ set -x MANPAGER "sh -c 'col -bx | bat -l man -p'"
|
|||||||
set -x fish_prompt_pwd_dir_length 1
|
set -x fish_prompt_pwd_dir_length 1
|
||||||
set -x fish_greeting ''
|
set -x fish_greeting ''
|
||||||
set fish_complete_path $fish_complete_path /usr/share/fish/competions
|
set fish_complete_path $fish_complete_path /usr/share/fish/competions
|
||||||
|
set -x JAVA_HOME /usr/lib/jvm/java-11-openjdk-amd64
|
||||||
|
set -x JIRA_API_TOKEN NDE2ODEyOTM5OTI2Ontw1zkanbJ8sAFMDUI1Y0QxOH7d
|
||||||
|
|
||||||
# This file is run by all fish instances.
|
# This file is run by all fish instances.
|
||||||
# To include configuration only for login shells, use
|
# To include configuration only for login shells, use
|
||||||
|
|||||||
@@ -12,8 +12,9 @@
|
|||||||
set_from_resource $main_color i3wm.color1 #fdff00
|
set_from_resource $main_color i3wm.color1 #fdff00
|
||||||
set_from_resource $secondary_color i3wm.color0 #98d1ce
|
set_from_resource $secondary_color i3wm.color0 #98d1ce
|
||||||
set_from_resource $bg_color i3wm.color4 #0c1014
|
set_from_resource $bg_color i3wm.color4 #0c1014
|
||||||
set $output_main DP-0
|
set $output_main DP-0.1
|
||||||
set $output_secondary DVI-D-0
|
set $output_secondary DP-0.3
|
||||||
|
set $refresh_i3status killall -SIGUSR1 i3status-rs
|
||||||
|
|
||||||
# Font for window titles. Will also be used by the bar unless a different font
|
# Font for window titles. Will also be used by the bar unless a different font
|
||||||
# is used in the bar {} block below.
|
# is used in the bar {} block below.
|
||||||
@@ -246,8 +247,6 @@ client.focused $main_color $main_color $bg_color #2e9ef4
|
|||||||
client.focused_inactive $main_color $bg_color $main_color #2e9ef4
|
client.focused_inactive $main_color $bg_color $main_color #2e9ef4
|
||||||
client.unfocused $bg_color $bg_color $main_color #2e9ef4
|
client.unfocused $bg_color $bg_color $main_color #2e9ef4
|
||||||
|
|
||||||
focus_on_window_activation focus
|
|
||||||
|
|
||||||
for_window [instance="fontpreview"] floating enable
|
for_window [instance="fontpreview"] floating enable
|
||||||
for_window [class="^Chrome$" title=" - Chromium$"] border none
|
for_window [class="^Chrome$" title=" - Chromium$"] border none
|
||||||
for_window [class="firefox"] border none
|
for_window [class="firefox"] border none
|
||||||
@@ -259,8 +258,11 @@ assign [class="com-mathworks-util-PostVMInit" title="^Fig"] $ws10
|
|||||||
new_window pixel 1
|
new_window pixel 1
|
||||||
new_float pixel 3
|
new_float pixel 3
|
||||||
hide_edge_borders smart
|
hide_edge_borders smart
|
||||||
|
#focus_on_window_activation focus
|
||||||
focus_on_window_activation urgent
|
focus_on_window_activation urgent
|
||||||
|
|
||||||
workspace_auto_back_and_forth yes
|
workspace_auto_back_and_forth yes
|
||||||
|
|
||||||
popup_during_fullscreen smart
|
popup_during_fullscreen smart
|
||||||
|
|
||||||
|
focus_wrapping false
|
||||||
|
|||||||
@@ -1,6 +1,11 @@
|
|||||||
theme = "solarized-dark"
|
theme = "solarized-dark"
|
||||||
icons = "awesome"
|
icons = "awesome"
|
||||||
|
|
||||||
|
[[block]]
|
||||||
|
block = "custom"
|
||||||
|
command = "echo vpn:(vpn | head -1 | cut -d: -f 2)"
|
||||||
|
interval = 5
|
||||||
|
|
||||||
[[block]]
|
[[block]]
|
||||||
block = "disk_space"
|
block = "disk_space"
|
||||||
path = "/home"
|
path = "/home"
|
||||||
|
|||||||
Binary file not shown.
|
Before Width: | Height: | Size: 292 KiB After Width: | Height: | Size: 520 KiB |
5
.config/nvim/after/available/airline.rc.lua
Normal file
5
.config/nvim/after/available/airline.rc.lua
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
vim.g.airline_theme = 'minimalist'
|
||||||
|
vim.g.airline_powerline_fonts = 1
|
||||||
|
vim.g.airline_stl_path_style = 'short'
|
||||||
|
vim.g.airline_highlighting_cache = 1
|
||||||
|
vim.g.airline#extensions#searchcount#enabled = 0
|
||||||
18
.config/nvim/after/available/boole.rc.lua
Normal file
18
.config/nvim/after/available/boole.rc.lua
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
require('boole').setup{
|
||||||
|
mappings = {
|
||||||
|
increment = '<C-a>',
|
||||||
|
decrement = '<C-x>'
|
||||||
|
},
|
||||||
|
-- User defined loops
|
||||||
|
additions = {
|
||||||
|
{'Foo', 'Bar'},
|
||||||
|
{'tic', 'tac', 'toe'},
|
||||||
|
{'light', 'dark'},
|
||||||
|
{'phaseOne', 'phaseTwo', 'phaseThree'},
|
||||||
|
{'PhaseOne', 'PhaseTwo', 'PhaseThree'},
|
||||||
|
{'Enable', 'Disable'},
|
||||||
|
{'ENABLE', 'DISABLE'},
|
||||||
|
{'enable', 'disable'},
|
||||||
|
{'zero', 'one', 'two', 'three', 'four', 'five', 'six', 'seven', 'eight', 'nine'},
|
||||||
|
},
|
||||||
|
}
|
||||||
1
.config/nvim/after/available/comment.rc.lua
Normal file
1
.config/nvim/after/available/comment.rc.lua
Normal file
@@ -0,0 +1 @@
|
|||||||
|
require('Comment').setup()
|
||||||
35
.config/nvim/after/available/context.rc.lua
Normal file
35
.config/nvim/after/available/context.rc.lua
Normal file
@@ -0,0 +1,35 @@
|
|||||||
|
-- " Configuration for context.vim
|
||||||
|
-- "" Disable context.vim on json files
|
||||||
|
-- ""let g:context_filetype_blacklist = ["json", "log"]
|
||||||
|
require'treesitter-context'.setup{
|
||||||
|
enable = true, -- Enable this plugin (Can be enabled/disabled later via commands)
|
||||||
|
throttle = true, -- Throttles plugin updates (may improve performance)
|
||||||
|
max_lines = 0, -- How many lines the window should span. Values <= 0 mean no limit.
|
||||||
|
patterns = { -- Match patterns for TS nodes. These get wrapped to match at word boundaries.
|
||||||
|
-- For all filetypes
|
||||||
|
-- Note that setting an entry here replaces all other patterns for this entry.
|
||||||
|
-- By setting the 'default' entry below, you can control which nodes you want to
|
||||||
|
-- appear in the context window.
|
||||||
|
default = {
|
||||||
|
'class',
|
||||||
|
'function',
|
||||||
|
'method',
|
||||||
|
'for',
|
||||||
|
'while',
|
||||||
|
'if',
|
||||||
|
'switch',
|
||||||
|
-- 'case',
|
||||||
|
},
|
||||||
|
-- Example for a specific filetype.
|
||||||
|
-- If a pattern is missing, *open a PR* so everyone can benefit.
|
||||||
|
rust = {
|
||||||
|
'impl_item',
|
||||||
|
},
|
||||||
|
},
|
||||||
|
exact_patterns = {
|
||||||
|
-- Example for a specific filetype with Lua patterns
|
||||||
|
-- Treat patterns.rust as a Lua pattern (i.e "^impl_item$" will
|
||||||
|
-- exactly match "impl_item" only)
|
||||||
|
rust = true,
|
||||||
|
}
|
||||||
|
}
|
||||||
1
.config/nvim/after/available/crates.rc.lua
Normal file
1
.config/nvim/after/available/crates.rc.lua
Normal file
@@ -0,0 +1 @@
|
|||||||
|
require('crates').setup()
|
||||||
1
.config/nvim/after/available/debugprint.rc.lua
Normal file
1
.config/nvim/after/available/debugprint.rc.lua
Normal file
@@ -0,0 +1 @@
|
|||||||
|
require('debugprint').setup()
|
||||||
1
.config/nvim/after/available/digraphs.rc.vim
Normal file
1
.config/nvim/after/available/digraphs.rc.vim
Normal file
@@ -0,0 +1 @@
|
|||||||
|
inoremap <C-k><C-k> <Cmd>lua require'better-digraphs'.digraphs("i")<CR>
|
||||||
159
.config/nvim/after/available/dressing.rc.lua
Normal file
159
.config/nvim/after/available/dressing.rc.lua
Normal file
@@ -0,0 +1,159 @@
|
|||||||
|
require('dressing').setup({
|
||||||
|
input = {
|
||||||
|
-- Set to false to disable the vim.ui.input implementation
|
||||||
|
enabled = true,
|
||||||
|
|
||||||
|
-- Default prompt string
|
||||||
|
default_prompt = "Input:",
|
||||||
|
|
||||||
|
-- Can be 'left', 'right', or 'center'
|
||||||
|
prompt_align = "left",
|
||||||
|
|
||||||
|
-- When true, <Esc> will close the modal
|
||||||
|
insert_only = true,
|
||||||
|
|
||||||
|
-- When true, input will start in insert mode.
|
||||||
|
start_in_insert = true,
|
||||||
|
|
||||||
|
-- These are passed to nvim_open_win
|
||||||
|
anchor = "SW",
|
||||||
|
border = "rounded",
|
||||||
|
-- 'editor' and 'win' will default to being centered
|
||||||
|
relative = "cursor",
|
||||||
|
|
||||||
|
-- These can be integers or a float between 0 and 1 (e.g. 0.4 for 40%)
|
||||||
|
prefer_width = 40,
|
||||||
|
width = nil,
|
||||||
|
-- min_width and max_width can be a list of mixed types.
|
||||||
|
-- min_width = {20, 0.2} means "the greater of 20 columns or 20% of total"
|
||||||
|
max_width = { 140, 0.9 },
|
||||||
|
min_width = { 20, 0.2 },
|
||||||
|
|
||||||
|
buf_options = {},
|
||||||
|
win_options = {
|
||||||
|
-- Window transparency (0-100)
|
||||||
|
winblend = 10,
|
||||||
|
-- Disable line wrapping
|
||||||
|
wrap = false,
|
||||||
|
},
|
||||||
|
|
||||||
|
-- Set to `false` to disable
|
||||||
|
mappings = {
|
||||||
|
n = {
|
||||||
|
["<Esc>"] = "Close",
|
||||||
|
["<CR>"] = "Confirm",
|
||||||
|
},
|
||||||
|
i = {
|
||||||
|
["<C-c>"] = "Close",
|
||||||
|
["<CR>"] = "Confirm",
|
||||||
|
["<Up>"] = "HistoryPrev",
|
||||||
|
["<Down>"] = "HistoryNext",
|
||||||
|
},
|
||||||
|
},
|
||||||
|
|
||||||
|
override = function(conf)
|
||||||
|
-- This is the config that will be passed to nvim_open_win.
|
||||||
|
-- Change values here to customize the layout
|
||||||
|
return conf
|
||||||
|
end,
|
||||||
|
|
||||||
|
-- see :help dressing_get_config
|
||||||
|
get_config = nil,
|
||||||
|
},
|
||||||
|
select = {
|
||||||
|
-- Set to false to disable the vim.ui.select implementation
|
||||||
|
enabled = true,
|
||||||
|
|
||||||
|
-- Priority list of preferred vim.select implementations
|
||||||
|
backend = { "telescope", "fzf_lua", "fzf", "builtin", "nui" },
|
||||||
|
|
||||||
|
-- Trim trailing `:` from prompt
|
||||||
|
trim_prompt = true,
|
||||||
|
|
||||||
|
-- Options for telescope selector
|
||||||
|
-- These are passed into the telescope picker directly. Can be used like:
|
||||||
|
-- telescope = require('telescope.themes').get_ivy({...})
|
||||||
|
telescope = nil,
|
||||||
|
|
||||||
|
-- Options for fzf selector
|
||||||
|
fzf = {
|
||||||
|
window = {
|
||||||
|
width = 0.5,
|
||||||
|
height = 0.4,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
|
||||||
|
-- Options for fzf_lua selector
|
||||||
|
fzf_lua = {
|
||||||
|
winopts = {
|
||||||
|
width = 0.5,
|
||||||
|
height = 0.4,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
|
||||||
|
-- Options for nui Menu
|
||||||
|
nui = {
|
||||||
|
position = "50%",
|
||||||
|
size = nil,
|
||||||
|
relative = "editor",
|
||||||
|
border = {
|
||||||
|
style = "rounded",
|
||||||
|
},
|
||||||
|
buf_options = {
|
||||||
|
swapfile = false,
|
||||||
|
filetype = "DressingSelect",
|
||||||
|
},
|
||||||
|
win_options = {
|
||||||
|
winblend = 10,
|
||||||
|
},
|
||||||
|
max_width = 80,
|
||||||
|
max_height = 40,
|
||||||
|
min_width = 40,
|
||||||
|
min_height = 10,
|
||||||
|
},
|
||||||
|
|
||||||
|
-- Options for built-in selector
|
||||||
|
builtin = {
|
||||||
|
-- These are passed to nvim_open_win
|
||||||
|
anchor = "NW",
|
||||||
|
border = "rounded",
|
||||||
|
-- 'editor' and 'win' will default to being centered
|
||||||
|
relative = "editor",
|
||||||
|
|
||||||
|
buf_options = {},
|
||||||
|
win_options = {
|
||||||
|
-- Window transparency (0-100)
|
||||||
|
winblend = 10,
|
||||||
|
},
|
||||||
|
|
||||||
|
-- These can be integers or a float between 0 and 1 (e.g. 0.4 for 40%)
|
||||||
|
-- the min_ and max_ options can be a list of mixed types.
|
||||||
|
-- max_width = {140, 0.8} means "the lesser of 140 columns or 80% of total"
|
||||||
|
width = nil,
|
||||||
|
max_width = { 140, 0.8 },
|
||||||
|
min_width = { 40, 0.2 },
|
||||||
|
height = nil,
|
||||||
|
max_height = 0.9,
|
||||||
|
min_height = { 10, 0.2 },
|
||||||
|
|
||||||
|
-- Set to `false` to disable
|
||||||
|
mappings = {
|
||||||
|
["<Esc>"] = "Close",
|
||||||
|
["<C-c>"] = "Close",
|
||||||
|
["<CR>"] = "Confirm",
|
||||||
|
},
|
||||||
|
|
||||||
|
override = function(conf)
|
||||||
|
-- This is the config that will be passed to nvim_open_win.
|
||||||
|
-- Change values here to customize the layout
|
||||||
|
return conf
|
||||||
|
end,
|
||||||
|
},
|
||||||
|
|
||||||
|
-- Used to override format_item. See :help dressing-format
|
||||||
|
format_item_override = {},
|
||||||
|
|
||||||
|
-- see :help dressing_get_config
|
||||||
|
get_config = nil,
|
||||||
|
},
|
||||||
|
})
|
||||||
1
.config/nvim/after/available/femaco.rc.lua
Normal file
1
.config/nvim/after/available/femaco.rc.lua
Normal file
@@ -0,0 +1 @@
|
|||||||
|
require('femaco').setup()
|
||||||
45
.config/nvim/after/available/fterm.rc.lua
Normal file
45
.config/nvim/after/available/fterm.rc.lua
Normal file
@@ -0,0 +1,45 @@
|
|||||||
|
require'FTerm'.setup({
|
||||||
|
-- Filetype of the terminal buffer
|
||||||
|
ft = 'FTerm',
|
||||||
|
|
||||||
|
-- Command to run inside the terminal. It could be a `string` or `table`
|
||||||
|
cmd = os.getenv('SHELL'),
|
||||||
|
|
||||||
|
-- Neovim's native window border. See `:h nvim_open_win` for more configuration options.
|
||||||
|
border = 'double',
|
||||||
|
|
||||||
|
-- Close the terminal as soon as shell/command exits.
|
||||||
|
-- Disabling this will mimic the native terminal behaviour.
|
||||||
|
auto_close = true,
|
||||||
|
|
||||||
|
-- Highlight group for the terminal. See `:h winhl`
|
||||||
|
hl = 'Normal',
|
||||||
|
|
||||||
|
-- Transparency of the floating window. See `:h winblend`
|
||||||
|
blend = 0,
|
||||||
|
|
||||||
|
-- Object containing the terminal window dimensions.
|
||||||
|
-- The value for each field should be between `0` and `1`
|
||||||
|
dimensions = {
|
||||||
|
height = 0.9, -- Height of the terminal window
|
||||||
|
width = 0.9, -- Width of the terminal window
|
||||||
|
x = 0.5, -- X axis of the terminal window
|
||||||
|
y = 0.5, -- Y axis of the terminal window
|
||||||
|
},
|
||||||
|
|
||||||
|
-- Callback invoked when the terminal exits.
|
||||||
|
-- See `:h jobstart-options`
|
||||||
|
on_exit = nil,
|
||||||
|
|
||||||
|
-- Callback invoked when the terminal emits stdout data.
|
||||||
|
-- See `:h jobstart-options`
|
||||||
|
on_stdout = nil,
|
||||||
|
|
||||||
|
-- Callback invoked when the terminal emits stderr data.
|
||||||
|
-- See `:h jobstart-options`
|
||||||
|
on_stderr = nil,
|
||||||
|
})
|
||||||
|
|
||||||
|
-- Example keybindings
|
||||||
|
vim.keymap.set('n', '<leader>i', '<CMD>lua require("FTerm").toggle()<CR>')
|
||||||
|
vim.keymap.set('t', '<leader>i', '<CMD>lua require("FTerm").toggle()<CR>')
|
||||||
104
.config/nvim/after/available/gitsigns.rc.lua
Normal file
104
.config/nvim/after/available/gitsigns.rc.lua
Normal file
@@ -0,0 +1,104 @@
|
|||||||
|
require('gitsigns').setup {
|
||||||
|
signs = {
|
||||||
|
add = {hl = 'GitSignsAdd' , text = '│', numhl='GitSignsAddNr' , linehl='GitSignsAddLn'},
|
||||||
|
change = {hl = 'GitSignsChange', text = '│', numhl='GitSignsChangeNr', linehl='GitSignsChangeLn'},
|
||||||
|
delete = {hl = 'GitSignsDelete', text = '_', numhl='GitSignsDeleteNr', linehl='GitSignsDeleteLn'},
|
||||||
|
topdelete = {hl = 'GitSignsDelete', text = '‾', numhl='GitSignsDeleteNr', linehl='GitSignsDeleteLn'},
|
||||||
|
changedelete = {hl = 'GitSignsChange', text = '~', numhl='GitSignsChangeNr', linehl='GitSignsChangeLn'},
|
||||||
|
},
|
||||||
|
signcolumn = true, -- Toggle with `:Gitsigns toggle_signs`
|
||||||
|
numhl = true, -- Toggle with `:Gitsigns toggle_numhl`
|
||||||
|
linehl = false, -- Toggle with `:Gitsigns toggle_linehl`
|
||||||
|
word_diff = false, -- Toggle with `:Gitsigns toggle_word_diff`
|
||||||
|
--keymaps = {
|
||||||
|
-- -- Default keymap options
|
||||||
|
-- noremap = true,
|
||||||
|
|
||||||
|
-- ['n ]c'] = { expr = true, "&diff ? ']c' : '<cmd>Gitsigns next_hunk<CR>'"},
|
||||||
|
-- ['n [c'] = { expr = true, "&diff ? '[c' : '<cmd>Gitsigns prev_hunk<CR>'"},
|
||||||
|
|
||||||
|
-- ['n <leader>hs'] = '<cmd>Gitsigns stage_hunk<CR>',
|
||||||
|
-- ['v <leader>hs'] = '<cmd>Gitsigns stage_hunk<CR>',
|
||||||
|
-- ['n <leader>hu'] = '<cmd>Gitsigns undo_stage_hunk<CR>',
|
||||||
|
-- ['n <leader>hr'] = '<cmd>Gitsigns reset_hunk<CR>',
|
||||||
|
-- ['v <leader>hr'] = '<cmd>:Gitsigns reset_hunk<CR>',
|
||||||
|
-- ['n <leader>hR'] = '<cmd>Gitsigns reset_buffer<CR>',
|
||||||
|
-- ['n <leader>hp'] = '<cmd>Gitsigns preview_hunk<CR>',
|
||||||
|
-- ['n <leader>hb'] = '<cmd>lua require"gitsigns".blame_line{full=true}<CR>',
|
||||||
|
-- ['n <leader>hS'] = '<cmd>Gitsigns stage_buffer<CR>',
|
||||||
|
-- ['n <leader>hU'] = '<cmd>Gitsigns reset_buffer_index<CR>',
|
||||||
|
|
||||||
|
-- -- Text objects
|
||||||
|
-- ['o ih'] = '<cmd><C-U>Gitsigns select_hunk<CR>',
|
||||||
|
-- ['x ih'] = '<cmd><C-U>Gitsigns select_hunk<CR>'
|
||||||
|
--},
|
||||||
|
on_attach = function(bufnr)
|
||||||
|
local gs = package.loaded.gitsigns
|
||||||
|
|
||||||
|
local function map(mode, l, r, opts)
|
||||||
|
opts = opts or {}
|
||||||
|
opts.buffer = bufnr
|
||||||
|
vim.keymap.set(mode, l, r, opts)
|
||||||
|
end
|
||||||
|
|
||||||
|
-- Navigation
|
||||||
|
map('n', ']c', function()
|
||||||
|
if vim.wo.diff then return ']c' end
|
||||||
|
vim.schedule(function() gs.next_hunk() end)
|
||||||
|
return '<Ignore>'
|
||||||
|
end, {expr=true})
|
||||||
|
|
||||||
|
map('n', '[c', function()
|
||||||
|
if vim.wo.diff then return '[c' end
|
||||||
|
vim.schedule(function() gs.prev_hunk() end)
|
||||||
|
return '<Ignore>'
|
||||||
|
end, {expr=true})
|
||||||
|
|
||||||
|
-- Actions
|
||||||
|
map({'n', 'v'}, '<leader>hs', '<cmd>Gitsigns stage_hunk<CR>')
|
||||||
|
map({'n', 'v'}, '<leader>hr', '<cmd>Gitsigns reset_hunk<CR>')
|
||||||
|
map('n', '<leader>hS', gs.stage_buffer)
|
||||||
|
map('n', '<leader>hu', gs.undo_stage_hunk)
|
||||||
|
map('n', '<leader>hR', gs.reset_buffer)
|
||||||
|
map('n', '<leader>hp', gs.preview_hunk)
|
||||||
|
map('n', '<leader>hb', function() gs.blame_line{full=true} end)
|
||||||
|
map('n', '<leader>tb', gs.toggle_current_line_blame)
|
||||||
|
map('n', '<leader>hd', gs.diffthis)
|
||||||
|
map('n', '<leader>hD', function() gs.diffthis('~') end)
|
||||||
|
map('n', '<leader>td', gs.toggle_deleted)
|
||||||
|
|
||||||
|
-- Text object
|
||||||
|
map({'o', 'x'}, 'ih', ':<C-U>Gitsigns select_hunk<CR>')
|
||||||
|
end,
|
||||||
|
|
||||||
|
watch_gitdir = {
|
||||||
|
interval = 1000,
|
||||||
|
follow_files = true
|
||||||
|
},
|
||||||
|
attach_to_untracked = true,
|
||||||
|
current_line_blame = true, -- Toggle with `:Gitsigns toggle_current_line_blame`
|
||||||
|
current_line_blame_opts = {
|
||||||
|
virt_text = true,
|
||||||
|
virt_text_pos = 'eol', -- 'eol' | 'overlay' | 'right_align'
|
||||||
|
delay = 1000,
|
||||||
|
ignore_whitespace = true,
|
||||||
|
},
|
||||||
|
current_line_blame_formatter_opts = {
|
||||||
|
relative_time = false
|
||||||
|
},
|
||||||
|
sign_priority = 6,
|
||||||
|
update_debounce = 100,
|
||||||
|
status_formatter = nil, -- Use default
|
||||||
|
max_file_length = 40000,
|
||||||
|
preview_config = {
|
||||||
|
-- Options passed to nvim_open_win
|
||||||
|
border = 'single',
|
||||||
|
style = 'minimal',
|
||||||
|
relative = 'cursor',
|
||||||
|
row = 0,
|
||||||
|
col = 1
|
||||||
|
},
|
||||||
|
yadm = {
|
||||||
|
enable = true
|
||||||
|
},
|
||||||
|
}
|
||||||
11
.config/nvim/after/available/hlslens.rc.vim
Normal file
11
.config/nvim/after/available/hlslens.rc.vim
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
"noremap <silent> n <Cmd>execute('normal! ' . v:count1 . 'n')<CR>
|
||||||
|
" \<Cmd>lua require('hlslens').start()<CR>
|
||||||
|
"noremap <silent> N <Cmd>execute('normal! ' . v:count1 . 'N')<CR>
|
||||||
|
" \<Cmd>lua require('hlslens').start()<CR>
|
||||||
|
"noremap * *<Cmd>lua require('hlslens').start()<CR>
|
||||||
|
"noremap # #<Cmd>lua require('hlslens').start()<CR>
|
||||||
|
"noremap g* g*<Cmd>lua require('hlslens').start()<CR>
|
||||||
|
"noremap g# g#<Cmd>lua require('hlslens').start()<CR>
|
||||||
|
"
|
||||||
|
"" use : instead of <Cmd>
|
||||||
|
"nnoremap <silent> <leader>l :noh<CR>
|
||||||
5
.config/nvim/after/available/icons.rc.lua
Normal file
5
.config/nvim/after/available/icons.rc.lua
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
require("icon-picker")
|
||||||
|
|
||||||
|
local opts = { noremap = true, silent = true }
|
||||||
|
|
||||||
|
vim.keymap.set("n", "<leader>o", "<cmd>PickIcons<cr>", opts)
|
||||||
42
.config/nvim/after/available/illuminate.rc.lua
Normal file
42
.config/nvim/after/available/illuminate.rc.lua
Normal file
@@ -0,0 +1,42 @@
|
|||||||
|
--require('illuminate').configure({
|
||||||
|
-- large_file_cutoff = 3000
|
||||||
|
--})
|
||||||
|
|
||||||
|
HIGHLIGHT = 'highlight'
|
||||||
|
vim.api.nvim_create_augroup(HIGHLIGHT, { clear = true })
|
||||||
|
|
||||||
|
require('murmur').setup {
|
||||||
|
cursor_rgb = 'darkgreen', -- default to '#393939'
|
||||||
|
max_len = 80, -- maximum word-length to highlight
|
||||||
|
-- disable_on_lines = 2000, -- to prevent lagging on large files. Default to 2000 lines.
|
||||||
|
exclude_filetypes = {'log'},
|
||||||
|
callbacks = {
|
||||||
|
-- to trigger the close_events of vim.diagnostic.open_float.
|
||||||
|
function ()
|
||||||
|
-- Close floating diag. and make it triggerable again.
|
||||||
|
vim.cmd('doautocmd InsertEnter')
|
||||||
|
vim.w.diag_shown = false
|
||||||
|
end,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
vim.api.nvim_create_autocmd('CursorHold', {
|
||||||
|
group = HIGHLIGHT,
|
||||||
|
pattern = '*',
|
||||||
|
callback = function ()
|
||||||
|
-- skip when a float-win already exists.
|
||||||
|
if vim.w.diag_shown then return end
|
||||||
|
|
||||||
|
-- open float-win when hovering on a cursor-word.
|
||||||
|
if vim.w.cursor_word ~= '' then
|
||||||
|
vim.diagnostic.open_float(nil, {
|
||||||
|
focusable = true,
|
||||||
|
close_events = { 'InsertEnter' },
|
||||||
|
border = 'rounded',
|
||||||
|
source = 'always',
|
||||||
|
prefix = ' ',
|
||||||
|
scope = 'cursor',
|
||||||
|
})
|
||||||
|
vim.w.diag_shown = true
|
||||||
|
end
|
||||||
|
end
|
||||||
|
})
|
||||||
22
.config/nvim/after/available/indent.rc.lua
Normal file
22
.config/nvim/after/available/indent.rc.lua
Normal file
@@ -0,0 +1,22 @@
|
|||||||
|
--require("indent_blankline").setup {
|
||||||
|
-- char = "",
|
||||||
|
-- show_current_context = true,
|
||||||
|
-- --show_current_context_start = true,
|
||||||
|
-- space_char_blankline = " ",
|
||||||
|
-- char_highlight_list = {
|
||||||
|
-- "IndentBlanklineIndent1",
|
||||||
|
-- "IndentBlanklineIndent2",
|
||||||
|
-- "IndentBlanklineIndent3",
|
||||||
|
-- "IndentBlanklineIndent4",
|
||||||
|
-- "IndentBlanklineIndent5",
|
||||||
|
-- "IndentBlanklineIndent6",
|
||||||
|
-- },
|
||||||
|
-- space_char_highlight_list = {
|
||||||
|
-- "IndentBlanklineIndent1",
|
||||||
|
-- "IndentBlanklineIndent2",
|
||||||
|
-- "IndentBlanklineIndent3",
|
||||||
|
-- "IndentBlanklineIndent4",
|
||||||
|
-- "IndentBlanklineIndent5",
|
||||||
|
-- "IndentBlanklineIndent6",
|
||||||
|
-- },
|
||||||
|
--}
|
||||||
5
.config/nvim/after/available/iswap.rc.lua
Normal file
5
.config/nvim/after/available/iswap.rc.lua
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
require('iswap').setup{}
|
||||||
|
|
||||||
|
local opts = { noremap=true, silent=true }
|
||||||
|
vim.api.nvim_set_keymap('n', 'ta', '<cmd>ISwapWith<cr>', opts)
|
||||||
|
vim.api.nvim_set_keymap('n', 'tn', '<cmd>ISwap<cr>', opts)
|
||||||
29
.config/nvim/after/available/knap.rc.lua
Normal file
29
.config/nvim/after/available/knap.rc.lua
Normal file
@@ -0,0 +1,29 @@
|
|||||||
|
local gknapsettings = {
|
||||||
|
htmloutputext = "html",
|
||||||
|
htmltohtml = "touch %outputfile%",
|
||||||
|
htmltohtmlviewerlaunch = "google-chrome-beta %outputfile%",
|
||||||
|
htmltohtmlviewerrefresh = "none",
|
||||||
|
mdoutputext = "html",
|
||||||
|
mdtohtml = "pandoc --standalone %docroot% -o %outputfile%",
|
||||||
|
mdtohtmlviewerlaunch = "google-chrome-beta %outputfile%",
|
||||||
|
mdtohtmlviewerrefresh = "none",
|
||||||
|
mdtopdf = "pandoc %docroot% -o %outputfile%",
|
||||||
|
mdtopdfviewerlaunch = "sioyek %outputfile%",
|
||||||
|
mdtopdfviewerrefresh = "none",
|
||||||
|
markdownoutputext = "html",
|
||||||
|
markdowntohtml = "pandoc --standalone %docroot% -o %outputfile%",
|
||||||
|
markdowntohtmlviewerlaunch = "google-chrome-beta %outputfile%",
|
||||||
|
markdowntohtmlviewerrefresh = "none",
|
||||||
|
markdowntopdf = "pandoc %docroot% -o %outputfile%",
|
||||||
|
markdowntopdfviewerlaunch = "sioyek %outputfile%",
|
||||||
|
markdowntopdfviewerrefresh = "none",
|
||||||
|
texoutputext = "pdf",
|
||||||
|
textopdf = "pdflatex -interaction=batchmode -halt-on-error -synctex=1 %docroot%",
|
||||||
|
textopdfviewerlaunch = "sioyek --inverse-search 'nvim --headless -es --cmd \"lua require('\"'\"'knaphelper'\"'\"').relayjump('\"'\"'%servername%'\"'\"','\"'\"'%1'\"'\"',%2,%3)\"' --reuse-instance %outputfile%",
|
||||||
|
textopdfviewerrefresh = "none",
|
||||||
|
textopdfforwardjump = "sioyek --inverse-search 'nvim --headless -es --cmd \"lua require('\"'\"'knaphelper'\"'\"').relayjump('\"'\"'%servername%'\"'\"','\"'\"'%1'\"'\"',%2,%3)\"' --reuse-instance --forward-search-file %srcfile% --forward-search-line %line% %outputfile%",
|
||||||
|
textopdfshorterror = "A=%outputfile% ; LOGFILE=\"${A%.pdf}.log\" ; rubber-info \"$LOGFILE\" 2>&1 | head -n 1",
|
||||||
|
delay = 250
|
||||||
|
}
|
||||||
|
|
||||||
|
vim.g.knap_settings = gknapsettings
|
||||||
150
.config/nvim/after/available/lspconfig.rc.lua
Normal file
150
.config/nvim/after/available/lspconfig.rc.lua
Normal file
@@ -0,0 +1,150 @@
|
|||||||
|
local nvim_lsp = require('lspconfig')
|
||||||
|
local coq = require('coq')
|
||||||
|
local clangd_extensions = require('clangd_extensions')
|
||||||
|
local lsp_signature = require('lsp_signature')
|
||||||
|
|
||||||
|
-- Mappings.
|
||||||
|
local opts = { noremap=true, silent=true }
|
||||||
|
vim.api.nvim_set_keymap('n', '<leader>e', '<cmd>lua vim.diagnostic.open_float()<CR>', opts)
|
||||||
|
vim.api.nvim_set_keymap('n', '[d', '<cmd>lua vim.diagnostic.goto_prev()<CR>', opts)
|
||||||
|
vim.api.nvim_set_keymap('n', ']d', '<cmd>lua vim.diagnostic.goto_next()<CR>', opts)
|
||||||
|
vim.api.nvim_set_keymap('n', '<leader>E', '<cmd>lua vim.diagnostic.set_loclist()<CR>', opts)
|
||||||
|
vim.api.nvim_set_keymap("n", "<leader>q", "<cmd>lua vim.lsp.buf.format{ async = true }<CR>", opts)
|
||||||
|
|
||||||
|
-- Use an on_attach function to only map the following keys
|
||||||
|
-- after the language server attaches to the current buffer
|
||||||
|
local on_attach = function(client, bufnr)
|
||||||
|
--Enable completion triggered by <c-x><c-o>
|
||||||
|
vim.api.nvim_buf_set_option(bufnr, 'omnifunc', 'v:lua.vim.lsp.omnifunc')
|
||||||
|
|
||||||
|
---- See `:help vim.lsp.*` for documentation on any of the below functions
|
||||||
|
vim.api.nvim_buf_set_keymap(bufnr, 'n', 'gD', '<cmd>lua vim.lsp.buf.declaration()<CR>', opts)
|
||||||
|
vim.api.nvim_buf_set_keymap(bufnr, 'n', 'gd', '<cmd>lua vim.lsp.buf.definition()<CR>', opts)
|
||||||
|
vim.api.nvim_buf_set_keymap(bufnr, 'n', 'K', '<cmd>lua vim.lsp.buf.hover()<CR>', opts)
|
||||||
|
vim.api.nvim_buf_set_keymap(bufnr, 'n', 'gi', '<cmd>lua vim.lsp.buf.implementation()<CR>', opts)
|
||||||
|
vim.api.nvim_buf_set_keymap(bufnr, 'n', '<C-k>', '<cmd>lua vim.lsp.buf.signature_help()<CR>', opts)
|
||||||
|
--vim.api.nvim_buf_set_keymap(bufnr, 'n', '<space>wa', '<cmd>lua vim.lsp.buf.add_workspace_folder()<CR>', opts)
|
||||||
|
--vim.api.nvim_buf_set_keymap(bufnr, 'n', '<space>wr', '<cmd>lua vim.lsp.buf.remove_workspace_folder()<CR>', opts)
|
||||||
|
--vim.api.nvim_buf_set_keymap(bufnr, 'n', '<space>wl', '<cmd>lua print(vim.inspect(vim.lsp.buf.list_workspace_folders()))<CR>', opts)
|
||||||
|
vim.api.nvim_buf_set_keymap(bufnr, 'n', '<leader>D', '<cmd>lua vim.lsp.buf.type_definition()<CR>', opts)
|
||||||
|
vim.api.nvim_buf_set_keymap(bufnr, 'n', '<leader>rn', '<cmd>lua vim.lsp.buf.rename()<CR>', opts)
|
||||||
|
vim.api.nvim_buf_set_keymap(bufnr, 'n', '<leader>ca', '<cmd>lua vim.lsp.buf.code_action()<CR>', opts)
|
||||||
|
vim.api.nvim_buf_set_keymap(bufnr, 'n', 'gr', '<cmd>lua vim.lsp.buf.references()<CR>', opts)
|
||||||
|
vim.api.nvim_buf_set_keymap(bufnr, 'n', '<F6>', '<cmd>ClangdSwitchSourceHeader<cr>', opts)
|
||||||
|
|
||||||
|
-- require'illuminate'.on_attach(client)
|
||||||
|
require'virtualtypes'.on_attach()
|
||||||
|
require'lsp_signature'.on_attach({
|
||||||
|
floating_window = true,
|
||||||
|
floating_window_above_cur_line = false,
|
||||||
|
floating_window_off_x = 500,
|
||||||
|
floating_window_off_y = -5,
|
||||||
|
})
|
||||||
|
end
|
||||||
|
|
||||||
|
local signs = {
|
||||||
|
{ name = "DiagnosticSignError", text = "" },
|
||||||
|
{ name = "DiagnosticSignWarn", text = "" },
|
||||||
|
{ name = "DiagnosticSignHint", text = "" },
|
||||||
|
{ name = "DiagnosticSignInfo", text = "" },
|
||||||
|
}
|
||||||
|
|
||||||
|
for _, sign in ipairs(signs) do
|
||||||
|
vim.fn.sign_define(sign.name, { texthl = sign.name, text = sign.text, numhl = "" })
|
||||||
|
end
|
||||||
|
|
||||||
|
vim.lsp.handlers["textDocument/publishDiagnostics"] = vim.lsp.with(
|
||||||
|
vim.lsp.diagnostic.on_publish_diagnostics, {
|
||||||
|
signs = {
|
||||||
|
active = signs,
|
||||||
|
--severity_limit = 'info',
|
||||||
|
},
|
||||||
|
severity_sort = true,
|
||||||
|
underline = false,
|
||||||
|
update_in_insert = false,
|
||||||
|
--virtual_text = {
|
||||||
|
-- spacing = 40,
|
||||||
|
-- severity_limit = 'Warning',
|
||||||
|
--},
|
||||||
|
virtual_text = false,
|
||||||
|
}
|
||||||
|
)
|
||||||
|
|
||||||
|
nvim_lsp.groovyls.setup (coq.lsp_ensure_capabilities({
|
||||||
|
cmd = { "java", "-jar", "/home/kmcr/tools/groovy-language-server/build/libs/groovy-language-server-all.jar" },
|
||||||
|
on_attach = on_attach,
|
||||||
|
on_publish_diagnostics = diagnostic_handler,
|
||||||
|
capabilities = vim.lsp.protocol.make_client_capabilities(),
|
||||||
|
})
|
||||||
|
)
|
||||||
|
|
||||||
|
-- nvim_lsp.ccls.setup(
|
||||||
|
-- coq.lsp_ensure_capabilities({
|
||||||
|
-- init_options = {
|
||||||
|
-- compilationDatabaseDirectory = ".";
|
||||||
|
-- index = {
|
||||||
|
-- threads = 0;
|
||||||
|
-- },
|
||||||
|
-- clang = {
|
||||||
|
-- excludeArgs = { "-frounding-math"} ;
|
||||||
|
-- },
|
||||||
|
-- },
|
||||||
|
-- root_dir = nvim_lsp.util.root_pattern("compile_commands.json"),
|
||||||
|
-- on_attach = on_attach,
|
||||||
|
-- on_publish_diagnostics = diagnostic_handler,
|
||||||
|
-- capabilities = cmp.update_capabilities(vim.lsp.protocol.make_client_capabilities()),
|
||||||
|
-- flags = {
|
||||||
|
-- debounce_text_changes = 150,
|
||||||
|
-- }}
|
||||||
|
-- )
|
||||||
|
-- )
|
||||||
|
|
||||||
|
clangd_extensions.setup(coq.lsp_ensure_capabilities({
|
||||||
|
server = {
|
||||||
|
on_attach = on_attach,
|
||||||
|
root_pattern = {
|
||||||
|
'.clangd',
|
||||||
|
'.clang-tidy',
|
||||||
|
'.clang-format',
|
||||||
|
'compile_commands.json',
|
||||||
|
'compile_flags.txt',
|
||||||
|
'configure.ac',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
inlay_hints = {
|
||||||
|
max_len_align = true,
|
||||||
|
max_len_align_padding = 3,
|
||||||
|
right_align = true,
|
||||||
|
}
|
||||||
|
}))
|
||||||
|
|
||||||
|
nvim_lsp.pylsp.setup(coq.lsp_ensure_capabilities({
|
||||||
|
settings = {
|
||||||
|
pylint = {
|
||||||
|
enabled = false
|
||||||
|
},
|
||||||
|
pyflakes = {
|
||||||
|
enabled = false,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
flags = {
|
||||||
|
debounce_text_changes = 150,
|
||||||
|
},
|
||||||
|
on_attach = on_attach,
|
||||||
|
on_publish_diagnostics = diagnostic_handler,
|
||||||
|
capabilities = vim.lsp.protocol.make_client_capabilities(),
|
||||||
|
}))
|
||||||
|
|
||||||
|
-- Use a loop to conveniently call 'setup' on multiple servers and
|
||||||
|
-- map buffer local keybindings when the language server attaches
|
||||||
|
local servers = { "cmake", "rust_analyzer", "bashls" }
|
||||||
|
for _, lsp in ipairs(servers) do
|
||||||
|
nvim_lsp[lsp].setup(coq.lsp_ensure_capabilities({
|
||||||
|
on_attach = on_attach,
|
||||||
|
on_publish_diagnostics = diagnostic_handler,
|
||||||
|
capabilities = vim.lsp.protocol.make_client_capabilities(),
|
||||||
|
flags = {
|
||||||
|
debounce_text_changes = 150,
|
||||||
|
}
|
||||||
|
}))
|
||||||
|
end
|
||||||
222
.config/nvim/after/available/lualine.rc.lua
Normal file
222
.config/nvim/after/available/lualine.rc.lua
Normal file
@@ -0,0 +1,222 @@
|
|||||||
|
-- Eviline config for lualine
|
||||||
|
-- Author: shadmansaleh
|
||||||
|
-- Credit: glepnir
|
||||||
|
local lualine = require('lualine')
|
||||||
|
|
||||||
|
-- Color table for highlights
|
||||||
|
-- stylua: ignore
|
||||||
|
local colors = {
|
||||||
|
bg = '#202328',
|
||||||
|
fg = '#bbc2cf',
|
||||||
|
yellow = '#ECBE7B',
|
||||||
|
cyan = '#008080',
|
||||||
|
darkblue = '#081633',
|
||||||
|
green = '#98be65',
|
||||||
|
orange = '#FF8800',
|
||||||
|
violet = '#a9a1e1',
|
||||||
|
magenta = '#c678dd',
|
||||||
|
blue = '#51afef',
|
||||||
|
red = '#ec5f67',
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
local conditions = {
|
||||||
|
buffer_not_empty = function()
|
||||||
|
return vim.fn.empty(vim.fn.expand('%:t')) ~= 1
|
||||||
|
end,
|
||||||
|
hide_in_width = function()
|
||||||
|
return vim.fn.winwidth(0) > 80
|
||||||
|
end,
|
||||||
|
check_git_workspace = function()
|
||||||
|
local filepath = vim.fn.expand('%:p:h')
|
||||||
|
local gitdir = vim.fn.finddir('.git', filepath .. ';')
|
||||||
|
return gitdir and #gitdir > 0 and #gitdir < #filepath
|
||||||
|
end,
|
||||||
|
}
|
||||||
|
|
||||||
|
-- Config
|
||||||
|
local config = {
|
||||||
|
options = {
|
||||||
|
-- Disable sections and component separators
|
||||||
|
component_separators = '',
|
||||||
|
section_separators = '',
|
||||||
|
theme = {
|
||||||
|
-- We are going to use lualine_c an lualine_x as left and
|
||||||
|
-- right section. Both are highlighted by c theme . So we
|
||||||
|
-- are just setting default looks o statusline
|
||||||
|
normal = { c = { fg = colors.fg, bg = colors.bg } },
|
||||||
|
inactive = { c = { fg = colors.fg, bg = colors.bg } },
|
||||||
|
},
|
||||||
|
},
|
||||||
|
sections = {
|
||||||
|
-- these are to remove the defaults
|
||||||
|
lualine_a = {},
|
||||||
|
lualine_b = {},
|
||||||
|
lualine_y = {},
|
||||||
|
lualine_z = {},
|
||||||
|
-- These will be filled later
|
||||||
|
lualine_c = {},
|
||||||
|
lualine_x = {},
|
||||||
|
},
|
||||||
|
inactive_sections = {
|
||||||
|
-- these are to remove the defaults
|
||||||
|
lualine_a = {},
|
||||||
|
lualine_b = {},
|
||||||
|
lualine_y = {},
|
||||||
|
lualine_z = {},
|
||||||
|
lualine_c = {},
|
||||||
|
lualine_x = {},
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
-- Inserts a component in lualine_c at left section
|
||||||
|
local function ins_left(component)
|
||||||
|
table.insert(config.sections.lualine_c, component)
|
||||||
|
end
|
||||||
|
|
||||||
|
-- Inserts a component in lualine_x ot right section
|
||||||
|
local function ins_right(component)
|
||||||
|
table.insert(config.sections.lualine_x, component)
|
||||||
|
end
|
||||||
|
|
||||||
|
ins_left {
|
||||||
|
function()
|
||||||
|
return '▊'
|
||||||
|
end,
|
||||||
|
color = { fg = colors.blue }, -- Sets highlighting of component
|
||||||
|
padding = { left = 0, right = 1 }, -- We don't need space before this
|
||||||
|
}
|
||||||
|
|
||||||
|
ins_left {
|
||||||
|
-- mode component
|
||||||
|
function()
|
||||||
|
return ''
|
||||||
|
end,
|
||||||
|
color = function()
|
||||||
|
-- auto change color according to neovims mode
|
||||||
|
local mode_color = {
|
||||||
|
n = colors.red,
|
||||||
|
i = colors.green,
|
||||||
|
v = colors.blue,
|
||||||
|
[''] = colors.blue,
|
||||||
|
V = colors.blue,
|
||||||
|
c = colors.magenta,
|
||||||
|
no = colors.red,
|
||||||
|
s = colors.orange,
|
||||||
|
S = colors.orange,
|
||||||
|
[''] = colors.orange,
|
||||||
|
ic = colors.yellow,
|
||||||
|
R = colors.violet,
|
||||||
|
Rv = colors.violet,
|
||||||
|
cv = colors.red,
|
||||||
|
ce = colors.red,
|
||||||
|
r = colors.cyan,
|
||||||
|
rm = colors.cyan,
|
||||||
|
['r?'] = colors.cyan,
|
||||||
|
['!'] = colors.red,
|
||||||
|
t = colors.red,
|
||||||
|
}
|
||||||
|
return { fg = mode_color[vim.fn.mode()] }
|
||||||
|
end,
|
||||||
|
padding = { right = 1 },
|
||||||
|
}
|
||||||
|
|
||||||
|
ins_left {
|
||||||
|
-- filesize component
|
||||||
|
'filesize',
|
||||||
|
cond = conditions.buffer_not_empty,
|
||||||
|
}
|
||||||
|
|
||||||
|
ins_left {
|
||||||
|
'filename',
|
||||||
|
cond = conditions.buffer_not_empty,
|
||||||
|
color = { fg = colors.magenta, gui = 'bold' },
|
||||||
|
}
|
||||||
|
|
||||||
|
ins_left { 'location' }
|
||||||
|
|
||||||
|
ins_left { 'progress', color = { fg = colors.fg, gui = 'bold' } }
|
||||||
|
|
||||||
|
ins_left {
|
||||||
|
'diagnostics',
|
||||||
|
sources = { 'nvim_diagnostic' },
|
||||||
|
symbols = { error = ' ', warn = ' ', info = ' ' },
|
||||||
|
diagnostics_color = {
|
||||||
|
color_error = { fg = colors.red },
|
||||||
|
color_warn = { fg = colors.yellow },
|
||||||
|
color_info = { fg = colors.cyan },
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
-- Insert mid section. You can make any number of sections in neovim :)
|
||||||
|
-- for lualine it's any number greater then 2
|
||||||
|
ins_left {
|
||||||
|
function()
|
||||||
|
return '%='
|
||||||
|
end,
|
||||||
|
}
|
||||||
|
|
||||||
|
ins_left {
|
||||||
|
-- Lsp server name .
|
||||||
|
function()
|
||||||
|
local msg = 'No Active Lsp'
|
||||||
|
local buf_ft = vim.api.nvim_buf_get_option(0, 'filetype')
|
||||||
|
local clients = vim.lsp.get_active_clients()
|
||||||
|
if next(clients) == nil then
|
||||||
|
return msg
|
||||||
|
end
|
||||||
|
for _, client in ipairs(clients) do
|
||||||
|
local filetypes = client.config.filetypes
|
||||||
|
if filetypes and vim.fn.index(filetypes, buf_ft) ~= -1 then
|
||||||
|
return client.name
|
||||||
|
end
|
||||||
|
end
|
||||||
|
return msg
|
||||||
|
end,
|
||||||
|
icon = ' LSP:',
|
||||||
|
color = { fg = '#ffffff', gui = 'bold' },
|
||||||
|
}
|
||||||
|
|
||||||
|
-- Add components to right sections
|
||||||
|
ins_right {
|
||||||
|
'o:encoding', -- option component same as &encoding in viml
|
||||||
|
fmt = string.upper, -- I'm not sure why it's upper case either ;)
|
||||||
|
cond = conditions.hide_in_width,
|
||||||
|
color = { fg = colors.green, gui = 'bold' },
|
||||||
|
}
|
||||||
|
|
||||||
|
ins_right {
|
||||||
|
'fileformat',
|
||||||
|
fmt = string.upper,
|
||||||
|
icons_enabled = true, -- I think icons are cool but Eviline doesn't have them. sigh
|
||||||
|
color = { fg = colors.green, gui = 'bold' },
|
||||||
|
}
|
||||||
|
|
||||||
|
ins_right {
|
||||||
|
'branch',
|
||||||
|
icon = '',
|
||||||
|
color = { fg = colors.violet, gui = 'bold' },
|
||||||
|
}
|
||||||
|
|
||||||
|
ins_right {
|
||||||
|
'diff',
|
||||||
|
-- Is it me or the symbol for modified us really weird
|
||||||
|
symbols = { added = ' ', modified = '柳 ', removed = ' ' },
|
||||||
|
diff_color = {
|
||||||
|
added = { fg = colors.green },
|
||||||
|
modified = { fg = colors.orange },
|
||||||
|
removed = { fg = colors.red },
|
||||||
|
},
|
||||||
|
cond = conditions.hide_in_width,
|
||||||
|
}
|
||||||
|
|
||||||
|
ins_right {
|
||||||
|
function()
|
||||||
|
return '▊'
|
||||||
|
end,
|
||||||
|
color = { fg = colors.blue },
|
||||||
|
padding = { left = 1 },
|
||||||
|
}
|
||||||
|
|
||||||
|
-- Now don't forget to initialize lualine
|
||||||
|
lualine.setup(config)
|
||||||
1
.config/nvim/after/available/md-preview.rc.vim
Normal file
1
.config/nvim/after/available/md-preview.rc.vim
Normal file
@@ -0,0 +1 @@
|
|||||||
|
let g:mkdp_filetypes = ['markdown', 'plantuml']
|
||||||
4
.config/nvim/after/available/minimap.rc.lua
Normal file
4
.config/nvim/after/available/minimap.rc.lua
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
local codewindow = require('codewindow')
|
||||||
|
|
||||||
|
codewindow.setup()
|
||||||
|
codewindow.apply_default_keybinds()
|
||||||
88
.config/nvim/after/available/mkdnflow.rc.lua
Normal file
88
.config/nvim/after/available/mkdnflow.rc.lua
Normal file
@@ -0,0 +1,88 @@
|
|||||||
|
require('mkdnflow').setup({
|
||||||
|
modules = {
|
||||||
|
bib = true,
|
||||||
|
buffers = true,
|
||||||
|
conceal = true,
|
||||||
|
cursor = true,
|
||||||
|
folds = true,
|
||||||
|
links = true,
|
||||||
|
lists = true,
|
||||||
|
maps = true,
|
||||||
|
paths = true,
|
||||||
|
tables = true
|
||||||
|
},
|
||||||
|
filetypes = {md = true, rmd = true, markdown = true},
|
||||||
|
create_dirs = true,
|
||||||
|
perspective = {
|
||||||
|
priority = 'first',
|
||||||
|
fallback = 'current',
|
||||||
|
root_tell = false,
|
||||||
|
nvim_wd_heel = true
|
||||||
|
},
|
||||||
|
wrap = false,
|
||||||
|
bib = {
|
||||||
|
default_path = nil,
|
||||||
|
find_in_root = true
|
||||||
|
},
|
||||||
|
silent = false,
|
||||||
|
links = {
|
||||||
|
style = 'markdown',
|
||||||
|
conceal = false,
|
||||||
|
implicit_extension = nil,
|
||||||
|
transform_implicit = false,
|
||||||
|
transform_explicit = function(text)
|
||||||
|
text = text:gsub(" ", "-")
|
||||||
|
text = text:lower()
|
||||||
|
text = os.date('%Y-%m-%d_')..text
|
||||||
|
return(text)
|
||||||
|
end
|
||||||
|
},
|
||||||
|
to_do = {
|
||||||
|
symbols = {' ', '-', 'X'},
|
||||||
|
update_parents = true,
|
||||||
|
not_started = ' ',
|
||||||
|
in_progress = '-',
|
||||||
|
complete = 'X'
|
||||||
|
},
|
||||||
|
tables = {
|
||||||
|
trim_whitespace = true,
|
||||||
|
format_on_move = true,
|
||||||
|
auto_extend_rows = false,
|
||||||
|
auto_extend_cols = false
|
||||||
|
},
|
||||||
|
mappings = {
|
||||||
|
MkdnEnter = {{'n', 'v'}, '<CR>'},
|
||||||
|
MkdnTab = false,
|
||||||
|
MkdnSTab = false,
|
||||||
|
MkdnNextLink = {'n', '<Tab>'},
|
||||||
|
MkdnPrevLink = {'n', '<S-Tab>'},
|
||||||
|
MkdnNextHeading = {'n', ']]'},
|
||||||
|
MkdnPrevHeading = {'n', '[['},
|
||||||
|
MkdnGoBack = {'n', '<BS>'},
|
||||||
|
MkdnGoForward = {'n', '<Del>'},
|
||||||
|
MkdnFollowLink = false, -- see MkdnEnter
|
||||||
|
MkdnDestroyLink = {'n', '<M-CR>'},
|
||||||
|
MkdnTagSpan = {'v', '<M-CR>'},
|
||||||
|
MkdnMoveSource = {'n', '<F2>'},
|
||||||
|
MkdnYankAnchorLink = {'n', 'ya'},
|
||||||
|
MkdnYankFileAnchorLink = {'n', 'yfa'},
|
||||||
|
MkdnIncreaseHeading = {'n', '+'},
|
||||||
|
MkdnDecreaseHeading = {'n', '-'},
|
||||||
|
MkdnToggleToDo = {{'n', 'v'}, '<C-Space>'},
|
||||||
|
MkdnNewListItem = false,
|
||||||
|
MkdnNewListItemBelowInsert = {'n', 'o'},
|
||||||
|
MkdnNewListItemAboveInsert = {'n', 'O'},
|
||||||
|
MkdnExtendList = false,
|
||||||
|
MkdnUpdateNumbering = {'n', '<leader>nn'},
|
||||||
|
MkdnTableNextCell = {'i', '<Tab>'},
|
||||||
|
MkdnTablePrevCell = {'i', '<S-Tab>'},
|
||||||
|
MkdnTableNextRow = false,
|
||||||
|
MkdnTablePrevRow = {'i', '<M-CR>'},
|
||||||
|
MkdnTableNewRowBelow = {'n', '<leader>ir'},
|
||||||
|
MkdnTableNewRowAbove = {'n', '<leader>iR'},
|
||||||
|
MkdnTableNewColAfter = {'n', '<leader>ic'},
|
||||||
|
MkdnTableNewColBefore = {'n', '<leader>iC'},
|
||||||
|
MkdnFoldSection = {'n', '<leader>f'},
|
||||||
|
MkdnUnfoldSection = {'n', '<leader>F'}
|
||||||
|
}
|
||||||
|
})
|
||||||
22
.config/nvim/after/available/neogen.rc.lua
Normal file
22
.config/nvim/after/available/neogen.rc.lua
Normal file
@@ -0,0 +1,22 @@
|
|||||||
|
require("neogen").setup({
|
||||||
|
--snippet_engine = 'ultisnips',
|
||||||
|
input_after_comment = true,
|
||||||
|
})
|
||||||
|
|
||||||
|
-- {
|
||||||
|
-- { nil, "///!", { no_results = true, type = { "func", "file", "class" } } },
|
||||||
|
-- { nil, "///! @file", { no_results = true, type = { "file" } } },
|
||||||
|
-- { nil, "///! * @brief $1", { no_results = true, type = { "func", "file", "class" } } },
|
||||||
|
-- { nil, "", { no_results = true, type = { "func", "file", "class" } } },
|
||||||
|
-- { nil, "", { no_results = true, type = { "file" } } },
|
||||||
|
--
|
||||||
|
-- { nil, "/**", { type = { "func", "class", "type" } } },
|
||||||
|
-- { i.ClassName, " * @class %s", { type = { "class" } } },
|
||||||
|
-- { i.Type, " * @typedef %s", { type = { "type" } } },
|
||||||
|
-- { nil, " * @brief $1", { type = { "func", "class", "type" } } },
|
||||||
|
-- { nil, " *", { type = { "func", "class", "type" } } },
|
||||||
|
-- { i.Tparam, " * @tparam %s $1" },
|
||||||
|
-- { i.Parameter, " * @param %s $1" },
|
||||||
|
-- { i.Return, " * @return $1" },
|
||||||
|
-- { nil, " */", { type = { "func", "class", "type" } } },
|
||||||
|
-- }
|
||||||
14
.config/nvim/after/available/neorg.rc.lua
Normal file
14
.config/nvim/after/available/neorg.rc.lua
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
require('neorg').setup {
|
||||||
|
load = {
|
||||||
|
["core.defaults"] = {},
|
||||||
|
["core.norg.dirman"] = {
|
||||||
|
config = {
|
||||||
|
workspaces = {
|
||||||
|
work = "~/notes/work",
|
||||||
|
home = "~/notes/home",
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
["core.norg.concealer"] = {},
|
||||||
|
}
|
||||||
|
}
|
||||||
13
.config/nvim/after/available/neoscroll.rc.lua
Normal file
13
.config/nvim/after/available/neoscroll.rc.lua
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
-- require('neoscroll').setup({
|
||||||
|
-- -- All these keys will be mapped to their corresponding default scrolling animation
|
||||||
|
-- mappings = {'<C-u>', '<C-d>', '<C-b>', '<C-f>',
|
||||||
|
-- '<C-y>', '<C-e>', 'zt', 'zz', 'zb'},
|
||||||
|
-- hide_cursor = true, -- Hide cursor while scrolling
|
||||||
|
-- stop_eof = true, -- Stop at <EOF> when scrolling downwards
|
||||||
|
-- use_local_scrolloff = false, -- Use the local scope of scrolloff instead of the global scope
|
||||||
|
-- respect_scrolloff = false, -- Stop scrolling when the cursor reaches the scrolloff margin of the file
|
||||||
|
-- cursor_scrolls_alone = true, -- The cursor will keep on scrolling even if the window cannot scroll further
|
||||||
|
-- easing_function = nil, -- Default easing function
|
||||||
|
-- pre_hook = nil, -- Function to run before the scrolling animation starts
|
||||||
|
-- post_hook = nil, -- Function to run after the scrolling animation ends
|
||||||
|
-- })
|
||||||
73
.config/nvim/after/available/nvim-cmp.rc.lua
Normal file
73
.config/nvim/after/available/nvim-cmp.rc.lua
Normal file
@@ -0,0 +1,73 @@
|
|||||||
|
-- Setup nvim-cmp.
|
||||||
|
--local cmp = require'cmp'
|
||||||
|
--
|
||||||
|
--cmp.setup({
|
||||||
|
-- snippet = {
|
||||||
|
-- expand = function(args)
|
||||||
|
-- -- For `vsnip` user.
|
||||||
|
-- -- vim.fn["vsnip#anonymous"](args.body)
|
||||||
|
--
|
||||||
|
-- -- For `luasnip` user.
|
||||||
|
-- -- require('luasnip').lsp_expand(args.body)
|
||||||
|
--
|
||||||
|
-- -- For `ultisnips` user.
|
||||||
|
-- vim.fn["UltiSnips#Anon"](args.body)
|
||||||
|
-- end,
|
||||||
|
-- },
|
||||||
|
-- mapping = cmp.mapping.preset.insert({
|
||||||
|
-- ['<C-b>'] = cmp.mapping(cmp.mapping.scroll_docs(-4), { 'i', 'c' }),
|
||||||
|
-- ['<C-f>'] = cmp.mapping(cmp.mapping.scroll_docs(4), { 'i', 'c' }),
|
||||||
|
-- ['<C-Space>'] = cmp.mapping(cmp.mapping.complete(), { 'i', 'c' }),
|
||||||
|
-- ['<tab>'] = cmp.mapping.confirm({ select = true }),
|
||||||
|
-- ['<C-e>'] = cmp.mapping({
|
||||||
|
-- i = cmp.mapping.abort(),
|
||||||
|
-- c = cmp.mapping.close(),
|
||||||
|
-- }),
|
||||||
|
-- }),
|
||||||
|
-- sources = cmp.config.sources({
|
||||||
|
-- { name = 'nvim_lsp' },
|
||||||
|
--
|
||||||
|
-- { name = 'path' },
|
||||||
|
--
|
||||||
|
-- { name = 'ultisnips' },
|
||||||
|
--
|
||||||
|
-- { name = 'calc' },
|
||||||
|
--
|
||||||
|
-- { name = 'cmp_matlab' },
|
||||||
|
--
|
||||||
|
-- { name = 'cmp_git' },
|
||||||
|
-- }, {
|
||||||
|
-- { name = 'buffer', keyword_length = 5, max_item_count = 10, priority = -5 },
|
||||||
|
-- }),
|
||||||
|
-- --experimental = {
|
||||||
|
-- -- native_menu = false
|
||||||
|
-- --}
|
||||||
|
--
|
||||||
|
-- sorting = {
|
||||||
|
-- comparators = {
|
||||||
|
-- cmp.config.compare.offset,
|
||||||
|
-- cmp.config.compare.exact,
|
||||||
|
-- cmp.config.compare.recently_used,
|
||||||
|
-- require("clangd_extensions.cmp_scores"),
|
||||||
|
-- cmp.config.compare.kind,
|
||||||
|
-- cmp.config.compare.sort_text,
|
||||||
|
-- cmp.config.compare.length,
|
||||||
|
-- cmp.config.compare.order,
|
||||||
|
-- },
|
||||||
|
-- },
|
||||||
|
--})
|
||||||
|
--
|
||||||
|
--cmp.setup.cmdline('/', {
|
||||||
|
-- sources = {
|
||||||
|
-- { name = 'buffer' }
|
||||||
|
-- }
|
||||||
|
--})
|
||||||
|
--
|
||||||
|
--cmp.setup.cmdline(':', {
|
||||||
|
-- sources = {
|
||||||
|
-- { name = 'cmdline' }
|
||||||
|
-- },
|
||||||
|
-- mapping = cmp.mapping.preset.cmdline()
|
||||||
|
--})
|
||||||
|
--
|
||||||
|
--require("cmp_git").setup()
|
||||||
0
.config/nvim/after/available/nvim-dap.rc.lua
Normal file
0
.config/nvim/after/available/nvim-dap.rc.lua
Normal file
@@ -1,39 +1,25 @@
|
|||||||
let g:nvim_tree_refresh_wait = 1000 " control how often the tree can be refreshed, 1000 means the tree can be refresh once per 1000ms.
|
local opts = { noremap = true, silent = true }
|
||||||
" Dictionary of buffer option names mapped to a list of option values that
|
|
||||||
" indicates to the window picker that the buffer's window should not be
|
|
||||||
" selectable.
|
|
||||||
"If 0, do not show the icons for one of 'git' 'folder' and 'files'
|
|
||||||
"1 by default, notice that if 'files' is 1, it will only display
|
|
||||||
"if nvim-web-devicons is installed and on your runtimepath.
|
|
||||||
"if folder is 1, you can also tell folder_arrows 1 to show small arrows next to the folder icons.
|
|
||||||
"but this will not work when you set indent_markers (because of UI conflict)
|
|
||||||
|
|
||||||
" default will show icon by default if no icon is provided
|
vim.keymap.set("n", "<leader>tt", "<cmd>NvimTreeToggle<cr>", opts)
|
||||||
" default shows no icon by default
|
vim.keymap.set("n", "<leader>tf", "<cmd>NvimTreeFindFile<cr>", opts)
|
||||||
|
|
||||||
nnoremap <leader>tt :NvimTreeToggle<CR>
|
vim.g.nvim_tree_refresh_wait = 1000
|
||||||
"nnoremap <leader>r :NvimTreeRefresh<CR>
|
|
||||||
nnoremap <leader>tf :NvimTreeFindFile<CR>
|
|
||||||
" NvimTreeOpen, NvimTreeClose, NvimTreeFocus, NvimTreeFindFileToggle, and NvimTreeResize are also available if you need them
|
|
||||||
|
|
||||||
"set termguicolors " this variable must be enabled for colors to be applied properly
|
|
||||||
|
|
||||||
" a list of groups can be found at `:help nvim_tree_highlight`
|
|
||||||
"highlight NvimTreeFolderIcon guibg=blue
|
|
||||||
|
|
||||||
lua << EOF
|
|
||||||
-- following options are the default
|
-- following options are the default
|
||||||
-- each of these are documented in `:help nvim-tree.OPTION_NAME`
|
-- each of these are documented in `:help nvim-tree.OPTION_NAME`
|
||||||
require'nvim-tree'.setup {
|
require'nvim-tree'.setup {
|
||||||
disable_netrw = true,
|
disable_netrw = true,
|
||||||
hijack_netrw = true,
|
hijack_netrw = true,
|
||||||
open_on_setup = false,
|
open_on_setup = true,
|
||||||
ignore_ft_on_setup = {},
|
ignore_ft_on_setup = {},
|
||||||
open_on_tab = false,
|
open_on_tab = false,
|
||||||
hijack_cursor = true,
|
hijack_cursor = true,
|
||||||
update_cwd = false,
|
update_cwd = false,
|
||||||
respect_buf_cwd = false,
|
|
||||||
create_in_closed_folder = false,
|
create_in_closed_folder = false,
|
||||||
|
hijack_unnamed_buffer_when_opening = true,
|
||||||
|
sync_root_with_cwd = true,
|
||||||
|
reload_on_bufenter = true,
|
||||||
|
respect_buf_cwd = false,
|
||||||
hijack_directories = {
|
hijack_directories = {
|
||||||
enable = true,
|
enable = true,
|
||||||
auto_open = true,
|
auto_open = true,
|
||||||
@@ -66,8 +52,7 @@ require'nvim-tree'.setup {
|
|||||||
timeout = 500,
|
timeout = 500,
|
||||||
},
|
},
|
||||||
view = {
|
view = {
|
||||||
width = 30,
|
width = 35,
|
||||||
height = 30,
|
|
||||||
hide_root_folder = true,
|
hide_root_folder = true,
|
||||||
side = 'left',
|
side = 'left',
|
||||||
mappings = {
|
mappings = {
|
||||||
@@ -145,4 +130,3 @@ require'nvim-tree'.setup {
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
EOF
|
|
||||||
67
.config/nvim/after/available/other.rc.lua
Normal file
67
.config/nvim/after/available/other.rc.lua
Normal file
@@ -0,0 +1,67 @@
|
|||||||
|
-- Plug 'rgroli/other.nvim'
|
||||||
|
|
||||||
|
require("other-nvim").setup({
|
||||||
|
mappings = {
|
||||||
|
-- custom mapping
|
||||||
|
{
|
||||||
|
pattern = "/src/(.*).cpp$",
|
||||||
|
target = "/include/%1.hpp",
|
||||||
|
transformer = "lowercase",
|
||||||
|
context = "header"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
pattern = "/src/(.*).cpp$",
|
||||||
|
target = "/include/%1.h",
|
||||||
|
transformer = "lowercase",
|
||||||
|
context = "header"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
pattern = "/src/(.*).hpp$",
|
||||||
|
target = "/include/%1.cpp",
|
||||||
|
transformer = "lowercase",
|
||||||
|
context = "source"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
pattern = "/include/(.*).hpp$",
|
||||||
|
target = "/src/%1.cpp",
|
||||||
|
transformer = "lowercase",
|
||||||
|
context = "source"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
pattern = "/include/(.*).h$",
|
||||||
|
target = "/src/%1.cpp",
|
||||||
|
transformer = "lowercase",
|
||||||
|
context = "source"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
transformers = {
|
||||||
|
-- defining a custom transformer
|
||||||
|
lowercase = function (inputString)
|
||||||
|
return inputString:lower()
|
||||||
|
end
|
||||||
|
},
|
||||||
|
style = {
|
||||||
|
-- How the plugin paints its window borders
|
||||||
|
-- Allowed values are none, single, double, rounded, solid and shadow
|
||||||
|
border = "solid",
|
||||||
|
|
||||||
|
-- Column seperator for the window
|
||||||
|
seperator = "|",
|
||||||
|
|
||||||
|
-- width of the window in percent. e.g. 0.5 is 50%, is 100%
|
||||||
|
width = 0.7,
|
||||||
|
|
||||||
|
-- min height in rows.
|
||||||
|
-- when more columns are needed this value is extended automatically
|
||||||
|
minHeight = 2
|
||||||
|
},
|
||||||
|
})
|
||||||
|
|
||||||
|
vim.api.nvim_set_keymap("n", "<leader>ll", "<cmd>:Other<CR>", { noremap = true, silent = true })
|
||||||
|
vim.api.nvim_set_keymap("n", "<leader>lp", "<cmd>:OtherSplit<CR>", { noremap = true, silent = true })
|
||||||
|
vim.api.nvim_set_keymap("n", "<leader>lv", "<cmd>:OtherVSplit<CR>", { noremap = true, silent = true })
|
||||||
|
vim.api.nvim_set_keymap("n", "<leader>lc", "<cmd>:OtherClear<CR>", { noremap = true, silent = true })
|
||||||
|
|
||||||
|
-- Context specific bindings
|
||||||
|
vim.api.nvim_set_keymap("n", "<leader>lt", "<cmd>:Other test<CR>", { noremap = true, silent = true })
|
||||||
|
vim.api.nvim_set_keymap("n", "<leader>ls", "<cmd>:Other scss<CR>", { noremap = true, silent = true })
|
||||||
34
.config/nvim/after/available/peek.rc.lua
Normal file
34
.config/nvim/after/available/peek.rc.lua
Normal file
@@ -0,0 +1,34 @@
|
|||||||
|
-- default config:
|
||||||
|
require('peek').setup({
|
||||||
|
auto_load = true, -- whether to automatically load preview when
|
||||||
|
-- entering another markdown buffer
|
||||||
|
close_on_bdelete = true, -- close preview window on buffer delete
|
||||||
|
|
||||||
|
syntax = true, -- enable syntax highlighting, affects performance
|
||||||
|
|
||||||
|
theme = 'dark', -- 'dark' or 'light'
|
||||||
|
|
||||||
|
update_on_change = true,
|
||||||
|
|
||||||
|
-- relevant if update_on_change is true
|
||||||
|
throttle_at = 200000, -- start throttling when file exceeds this
|
||||||
|
-- amount of bytes in size
|
||||||
|
throttle_time = 'auto', -- minimum amount of time in milliseconds
|
||||||
|
-- that has to pass before starting new render
|
||||||
|
})
|
||||||
|
|
||||||
|
local peek = require('peek')
|
||||||
|
|
||||||
|
vim.api.nvim_create_user_command('PeekOpen', function()
|
||||||
|
if not peek.is_open() and vim.bo[vim.api.nvim_get_current_buf()].filetype == 'markdown' then
|
||||||
|
vim.fn.system('i3-msg split horizontal')
|
||||||
|
peek.open()
|
||||||
|
end
|
||||||
|
end, {})
|
||||||
|
|
||||||
|
vim.api.nvim_create_user_command('PeekClose', function()
|
||||||
|
if peek.is_open() then
|
||||||
|
peek.close()
|
||||||
|
vim.fn.system('i3-msg move left')
|
||||||
|
end
|
||||||
|
end, {})
|
||||||
43
.config/nvim/after/available/screenshot.rc.lua
Normal file
43
.config/nvim/after/available/screenshot.rc.lua
Normal file
@@ -0,0 +1,43 @@
|
|||||||
|
--Plug 'nvim-lua/plenary.nvim'
|
||||||
|
--Plug 'narutoxy/silicon.lua'
|
||||||
|
|
||||||
|
-- Not working well
|
||||||
|
-- silicon = require('silicon')
|
||||||
|
-- silicon.setup(
|
||||||
|
-- {
|
||||||
|
-- theme = "auto",
|
||||||
|
-- output = "SILICON_${year}-${month}-${date}_${time}.png", -- auto generate file name based on time (absolute or relative to cwd)
|
||||||
|
-- bgColor = vim.g.terminal_color_5,
|
||||||
|
-- bgImage = "", -- path to image, must be png
|
||||||
|
-- roundCorner = true,
|
||||||
|
-- windowControls = true,
|
||||||
|
-- lineNumber = true,
|
||||||
|
-- font = "monospace",
|
||||||
|
-- lineOffset = 1, -- from where to start line number
|
||||||
|
-- linePad = 2, -- padding between lines
|
||||||
|
-- padHoriz = 80, -- Horizontal padding
|
||||||
|
-- padVert = 100, -- vertical padding
|
||||||
|
-- shadowBlurRadius = 10,
|
||||||
|
-- shadowColor = "#555555",
|
||||||
|
-- shadowOffsetX = 8,
|
||||||
|
-- shadowOffsetY = 8,
|
||||||
|
-- gobble = false, -- enable lsautogobble like feature
|
||||||
|
-- debug = true, -- enable debug output
|
||||||
|
-- }
|
||||||
|
-- )
|
||||||
|
--
|
||||||
|
-- -- Generate image of lines in a visual selection
|
||||||
|
-- vim.keymap.set('v', '<Leader>s', function() silicon.visualise_api({to_clip = false, show_buf = false}) end )
|
||||||
|
-- -- Generate image of a whole buffer, with lines in a visual selection highlighted
|
||||||
|
-- vim.keymap.set('v', '<Leader>bs', function() silicon.visualise_api({to_clip = false, show_buf = true}) end )
|
||||||
|
-- -- Generate visible portion of a buffer
|
||||||
|
-- --vim.keymap.set('n', '<Leader>s', function() silicon.visualise_api({to_clip = true, visible = true}) end )
|
||||||
|
-- -- Generate current buffer line in normal mode
|
||||||
|
-- --vim.keymap.set('n', '<Leader>s', function() silicon.visualise_api({to_clip = true}) end )
|
||||||
|
|
||||||
|
|
||||||
|
-- Time for silicon.nvim
|
||||||
|
require('silicon').setup({
|
||||||
|
font = 'FantasqueSansMono Nerd Font=16',
|
||||||
|
theme = 'Monokai Extended',
|
||||||
|
})
|
||||||
2
.config/nvim/after/available/search-pulse.rc.vim
Normal file
2
.config/nvim/after/available/search-pulse.rc.vim
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
let g:vim_search_pulse_mode = 'pattern'
|
||||||
|
let g:vim_search_pulse_duration = 400
|
||||||
1
.config/nvim/after/available/startify.rc.vim
Normal file
1
.config/nvim/after/available/startify.rc.vim
Normal file
@@ -0,0 +1 @@
|
|||||||
|
let g:startify_custom_header = ''
|
||||||
34
.config/nvim/after/available/telescope.rc.vim
Normal file
34
.config/nvim/after/available/telescope.rc.vim
Normal file
@@ -0,0 +1,34 @@
|
|||||||
|
" Find files using Telescope command-line sugar.
|
||||||
|
"nnoremap <leader>f <cmd>Telescope find_files<cr>
|
||||||
|
"nnoremap <leader>g <cmd>Telescope live_grep<cr>
|
||||||
|
"nnoremap <leader>b <cmd>Telescope buffers<cr>
|
||||||
|
"nnoremap <leader>fh <cmd>Telescope help_tags<cr>
|
||||||
|
|
||||||
|
lua << EOF
|
||||||
|
|
||||||
|
-- require('telescope').load_extension('ultisnips')
|
||||||
|
|
||||||
|
EOF
|
||||||
|
|
||||||
|
" Using Lua functions
|
||||||
|
nnoremap <leader>f <cmd>lua require('telescope.builtin').find_files()<cr>
|
||||||
|
nnoremap <leader>a <cmd>lua require('telescope.builtin').grep_string()<cr>
|
||||||
|
nnoremap <leader>A <cmd>lua require('telescope.builtin').live_grep()<cr>
|
||||||
|
nnoremap <leader>b <cmd>lua require('telescope.builtin').buffers()<cr>
|
||||||
|
nnoremap <leader>r <cmd>lua require('telescope.builtin').resume()<cr>
|
||||||
|
"nnoremap <leader>fh <cmd>lua require('telescope.builtin').help_tags()<cr>
|
||||||
|
nnoremap <leader>tc <cmd>lua require('telescope.builtin').commands()<cr>
|
||||||
|
nnoremap <leader>t: <cmd>lua require('telescope.builtin').command_history()<cr>
|
||||||
|
nnoremap <leader>t/ <cmd>lua require('telescope.builtin').search_history()<cr>
|
||||||
|
nnoremap <leader>tr <cmd>lua require('telescope.builtin').registers()<cr>
|
||||||
|
|
||||||
|
" Neovim lsp pickers
|
||||||
|
nnoremap <leader>tr <cmd>lua require('telescope.builtin').lsp_references()<cr>
|
||||||
|
nnoremap <leader>td <cmd>lua require('telescope.builtin').lsp_definitions()<cr>
|
||||||
|
|
||||||
|
" git pickers
|
||||||
|
nnoremap <leader>gc <cmd>lua require('telescope.builtin').git_commits()<cr>
|
||||||
|
nnoremap <leader>gC <cmd>lua require('telescope.builtin').git_bcommits()<cr>
|
||||||
|
nnoremap <leader>gb <cmd>lua require('telescope.builtin').git_branches()<cr>
|
||||||
|
|
||||||
|
" nnoremap <leader>s <cmd>lua require('telescope').extensions.ultisnips.ultisnips()<cr>
|
||||||
11
.config/nvim/after/available/themer.rc.lua
Normal file
11
.config/nvim/after/available/themer.rc.lua
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
--require("themer").setup({
|
||||||
|
-- colorscheme = "scery",
|
||||||
|
-- enable_installer = true,
|
||||||
|
-- styles = {
|
||||||
|
-- ["function"] = { style = 'italic' },
|
||||||
|
-- functionbuiltin = { style = 'italic' },
|
||||||
|
-- variable = { style = 'italic' },
|
||||||
|
-- variableBuiltIn = { style = 'italic' },
|
||||||
|
-- parameter = { style = 'italic' },
|
||||||
|
-- },
|
||||||
|
--})
|
||||||
9
.config/nvim/after/available/toggler.rc.lua
Normal file
9
.config/nvim/after/available/toggler.rc.lua
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
require('nvim-toggler').setup({
|
||||||
|
inverses = {
|
||||||
|
['vim'] = 'emacs'
|
||||||
|
},
|
||||||
|
-- removes the default <leader>i keymap
|
||||||
|
remove_default_keybinds = true,
|
||||||
|
})
|
||||||
|
|
||||||
|
vim.keymap.set({'n', 'v'}, 'gt', require('nvim-toggler').toggle)
|
||||||
58
.config/nvim/after/available/treesitter.rc.lua
Normal file
58
.config/nvim/after/available/treesitter.rc.lua
Normal file
@@ -0,0 +1,58 @@
|
|||||||
|
-- Tree-sitter configuration
|
||||||
|
|
||||||
|
ts = require'nvim-treesitter.configs'
|
||||||
|
|
||||||
|
ts.setup {
|
||||||
|
highlight = {
|
||||||
|
enable = true,
|
||||||
|
additional_vim_regex_highlighting = false,
|
||||||
|
},
|
||||||
|
ensure_installed = {
|
||||||
|
"bash",
|
||||||
|
"c",
|
||||||
|
"cmake",
|
||||||
|
"cpp",
|
||||||
|
"fish",
|
||||||
|
"lua",
|
||||||
|
"rust",
|
||||||
|
},
|
||||||
|
-- disabled, since it mostly shifts to four characters
|
||||||
|
--indent = {
|
||||||
|
-- enable = true,
|
||||||
|
--},
|
||||||
|
incremental_selection = {
|
||||||
|
enable = true,
|
||||||
|
keymaps = {
|
||||||
|
init_selection = "ti",
|
||||||
|
node_incremental = "ti",
|
||||||
|
scope_incremental = "ts",
|
||||||
|
node_decremental = "td",
|
||||||
|
},
|
||||||
|
},
|
||||||
|
rainbow = {
|
||||||
|
enable = true,
|
||||||
|
-- disable = { "jsx", "cpp" }, list of languages you want to disable the plugin for
|
||||||
|
extended_mode = true, -- Also highlight non-bracket delimiters like html tags, boolean or table: lang -> boolean
|
||||||
|
max_file_lines = 10000, -- Do not enable for files with more than n lines, int
|
||||||
|
-- colors = {}, -- table of hex strings
|
||||||
|
-- termcolors = {} -- table of colour name strings
|
||||||
|
},
|
||||||
|
--textobjects = {
|
||||||
|
-- swap = {
|
||||||
|
-- enable = true,
|
||||||
|
-- swap_next = {
|
||||||
|
-- ["tan"] = "@parameter.inner",
|
||||||
|
-- },
|
||||||
|
-- swap_previous = {
|
||||||
|
-- ["tap"] = "@parameter.inner",
|
||||||
|
-- },
|
||||||
|
-- },
|
||||||
|
--},
|
||||||
|
matchup = {
|
||||||
|
enable = true,
|
||||||
|
-- disable = { "c", "ruby" },
|
||||||
|
include_match_words
|
||||||
|
},
|
||||||
|
}
|
||||||
|
vim.opt.foldmethod = "expr"
|
||||||
|
vim.opt.foldexpr = "nvim_treesitter#foldexpr()"
|
||||||
12
.config/nvim/after/available/ufo.rc.lua
Normal file
12
.config/nvim/after/available/ufo.rc.lua
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
vim.wo.foldcolumn = '1'
|
||||||
|
vim.wo.foldlevel = 99 -- feel free to decrease the value
|
||||||
|
vim.wo.foldenable = true
|
||||||
|
|
||||||
|
-- tell the sever the capability of foldingRange
|
||||||
|
local capabilities = vim.lsp.protocol.make_client_capabilities()
|
||||||
|
capabilities.textDocument.foldingRange = {
|
||||||
|
dynamicRegistration = false,
|
||||||
|
lineFoldingOnly = true
|
||||||
|
}
|
||||||
|
|
||||||
|
--require('ufo').setup()
|
||||||
8
.config/nvim/after/available/ultisnips.rc.vim
Normal file
8
.config/nvim/after/available/ultisnips.rc.vim
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
" Set completeopt to have a better completion experience
|
||||||
|
"set completeopt=menuone,noinsert,noselect
|
||||||
|
let g:completion_enable_snippet = 'UltiSnips'
|
||||||
|
"iunmap <Tab>
|
||||||
|
"map <c-s> <C-R>=UltiSnips#ExpandSnippet()<CR>
|
||||||
|
"let g:UltiSnipsExpandTrigger="<c-s>"
|
||||||
|
let g:UltiSnipsJumpForwardTrigger="<tab>"
|
||||||
|
let g:UltiSnipsJumpBackwardTrigger="<S-tab>"
|
||||||
13
.config/nvim/after/available/vim-cmake.rc.vim
Normal file
13
.config/nvim/after/available/vim-cmake.rc.vim
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
let g:cmake_build_options = [ "-j10" ]
|
||||||
|
|
||||||
|
let g:cmake_root_markers = ['.svn']
|
||||||
|
|
||||||
|
|
||||||
|
let g:cmake_jump_on_error = 0 " We do not want to focus the console
|
||||||
|
augroup vim-cmake-group
|
||||||
|
autocmd User CMakeBuildFailed :cfirst
|
||||||
|
augroup END
|
||||||
|
|
||||||
|
augroup vim-cmake-group
|
||||||
|
autocmd! User CMakeBuildSucceeded CMakeClose
|
||||||
|
augroup END
|
||||||
7
.config/nvim/after/available/vim-test.rc.vim
Normal file
7
.config/nvim/after/available/vim-test.rc.vim
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
"nmap <silent> <leader>tn :TestNearest<CR>
|
||||||
|
"nmap <silent> <leader>tf :TestFile<CR>
|
||||||
|
"nmap <silent> <leader>ts :TestSuite<CR>
|
||||||
|
"nmap <silent> <leader>tl :TestLast<CR>
|
||||||
|
"nmap <silent> <leader>tv :TestVisit<CR>
|
||||||
|
"
|
||||||
|
"let test#strategy = "floaterm"
|
||||||
0
.config/nvim/after/available/virt-column.rc.vim
Normal file
0
.config/nvim/after/available/virt-column.rc.vim
Normal file
5
.config/nvim/after/available/which.rc.lua
Normal file
5
.config/nvim/after/available/which.rc.lua
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
require("which-key").setup {
|
||||||
|
-- your configuration comes here
|
||||||
|
-- or leave it empty to use the default settings
|
||||||
|
-- refer to the configuration section below
|
||||||
|
}
|
||||||
8
.config/nvim/after/available/window.rc.lua
Normal file
8
.config/nvim/after/available/window.rc.lua
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
require('nvim-window').setup({
|
||||||
|
chars = {
|
||||||
|
'j', 'k', 'l', 'f', 'd', 's', 'g', 'h', 'i', 'e', 'a', 'b', 'm', 'n', 'o',
|
||||||
|
'p', 'q', 'r', 'c', 't', 'u', 'v', 'w', 'x', 'y', 'z'
|
||||||
|
},
|
||||||
|
})
|
||||||
|
|
||||||
|
vim.api.nvim_set_keymap('n', '<leader>j', '<cmd>lua require("nvim-window").pick()<cr>', {silent=true, noremap = true})
|
||||||
8
.config/nvim/after/available/windows.rc.lua
Normal file
8
.config/nvim/after/available/windows.rc.lua
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
vim.o.winwidth = 10
|
||||||
|
vim.o.winminwidth = 10
|
||||||
|
require("windows").setup()
|
||||||
|
|
||||||
|
vim.keymap.set('n', '<C-w>z', "<cmd> WindowsMaximize<cr>")
|
||||||
|
vim.keymap.set('n', '<C-w>_', "<cmd> WindowsMaximizeVertically<cr>")
|
||||||
|
vim.keymap.set('n', '<C-w>|', "<cmd> WindowsMaximizeHorizontally<cr>")
|
||||||
|
vim.keymap.set('n', '<C-w>=', "<cmd WindowsEqualize<cr>")
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
let g:airline_theme = 'minimalist'
|
|
||||||
let g:airline_powerline_fonts = 1
|
|
||||||
let g:airline_stl_path_style = 'short'
|
|
||||||
let g:airline_highlighting_cache = 1
|
|
||||||
let g:airline#extensions#searchcount#enabled = 0
|
|
||||||
1
.config/nvim/after/plugin/boole.rc.lua
Symbolic link
1
.config/nvim/after/plugin/boole.rc.lua
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/boole.rc.lua
|
||||||
@@ -1 +0,0 @@
|
|||||||
require('Comment').setup()
|
|
||||||
1
.config/nvim/after/plugin/comment.rc.lua
Symbolic link
1
.config/nvim/after/plugin/comment.rc.lua
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/comment.rc.lua
|
||||||
@@ -1,35 +0,0 @@
|
|||||||
-- " Configuration for context.vim
|
|
||||||
-- "" Disable context.vim on json files
|
|
||||||
-- ""let g:context_filetype_blacklist = ["json", "log"]
|
|
||||||
require'treesitter-context'.setup{
|
|
||||||
enable = true, -- Enable this plugin (Can be enabled/disabled later via commands)
|
|
||||||
throttle = true, -- Throttles plugin updates (may improve performance)
|
|
||||||
max_lines = 0, -- How many lines the window should span. Values <= 0 mean no limit.
|
|
||||||
patterns = { -- Match patterns for TS nodes. These get wrapped to match at word boundaries.
|
|
||||||
-- For all filetypes
|
|
||||||
-- Note that setting an entry here replaces all other patterns for this entry.
|
|
||||||
-- By setting the 'default' entry below, you can control which nodes you want to
|
|
||||||
-- appear in the context window.
|
|
||||||
default = {
|
|
||||||
'class',
|
|
||||||
'function',
|
|
||||||
'method',
|
|
||||||
'for',
|
|
||||||
'while',
|
|
||||||
'if',
|
|
||||||
'switch',
|
|
||||||
-- 'case',
|
|
||||||
},
|
|
||||||
-- Example for a specific filetype.
|
|
||||||
-- If a pattern is missing, *open a PR* so everyone can benefit.
|
|
||||||
rust = {
|
|
||||||
'impl_item',
|
|
||||||
},
|
|
||||||
},
|
|
||||||
exact_patterns = {
|
|
||||||
-- Example for a specific filetype with Lua patterns
|
|
||||||
-- Treat patterns.rust as a Lua pattern (i.e "^impl_item$" will
|
|
||||||
-- exactly match "impl_item" only)
|
|
||||||
rust = true,
|
|
||||||
}
|
|
||||||
}
|
|
||||||
1
.config/nvim/after/plugin/context.rc.lua
Symbolic link
1
.config/nvim/after/plugin/context.rc.lua
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/context.rc.lua
|
||||||
@@ -1 +0,0 @@
|
|||||||
require('crates').setup()
|
|
||||||
1
.config/nvim/after/plugin/crates.rc.lua
Symbolic link
1
.config/nvim/after/plugin/crates.rc.lua
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/crates.rc.lua
|
||||||
1
.config/nvim/after/plugin/debugprint.rc.lua
Symbolic link
1
.config/nvim/after/plugin/debugprint.rc.lua
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/debugprint.rc.lua
|
||||||
@@ -1 +0,0 @@
|
|||||||
inoremap <C-k><C-k> <Cmd>lua require'betterdigraphs'.digraphs("i")<CR>
|
|
||||||
1
.config/nvim/after/plugin/digraphs.rc.vim
Symbolic link
1
.config/nvim/after/plugin/digraphs.rc.vim
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/digraphs.rc.vim
|
||||||
@@ -1,116 +0,0 @@
|
|||||||
require('dressing').setup({
|
|
||||||
input = {
|
|
||||||
-- Set to false to disable the vim.ui.input implementation
|
|
||||||
enabled = true,
|
|
||||||
|
|
||||||
-- Default prompt string
|
|
||||||
default_prompt = "➤ ",
|
|
||||||
|
|
||||||
-- When true, <Esc> will close the modal
|
|
||||||
insert_only = true,
|
|
||||||
|
|
||||||
-- These are passed to nvim_open_win
|
|
||||||
anchor = "SW",
|
|
||||||
border = "rounded",
|
|
||||||
-- 'editor' and 'win' will default to being centered
|
|
||||||
relative = "cursor",
|
|
||||||
|
|
||||||
-- These can be integers or a float between 0 and 1 (e.g. 0.4 for 40%)
|
|
||||||
prefer_width = 40,
|
|
||||||
width = nil,
|
|
||||||
-- min_width and max_width can be a list of mixed types.
|
|
||||||
-- min_width = {20, 0.2} means "the greater of 20 columns or 20% of total"
|
|
||||||
max_width = { 140, 0.9 },
|
|
||||||
min_width = { 20, 0.2 },
|
|
||||||
|
|
||||||
-- Window transparency (0-100)
|
|
||||||
winblend = 10,
|
|
||||||
-- Change default highlight groups (see :help winhl)
|
|
||||||
winhighlight = "",
|
|
||||||
|
|
||||||
override = function(conf)
|
|
||||||
-- This is the config that will be passed to nvim_open_win.
|
|
||||||
-- Change values here to customize the layout
|
|
||||||
return conf
|
|
||||||
end,
|
|
||||||
|
|
||||||
-- see :help dressing_get_config
|
|
||||||
get_config = nil,
|
|
||||||
},
|
|
||||||
select = {
|
|
||||||
-- Set to false to disable the vim.ui.select implementation
|
|
||||||
enabled = true,
|
|
||||||
|
|
||||||
-- Priority list of preferred vim.select implementations
|
|
||||||
backend = { "telescope", "fzf_lua", "fzf", "builtin", "nui" },
|
|
||||||
|
|
||||||
-- Options for telescope selector
|
|
||||||
-- These are passed into the telescope picker directly. Can be used like:
|
|
||||||
-- telescope = require('telescope.themes').get_ivy({...})
|
|
||||||
-- telescope = require('telescope.themes').get_dropdown({}),
|
|
||||||
|
|
||||||
-- Options for fzf selector
|
|
||||||
fzf = {
|
|
||||||
window = {
|
|
||||||
width = 0.5,
|
|
||||||
height = 0.4,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
|
|
||||||
-- Options for fzf_lua selector
|
|
||||||
fzf_lua = {
|
|
||||||
winopts = {
|
|
||||||
width = 0.5,
|
|
||||||
height = 0.4,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
|
|
||||||
-- Options for nui Menu
|
|
||||||
nui = {
|
|
||||||
position = "50%",
|
|
||||||
size = nil,
|
|
||||||
relative = "editor",
|
|
||||||
border = {
|
|
||||||
style = "rounded",
|
|
||||||
},
|
|
||||||
max_width = 80,
|
|
||||||
max_height = 40,
|
|
||||||
},
|
|
||||||
|
|
||||||
-- Options for built-in selector
|
|
||||||
builtin = {
|
|
||||||
-- These are passed to nvim_open_win
|
|
||||||
anchor = "NW",
|
|
||||||
border = "rounded",
|
|
||||||
-- 'editor' and 'win' will default to being centered
|
|
||||||
relative = "editor",
|
|
||||||
|
|
||||||
-- Window transparency (0-100)
|
|
||||||
winblend = 10,
|
|
||||||
-- Change default highlight groups (see :help winhl)
|
|
||||||
winhighlight = "",
|
|
||||||
|
|
||||||
-- These can be integers or a float between 0 and 1 (e.g. 0.4 for 40%)
|
|
||||||
-- the min_ and max_ options can be a list of mixed types.
|
|
||||||
-- max_width = {140, 0.8} means "the lesser of 140 columns or 80% of total"
|
|
||||||
width = nil,
|
|
||||||
max_width = { 140, 0.8 },
|
|
||||||
min_width = { 40, 0.2 },
|
|
||||||
height = nil,
|
|
||||||
max_height = 0.9,
|
|
||||||
min_height = { 10, 0.2 },
|
|
||||||
|
|
||||||
override = function(conf)
|
|
||||||
-- This is the config that will be passed to nvim_open_win.
|
|
||||||
-- Change values here to customize the layout
|
|
||||||
return conf
|
|
||||||
end,
|
|
||||||
},
|
|
||||||
|
|
||||||
-- Used to override format_item. See :help dressing-format
|
|
||||||
format_item_override = {},
|
|
||||||
|
|
||||||
-- see :help dressing_get_config
|
|
||||||
get_config = nil,
|
|
||||||
},
|
|
||||||
})
|
|
||||||
1
.config/nvim/after/plugin/dressing.rc.lua
Symbolic link
1
.config/nvim/after/plugin/dressing.rc.lua
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/dressing.rc.lua
|
||||||
1
.config/nvim/after/plugin/femaco.rc.lua
Symbolic link
1
.config/nvim/after/plugin/femaco.rc.lua
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/femaco.rc.lua
|
||||||
@@ -1,45 +0,0 @@
|
|||||||
require'FTerm'.setup({
|
|
||||||
-- Filetype of the terminal buffer
|
|
||||||
ft = 'FTerm',
|
|
||||||
|
|
||||||
-- Command to run inside the terminal. It could be a `string` or `table`
|
|
||||||
cmd = os.getenv('SHELL'),
|
|
||||||
|
|
||||||
-- Neovim's native window border. See `:h nvim_open_win` for more configuration options.
|
|
||||||
border = 'double',
|
|
||||||
|
|
||||||
-- Close the terminal as soon as shell/command exits.
|
|
||||||
-- Disabling this will mimic the native terminal behaviour.
|
|
||||||
auto_close = true,
|
|
||||||
|
|
||||||
-- Highlight group for the terminal. See `:h winhl`
|
|
||||||
hl = 'Normal',
|
|
||||||
|
|
||||||
-- Transparency of the floating window. See `:h winblend`
|
|
||||||
blend = 0,
|
|
||||||
|
|
||||||
-- Object containing the terminal window dimensions.
|
|
||||||
-- The value for each field should be between `0` and `1`
|
|
||||||
dimensions = {
|
|
||||||
height = 0.8, -- Height of the terminal window
|
|
||||||
width = 0.8, -- Width of the terminal window
|
|
||||||
x = 0.5, -- X axis of the terminal window
|
|
||||||
y = 0.5, -- Y axis of the terminal window
|
|
||||||
},
|
|
||||||
|
|
||||||
-- Callback invoked when the terminal exits.
|
|
||||||
-- See `:h jobstart-options`
|
|
||||||
on_exit = nil,
|
|
||||||
|
|
||||||
-- Callback invoked when the terminal emits stdout data.
|
|
||||||
-- See `:h jobstart-options`
|
|
||||||
on_stdout = nil,
|
|
||||||
|
|
||||||
-- Callback invoked when the terminal emits stderr data.
|
|
||||||
-- See `:h jobstart-options`
|
|
||||||
on_stderr = nil,
|
|
||||||
})
|
|
||||||
|
|
||||||
-- Example keybindings
|
|
||||||
vim.keymap.set('n', '<leader>i', '<CMD>lua require("FTerm").toggle()<CR>')
|
|
||||||
vim.keymap.set('t', '<leader>i', '<C-\\><C-n><CMD>lua require("FTerm").toggle()<CR>')
|
|
||||||
1
.config/nvim/after/plugin/fterm.rc.lua
Symbolic link
1
.config/nvim/after/plugin/fterm.rc.lua
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/fterm.rc.lua
|
||||||
@@ -1,65 +0,0 @@
|
|||||||
require('gitsigns').setup {
|
|
||||||
signs = {
|
|
||||||
add = {hl = 'GitSignsAdd' , text = '+', numhl='GitSignsAddNr' , linehl='GitSignsAddLn'},
|
|
||||||
change = {hl = 'GitSignsChange', text = '~', numhl='GitSignsChangeNr', linehl='GitSignsChangeLn'},
|
|
||||||
delete = {hl = 'GitSignsDelete', text = '-', numhl='GitSignsDeleteNr', linehl='GitSignsDeleteLn'},
|
|
||||||
topdelete = {hl = 'GitSignsDelete', text = '‾', numhl='GitSignsDeleteNr', linehl='GitSignsDeleteLn'},
|
|
||||||
changedelete = {hl = 'GitSignsChange', text = '~', numhl='GitSignsChangeNr', linehl='GitSignsChangeLn'},
|
|
||||||
},
|
|
||||||
signcolumn = true, -- Toggle with `:Gitsigns toggle_signs`
|
|
||||||
numhl = false, -- Toggle with `:Gitsigns toggle_numhl`
|
|
||||||
linehl = false, -- Toggle with `:Gitsigns toggle_linehl`
|
|
||||||
word_diff = false, -- Toggle with `:Gitsigns toggle_word_diff`
|
|
||||||
keymaps = {
|
|
||||||
-- Default keymap options
|
|
||||||
noremap = true,
|
|
||||||
|
|
||||||
['n ]c'] = { expr = true, "&diff ? ']c' : '<cmd>Gitsigns next_hunk<CR>'"},
|
|
||||||
['n [c'] = { expr = true, "&diff ? '[c' : '<cmd>Gitsigns prev_hunk<CR>'"},
|
|
||||||
|
|
||||||
['n <leader>hs'] = '<cmd>Gitsigns stage_hunk<CR>',
|
|
||||||
['v <leader>hs'] = ':Gitsigns stage_hunk<CR>',
|
|
||||||
['n <leader>hu'] = '<cmd>Gitsigns undo_stage_hunk<CR>',
|
|
||||||
['n <leader>hr'] = '<cmd>Gitsigns reset_hunk<CR>',
|
|
||||||
['v <leader>hr'] = ':Gitsigns reset_hunk<CR>',
|
|
||||||
['n <leader>hR'] = '<cmd>Gitsigns reset_buffer<CR>',
|
|
||||||
['n <leader>hp'] = '<cmd>Gitsigns preview_hunk<CR>',
|
|
||||||
['n <leader>hb'] = '<cmd>lua require"gitsigns".blame_line{full=true}<CR>',
|
|
||||||
['n <leader>hS'] = '<cmd>Gitsigns stage_buffer<CR>',
|
|
||||||
['n <leader>hU'] = '<cmd>Gitsigns reset_buffer_index<CR>',
|
|
||||||
|
|
||||||
-- Text objects
|
|
||||||
['o ih'] = ':<C-U>Gitsigns select_hunk<CR>',
|
|
||||||
['x ih'] = ':<C-U>Gitsigns select_hunk<CR>'
|
|
||||||
},
|
|
||||||
watch_gitdir = {
|
|
||||||
interval = 1000,
|
|
||||||
follow_files = true
|
|
||||||
},
|
|
||||||
attach_to_untracked = true,
|
|
||||||
current_line_blame = false, -- Toggle with `:Gitsigns toggle_current_line_blame`
|
|
||||||
current_line_blame_opts = {
|
|
||||||
virt_text = true,
|
|
||||||
virt_text_pos = 'eol', -- 'eol' | 'overlay' | 'right_align'
|
|
||||||
delay = 1000,
|
|
||||||
ignore_whitespace = false,
|
|
||||||
},
|
|
||||||
current_line_blame_formatter_opts = {
|
|
||||||
relative_time = false
|
|
||||||
},
|
|
||||||
sign_priority = 6,
|
|
||||||
update_debounce = 100,
|
|
||||||
status_formatter = nil, -- Use default
|
|
||||||
max_file_length = 40000,
|
|
||||||
preview_config = {
|
|
||||||
-- Options passed to nvim_open_win
|
|
||||||
border = 'single',
|
|
||||||
style = 'minimal',
|
|
||||||
relative = 'cursor',
|
|
||||||
row = 0,
|
|
||||||
col = 1
|
|
||||||
},
|
|
||||||
yadm = {
|
|
||||||
enable = true
|
|
||||||
},
|
|
||||||
}
|
|
||||||
1
.config/nvim/after/plugin/gitsigns.rc.lua
Symbolic link
1
.config/nvim/after/plugin/gitsigns.rc.lua
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/gitsigns.rc.lua
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
"noremap <silent> n <Cmd>execute('normal! ' . v:count1 . 'n')<CR>
|
|
||||||
" \<Cmd>lua require('hlslens').start()<CR>
|
|
||||||
"noremap <silent> N <Cmd>execute('normal! ' . v:count1 . 'N')<CR>
|
|
||||||
" \<Cmd>lua require('hlslens').start()<CR>
|
|
||||||
"noremap * *<Cmd>lua require('hlslens').start()<CR>
|
|
||||||
"noremap # #<Cmd>lua require('hlslens').start()<CR>
|
|
||||||
"noremap g* g*<Cmd>lua require('hlslens').start()<CR>
|
|
||||||
"noremap g# g#<Cmd>lua require('hlslens').start()<CR>
|
|
||||||
"
|
|
||||||
"" use : instead of <Cmd>
|
|
||||||
"nnoremap <silent> <leader>l :noh<CR>
|
|
||||||
1
.config/nvim/after/plugin/hlslens.rc.vim
Symbolic link
1
.config/nvim/after/plugin/hlslens.rc.vim
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/hlslens.rc.vim
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
require("icon-picker")
|
|
||||||
|
|
||||||
local opts = { noremap = true, silent = true }
|
|
||||||
|
|
||||||
vim.keymap.set("n", "<leader>o", "<cmd>PickIcons<cr>", opts)
|
|
||||||
1
.config/nvim/after/plugin/icons.rc.lua
Symbolic link
1
.config/nvim/after/plugin/icons.rc.lua
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/icons.rc.lua
|
||||||
1
.config/nvim/after/plugin/illuminate.rc.lua
Symbolic link
1
.config/nvim/after/plugin/illuminate.rc.lua
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/illuminate.rc.lua
|
||||||
@@ -1,22 +0,0 @@
|
|||||||
require("indent_blankline").setup {
|
|
||||||
char = "",
|
|
||||||
show_current_context = true,
|
|
||||||
--show_current_context_start = true,
|
|
||||||
space_char_blankline = " ",
|
|
||||||
char_highlight_list = {
|
|
||||||
"IndentBlanklineIndent1",
|
|
||||||
"IndentBlanklineIndent2",
|
|
||||||
"IndentBlanklineIndent3",
|
|
||||||
"IndentBlanklineIndent4",
|
|
||||||
"IndentBlanklineIndent5",
|
|
||||||
"IndentBlanklineIndent6",
|
|
||||||
},
|
|
||||||
space_char_highlight_list = {
|
|
||||||
"IndentBlanklineIndent1",
|
|
||||||
"IndentBlanklineIndent2",
|
|
||||||
"IndentBlanklineIndent3",
|
|
||||||
"IndentBlanklineIndent4",
|
|
||||||
"IndentBlanklineIndent5",
|
|
||||||
"IndentBlanklineIndent6",
|
|
||||||
},
|
|
||||||
}
|
|
||||||
1
.config/nvim/after/plugin/indent.rc.lua
Symbolic link
1
.config/nvim/after/plugin/indent.rc.lua
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/indent.rc.lua
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
require('iswap').setup{}
|
|
||||||
|
|
||||||
local opts = { noremap=true, silent=true }
|
|
||||||
vim.api.nvim_set_keymap('n', 'ta', '<cmd>ISwapWith<cr>', opts)
|
|
||||||
vim.api.nvim_set_keymap('n', 'tn', '<cmd>ISwap<cr>', opts)
|
|
||||||
1
.config/nvim/after/plugin/iswap.rc.lua
Symbolic link
1
.config/nvim/after/plugin/iswap.rc.lua
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/iswap.rc.lua
|
||||||
@@ -1,29 +0,0 @@
|
|||||||
local gknapsettings = {
|
|
||||||
htmloutputext = "html",
|
|
||||||
htmltohtml = "touch %outputfile%",
|
|
||||||
htmltohtmlviewerlaunch = "google-chrome-beta %outputfile%",
|
|
||||||
htmltohtmlviewerrefresh = "none",
|
|
||||||
mdoutputext = "html",
|
|
||||||
mdtohtml = "pandoc --standalone %docroot% -o %outputfile%",
|
|
||||||
mdtohtmlviewerlaunch = "google-chrome-beta %outputfile%",
|
|
||||||
mdtohtmlviewerrefresh = "none",
|
|
||||||
mdtopdf = "pandoc %docroot% -o %outputfile%",
|
|
||||||
mdtopdfviewerlaunch = "sioyek %outputfile%",
|
|
||||||
mdtopdfviewerrefresh = "none",
|
|
||||||
markdownoutputext = "html",
|
|
||||||
markdowntohtml = "pandoc --standalone %docroot% -o %outputfile%",
|
|
||||||
markdowntohtmlviewerlaunch = "google-chrome-beta %outputfile%",
|
|
||||||
markdowntohtmlviewerrefresh = "none",
|
|
||||||
markdowntopdf = "pandoc %docroot% -o %outputfile%",
|
|
||||||
markdowntopdfviewerlaunch = "sioyek %outputfile%",
|
|
||||||
markdowntopdfviewerrefresh = "none",
|
|
||||||
texoutputext = "pdf",
|
|
||||||
textopdf = "pdflatex -interaction=batchmode -halt-on-error -synctex=1 %docroot%",
|
|
||||||
textopdfviewerlaunch = "sioyek --inverse-search 'nvim --headless -es --cmd \"lua require('\"'\"'knaphelper'\"'\"').relayjump('\"'\"'%servername%'\"'\"','\"'\"'%1'\"'\"',%2,%3)\"' --reuse-instance %outputfile%",
|
|
||||||
textopdfviewerrefresh = "none",
|
|
||||||
textopdfforwardjump = "sioyek --inverse-search 'nvim --headless -es --cmd \"lua require('\"'\"'knaphelper'\"'\"').relayjump('\"'\"'%servername%'\"'\"','\"'\"'%1'\"'\"',%2,%3)\"' --reuse-instance --forward-search-file %srcfile% --forward-search-line %line% %outputfile%",
|
|
||||||
textopdfshorterror = "A=%outputfile% ; LOGFILE=\"${A%.pdf}.log\" ; rubber-info \"$LOGFILE\" 2>&1 | head -n 1",
|
|
||||||
delay = 250
|
|
||||||
}
|
|
||||||
|
|
||||||
vim.g.knap_settings = gknapsettings
|
|
||||||
1
.config/nvim/after/plugin/knap.rc.lua
Symbolic link
1
.config/nvim/after/plugin/knap.rc.lua
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/knap.rc.lua
|
||||||
@@ -1,154 +0,0 @@
|
|||||||
local nvim_lsp = require'lspconfig'
|
|
||||||
local coq = require'coq'
|
|
||||||
--local cmp = require'cmp_nvim_lsp'
|
|
||||||
local clangd_extensions = require("clangd_extensions")
|
|
||||||
|
|
||||||
-- Mappings.
|
|
||||||
local opts = { noremap=true, silent=true }
|
|
||||||
vim.api.nvim_set_keymap('n', '<leader>e', '<cmd>lua vim.diagnostic.open_float()<CR>', opts)
|
|
||||||
vim.api.nvim_set_keymap('n', '[d', '<cmd>lua vim.diagnostic.goto_prev()<CR>', opts)
|
|
||||||
vim.api.nvim_set_keymap('n', ']d', '<cmd>lua vim.diagnostic.goto_next()<CR>', opts)
|
|
||||||
vim.api.nvim_set_keymap('n', '<leader>E', '<cmd>lua vim.diagnostic.set_loclist()<CR>', opts)
|
|
||||||
vim.api.nvim_set_keymap("n", "<leader>q", "<cmd>lua vim.lsp.buf.format{ async = true }<CR>", opts)
|
|
||||||
|
|
||||||
-- Use an on_attach function to only map the following keys
|
|
||||||
-- after the language server attaches to the current buffer
|
|
||||||
local on_attach = function(client, bufnr)
|
|
||||||
--Enable completion triggered by <c-x><c-o>
|
|
||||||
vim.api.nvim_buf_set_option(bufnr, 'omnifunc', 'v:lua.vim.lsp.omnifunc')
|
|
||||||
|
|
||||||
---- See `:help vim.lsp.*` for documentation on any of the below functions
|
|
||||||
vim.api.nvim_buf_set_keymap(bufnr, 'n', 'gD', '<cmd>lua vim.lsp.buf.declaration()<CR>', opts)
|
|
||||||
vim.api.nvim_buf_set_keymap(bufnr, 'n', 'gd', '<cmd>lua vim.lsp.buf.definition()<CR>', opts)
|
|
||||||
vim.api.nvim_buf_set_keymap(bufnr, 'n', 'K', '<cmd>lua vim.lsp.buf.hover()<CR>', opts)
|
|
||||||
vim.api.nvim_buf_set_keymap(bufnr, 'n', 'gi', '<cmd>lua vim.lsp.buf.implementation()<CR>', opts)
|
|
||||||
vim.api.nvim_buf_set_keymap(bufnr, 'n', '<C-k>', '<cmd>lua vim.lsp.buf.signature_help()<CR>', opts)
|
|
||||||
--vim.api.nvim_buf_set_keymap(bufnr, 'n', '<space>wa', '<cmd>lua vim.lsp.buf.add_workspace_folder()<CR>', opts)
|
|
||||||
--vim.api.nvim_buf_set_keymap(bufnr, 'n', '<space>wr', '<cmd>lua vim.lsp.buf.remove_workspace_folder()<CR>', opts)
|
|
||||||
--vim.api.nvim_buf_set_keymap(bufnr, 'n', '<space>wl', '<cmd>lua print(vim.inspect(vim.lsp.buf.list_workspace_folders()))<CR>', opts)
|
|
||||||
vim.api.nvim_buf_set_keymap(bufnr, 'n', '<leader>D', '<cmd>lua vim.lsp.buf.type_definition()<CR>', opts)
|
|
||||||
vim.api.nvim_buf_set_keymap(bufnr, 'n', '<leader>rn', '<cmd>lua vim.lsp.buf.rename()<CR>', opts)
|
|
||||||
vim.api.nvim_buf_set_keymap(bufnr, 'n', '<leader>ca', '<cmd>lua vim.lsp.buf.code_action()<CR>', opts)
|
|
||||||
vim.api.nvim_buf_set_keymap(bufnr, 'n', 'gr', '<cmd>lua vim.lsp.buf.references()<CR>', opts)
|
|
||||||
vim.api.nvim_buf_set_keymap(bufnr, 'n', '<F6>', '<cmd>ClangdSwitchSourceHeader<cr>', opts)
|
|
||||||
|
|
||||||
require'illuminate'.on_attach(client)
|
|
||||||
require'virtualtypes'.on_attach()
|
|
||||||
end
|
|
||||||
|
|
||||||
local signs = {
|
|
||||||
{ name = "DiagnosticSignError", text = "" },
|
|
||||||
{ name = "DiagnosticSignWarn", text = "" },
|
|
||||||
{ name = "DiagnosticSignHint", text = "" },
|
|
||||||
{ name = "DiagnosticSignInfo", text = "" },
|
|
||||||
}
|
|
||||||
|
|
||||||
for _, sign in ipairs(signs) do
|
|
||||||
vim.fn.sign_define(sign.name, { texthl = sign.name, text = sign.text, numhl = "" })
|
|
||||||
end
|
|
||||||
|
|
||||||
vim.lsp.handlers["textDocument/publishDiagnostics"] = vim.lsp.with(
|
|
||||||
vim.lsp.diagnostic.on_publish_diagnostics, {
|
|
||||||
signs = {
|
|
||||||
active = signs,
|
|
||||||
--severity_limit = 'info',
|
|
||||||
},
|
|
||||||
severity_sort = true,
|
|
||||||
underline = false,
|
|
||||||
update_in_insert = false,
|
|
||||||
--virtual_text = {
|
|
||||||
-- spacing = 40,
|
|
||||||
-- severity_limit = 'Warning',
|
|
||||||
--},
|
|
||||||
virtual_text = false,
|
|
||||||
}
|
|
||||||
)
|
|
||||||
|
|
||||||
nvim_lsp.groovyls.setup (coq.lsp_ensure_capabilities({
|
|
||||||
cmd = { "java", "-jar", "/home/kmcr/tools/groovy-language-server/build/libs/groovy-language-server-all.jar" },
|
|
||||||
on_attach = on_attach,
|
|
||||||
on_publish_diagnostics = diagnostic_handler,
|
|
||||||
capabilities = vim.lsp.protocol.make_client_capabilities(),
|
|
||||||
})
|
|
||||||
)
|
|
||||||
|
|
||||||
-- nvim_lsp.ccls.setup(
|
|
||||||
-- coq.lsp_ensure_capabilities({
|
|
||||||
-- init_options = {
|
|
||||||
-- compilationDatabaseDirectory = ".";
|
|
||||||
-- index = {
|
|
||||||
-- threads = 0;
|
|
||||||
-- },
|
|
||||||
-- clang = {
|
|
||||||
-- excludeArgs = { "-frounding-math"} ;
|
|
||||||
-- },
|
|
||||||
-- },
|
|
||||||
-- root_dir = nvim_lsp.util.root_pattern("compile_commands.json"),
|
|
||||||
-- on_attach = on_attach,
|
|
||||||
-- on_publish_diagnostics = diagnostic_handler,
|
|
||||||
-- capabilities = cmp.update_capabilities(vim.lsp.protocol.make_client_capabilities()),
|
|
||||||
-- flags = {
|
|
||||||
-- debounce_text_changes = 150,
|
|
||||||
-- }}
|
|
||||||
-- )
|
|
||||||
-- )
|
|
||||||
|
|
||||||
clangd_extensions.setup(coq.lsp_ensure_capabilities({
|
|
||||||
server = {
|
|
||||||
on_attach = on_attach,
|
|
||||||
root_pattern = {
|
|
||||||
'.clangd',
|
|
||||||
'.clang-tidy',
|
|
||||||
'.clang-format',
|
|
||||||
'compile_commands.json',
|
|
||||||
'compile_flags.txt',
|
|
||||||
'configure.ac',
|
|
||||||
}
|
|
||||||
},
|
|
||||||
inlay_hints = {
|
|
||||||
max_len_align = true,
|
|
||||||
max_len_align_padding = 3,
|
|
||||||
right_align = true,
|
|
||||||
}
|
|
||||||
}))
|
|
||||||
-- nvim_lsp.clangd.setup(
|
|
||||||
-- coq.lsp_ensure_capabilities({
|
|
||||||
-- root_dir = nvim_lsp.util.root_pattern("compile_commands.json"),
|
|
||||||
-- on_attach = on_attach,
|
|
||||||
-- capabilities = cmp.update_capabilities(vim.lsp.protocol.make_client_capabilities()),
|
|
||||||
-- flags = {
|
|
||||||
-- debounce_text_changes = 150,
|
|
||||||
-- }}
|
|
||||||
-- )
|
|
||||||
-- )
|
|
||||||
|
|
||||||
nvim_lsp.pylsp.setup(coq.lsp_ensure_capabilities({
|
|
||||||
settings = {
|
|
||||||
pylint = {
|
|
||||||
enabled = false
|
|
||||||
},
|
|
||||||
pyflakes = {
|
|
||||||
enabled = false,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
flags = {
|
|
||||||
debounce_text_changes = 150,
|
|
||||||
},
|
|
||||||
on_attach = on_attach,
|
|
||||||
on_publish_diagnostics = diagnostic_handler,
|
|
||||||
capabilities = vim.lsp.protocol.make_client_capabilities(),
|
|
||||||
}))
|
|
||||||
|
|
||||||
-- Use a loop to conveniently call 'setup' on multiple servers and
|
|
||||||
-- map buffer local keybindings when the language server attaches
|
|
||||||
local servers = { "cmake", "rust_analyzer", "bashls" }
|
|
||||||
for _, lsp in ipairs(servers) do
|
|
||||||
nvim_lsp[lsp].setup(coq.lsp_ensure_capabilities({
|
|
||||||
on_attach = on_attach,
|
|
||||||
on_publish_diagnostics = diagnostic_handler,
|
|
||||||
capabilities = vim.lsp.protocol.make_client_capabilities(),
|
|
||||||
flags = {
|
|
||||||
debounce_text_changes = 150,
|
|
||||||
}
|
|
||||||
}))
|
|
||||||
end
|
|
||||||
1
.config/nvim/after/plugin/lspconfig.rc.lua
Symbolic link
1
.config/nvim/after/plugin/lspconfig.rc.lua
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/lspconfig.rc.lua
|
||||||
1
.config/nvim/after/plugin/lualine.rc.lua
Symbolic link
1
.config/nvim/after/plugin/lualine.rc.lua
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/lualine.rc.lua
|
||||||
@@ -1 +0,0 @@
|
|||||||
let g:mkdp_filetypes = ['markdown', 'plantuml']
|
|
||||||
1
.config/nvim/after/plugin/md-preview.rc.vim
Symbolic link
1
.config/nvim/after/plugin/md-preview.rc.vim
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/md-preview.rc.vim
|
||||||
1
.config/nvim/after/plugin/minimap.rc.lua
Symbolic link
1
.config/nvim/after/plugin/minimap.rc.lua
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/minimap.rc.lua
|
||||||
1
.config/nvim/after/plugin/mkdnflow.rc.lua
Symbolic link
1
.config/nvim/after/plugin/mkdnflow.rc.lua
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/mkdnflow.rc.lua
|
||||||
@@ -1,22 +0,0 @@
|
|||||||
require("neogen").setup({
|
|
||||||
--snippet_engine = 'ultisnips',
|
|
||||||
input_after_comment = true,
|
|
||||||
})
|
|
||||||
|
|
||||||
-- {
|
|
||||||
-- { nil, "///!", { no_results = true, type = { "func", "file", "class" } } },
|
|
||||||
-- { nil, "///! @file", { no_results = true, type = { "file" } } },
|
|
||||||
-- { nil, "///! * @brief $1", { no_results = true, type = { "func", "file", "class" } } },
|
|
||||||
-- { nil, "", { no_results = true, type = { "func", "file", "class" } } },
|
|
||||||
-- { nil, "", { no_results = true, type = { "file" } } },
|
|
||||||
--
|
|
||||||
-- { nil, "/**", { type = { "func", "class", "type" } } },
|
|
||||||
-- { i.ClassName, " * @class %s", { type = { "class" } } },
|
|
||||||
-- { i.Type, " * @typedef %s", { type = { "type" } } },
|
|
||||||
-- { nil, " * @brief $1", { type = { "func", "class", "type" } } },
|
|
||||||
-- { nil, " *", { type = { "func", "class", "type" } } },
|
|
||||||
-- { i.Tparam, " * @tparam %s $1" },
|
|
||||||
-- { i.Parameter, " * @param %s $1" },
|
|
||||||
-- { i.Return, " * @return $1" },
|
|
||||||
-- { nil, " */", { type = { "func", "class", "type" } } },
|
|
||||||
-- }
|
|
||||||
1
.config/nvim/after/plugin/neogen.rc.lua
Symbolic link
1
.config/nvim/after/plugin/neogen.rc.lua
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/neogen.rc.lua
|
||||||
@@ -1,13 +0,0 @@
|
|||||||
require('neorg').setup {
|
|
||||||
load = {
|
|
||||||
["core.defaults"] = {}
|
|
||||||
},
|
|
||||||
["core.norg.dirman"] = {
|
|
||||||
config = {
|
|
||||||
workspaces = {
|
|
||||||
work = "~/notes/work",
|
|
||||||
home = "~/notes/home",
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
1
.config/nvim/after/plugin/neorg.rc.lua
Symbolic link
1
.config/nvim/after/plugin/neorg.rc.lua
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/neorg.rc.lua
|
||||||
@@ -1,13 +0,0 @@
|
|||||||
-- require('neoscroll').setup({
|
|
||||||
-- -- All these keys will be mapped to their corresponding default scrolling animation
|
|
||||||
-- mappings = {'<C-u>', '<C-d>', '<C-b>', '<C-f>',
|
|
||||||
-- '<C-y>', '<C-e>', 'zt', 'zz', 'zb'},
|
|
||||||
-- hide_cursor = true, -- Hide cursor while scrolling
|
|
||||||
-- stop_eof = true, -- Stop at <EOF> when scrolling downwards
|
|
||||||
-- use_local_scrolloff = false, -- Use the local scope of scrolloff instead of the global scope
|
|
||||||
-- respect_scrolloff = false, -- Stop scrolling when the cursor reaches the scrolloff margin of the file
|
|
||||||
-- cursor_scrolls_alone = true, -- The cursor will keep on scrolling even if the window cannot scroll further
|
|
||||||
-- easing_function = nil, -- Default easing function
|
|
||||||
-- pre_hook = nil, -- Function to run before the scrolling animation starts
|
|
||||||
-- post_hook = nil, -- Function to run after the scrolling animation ends
|
|
||||||
-- })
|
|
||||||
1
.config/nvim/after/plugin/neoscroll.rc.lua
Symbolic link
1
.config/nvim/after/plugin/neoscroll.rc.lua
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/neoscroll.rc.lua
|
||||||
@@ -1,73 +0,0 @@
|
|||||||
-- Setup nvim-cmp.
|
|
||||||
--local cmp = require'cmp'
|
|
||||||
--
|
|
||||||
--cmp.setup({
|
|
||||||
-- snippet = {
|
|
||||||
-- expand = function(args)
|
|
||||||
-- -- For `vsnip` user.
|
|
||||||
-- -- vim.fn["vsnip#anonymous"](args.body)
|
|
||||||
--
|
|
||||||
-- -- For `luasnip` user.
|
|
||||||
-- -- require('luasnip').lsp_expand(args.body)
|
|
||||||
--
|
|
||||||
-- -- For `ultisnips` user.
|
|
||||||
-- vim.fn["UltiSnips#Anon"](args.body)
|
|
||||||
-- end,
|
|
||||||
-- },
|
|
||||||
-- mapping = cmp.mapping.preset.insert({
|
|
||||||
-- ['<C-b>'] = cmp.mapping(cmp.mapping.scroll_docs(-4), { 'i', 'c' }),
|
|
||||||
-- ['<C-f>'] = cmp.mapping(cmp.mapping.scroll_docs(4), { 'i', 'c' }),
|
|
||||||
-- ['<C-Space>'] = cmp.mapping(cmp.mapping.complete(), { 'i', 'c' }),
|
|
||||||
-- ['<tab>'] = cmp.mapping.confirm({ select = true }),
|
|
||||||
-- ['<C-e>'] = cmp.mapping({
|
|
||||||
-- i = cmp.mapping.abort(),
|
|
||||||
-- c = cmp.mapping.close(),
|
|
||||||
-- }),
|
|
||||||
-- }),
|
|
||||||
-- sources = cmp.config.sources({
|
|
||||||
-- { name = 'nvim_lsp' },
|
|
||||||
--
|
|
||||||
-- { name = 'path' },
|
|
||||||
--
|
|
||||||
-- { name = 'ultisnips' },
|
|
||||||
--
|
|
||||||
-- { name = 'calc' },
|
|
||||||
--
|
|
||||||
-- { name = 'cmp_matlab' },
|
|
||||||
--
|
|
||||||
-- { name = 'cmp_git' },
|
|
||||||
-- }, {
|
|
||||||
-- { name = 'buffer', keyword_length = 5, max_item_count = 10, priority = -5 },
|
|
||||||
-- }),
|
|
||||||
-- --experimental = {
|
|
||||||
-- -- native_menu = false
|
|
||||||
-- --}
|
|
||||||
--
|
|
||||||
-- sorting = {
|
|
||||||
-- comparators = {
|
|
||||||
-- cmp.config.compare.offset,
|
|
||||||
-- cmp.config.compare.exact,
|
|
||||||
-- cmp.config.compare.recently_used,
|
|
||||||
-- require("clangd_extensions.cmp_scores"),
|
|
||||||
-- cmp.config.compare.kind,
|
|
||||||
-- cmp.config.compare.sort_text,
|
|
||||||
-- cmp.config.compare.length,
|
|
||||||
-- cmp.config.compare.order,
|
|
||||||
-- },
|
|
||||||
-- },
|
|
||||||
--})
|
|
||||||
--
|
|
||||||
--cmp.setup.cmdline('/', {
|
|
||||||
-- sources = {
|
|
||||||
-- { name = 'buffer' }
|
|
||||||
-- }
|
|
||||||
--})
|
|
||||||
--
|
|
||||||
--cmp.setup.cmdline(':', {
|
|
||||||
-- sources = {
|
|
||||||
-- { name = 'cmdline' }
|
|
||||||
-- },
|
|
||||||
-- mapping = cmp.mapping.preset.cmdline()
|
|
||||||
--})
|
|
||||||
--
|
|
||||||
--require("cmp_git").setup()
|
|
||||||
1
.config/nvim/after/plugin/nvim-cmp.rc.lua
Symbolic link
1
.config/nvim/after/plugin/nvim-cmp.rc.lua
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/nvim-cmp.rc.lua
|
||||||
1
.config/nvim/after/plugin/nvim-dap.rc.lua
Symbolic link
1
.config/nvim/after/plugin/nvim-dap.rc.lua
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/nvim-dap.rc.lua
|
||||||
1
.config/nvim/after/plugin/nvim-tree.rc.lua
Symbolic link
1
.config/nvim/after/plugin/nvim-tree.rc.lua
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../available/nvim-tree.rc.lua
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user