initial commit

This commit is contained in:
TriMill 2023-03-07 13:15:21 -05:00
commit 2e712bca89
33 changed files with 1682 additions and 0 deletions

View file

@ -0,0 +1,77 @@
# Configuration for Alacritty, the GPU enhanced terminal emulator.
#env:
#TERM: alacritty
window:
padding:
x: 5
y: 5
decorations: full
dynamic_title: true
opacity: 0.90
font:
normal:
family: Fira Mono
style: Regular
bold:
style: Bold
italic:
style: Italic
bold_italic:
style: Bold Italic
size: 11.5
offset:
x: 0
y: 0
draw_bold_text_with_bright_colors: false
colors:
primary:
background: '0x14171d'
foreground: '0xc7c6c3'
normal:
black: '0x14171d'
red: '0xa63a3a'
green: '0x759438'
yellow: '0xde7e54'
blue: '0x3d67a2'
magenta: '0x7b5687'
cyan: '0x578c7c'
white: '0xada0a8'
bright:
black: '0x4d4754'
red: '0xcc5c5c'
green: '0x97bd5e'
yellow: '0xf0c767'
blue: '0x789ebf'
magenta: '0xa97fb3'
cyan: '0x82bfb3'
white: '0xc7c6c3'
selection:
text: CellBackground
background: CellForeground
cursor:
text: CellBackground
background: CellForeground
hints:
enabled:
- regex: "(magnet|mailto|gemini|gopher|https|http|news|file|git|ssh|ftp):\
[^\u0000-\u001F\u007F-\u009F<>\"\\s{-}\\^⟨⟩`]+"
command: xdg-open
post_processing: true
mouse:
enabled: true
mods: None
binding:
key: U
mods: Control|Shift
key_bindings:
- { key: Return, mods: Control|Super, action: SpawnNewInstance }

View file

@ -0,0 +1,337 @@
# Configuration for Alacritty, the GPU enhanced terminal emulator.
#env:
#TERM: alacritty
window:
#dimensions:
# columns: 0
# lines: 0
#position:
# x: 0
# y: 0
padding:
x: 5
y: 5
#dynamic_padding: true
decorations: full
#startup_mode: Windowed
#title: Alacritty
dynamic_title: true
#class:
#instance: Alacritty
#general: Alacritty
#gtk_theme_variant: None
opacity: 1
#scrolling:
#history: 10000
#multiplier: 3
font:
normal:
family: Perfect DOS VGA 437
style: Regular
bold:
style: Bold
italic:
style: Italic
bold_italic:
style: Bold Italic
size: 11
offset:
x: 0
y: 0
#glyph_offset:
# x: 0
# y: 0
draw_bold_text_with_bright_colors: false
colors:
primary:
background: '0x000000'
foreground: '0xaaaaaa'
normal:
black: '0x000000'
red: '0xaa0000'
green: '0x759438'
yellow: '0xde7e54'
blue: '0x3d67a2'
magenta: '0x7b5687'
cyan: '0x578c7c'
white: '0xaaaaaa'
bright:
black: '0x555555'
red: '0xff5555'
green: '0x97bd5e'
yellow: '0xf0c767'
blue: '0x789ebf'
magenta: '0xa97fb3'
cyan: '0x82bfb3'
white: '0xffffff'
selection:
text: CellBackground
background: CellForeground
cursor:
text: CellBackground
background: CellForeground
# Colors (Tomorrow Night)
#colors:
# Default colors
#primary:
# background: '#1d1f21'
# foreground: '#c5c8c6'
# Bright and dim foreground colors
#
# The dimmed foreground color is calculated automatically if it is not present.
# If the bright foreground color is not set, or `draw_bold_text_with_bright_colors`
# is `false`, the normal foreground color will be used.
#dim_foreground: '#828482'
#bright_foreground: '#eaeaea'
# Cursor colors
#
# Colors which should be used to draw the terminal cursor.
#
# Allowed values are CellForeground and CellBackground, which reference the
# affected cell, or hexadecimal colors like #ff00ff.
#cursor:
# text: CellBackground
# cursor: CellForeground
# Vi mode cursor colors
#
# Colors for the cursor when the vi mode is active.
#
# Allowed values are CellForeground and CellBackground, which reference the
# affected cell, or hexadecimal colors like #ff00ff.
#vi_mode_cursor:
# text: CellBackground
# cursor: CellForeground
# Selection colors
#
# Colors which should be used to draw the selection area.
#
# Allowed values are CellForeground and CellBackground, which reference the
# affected cell, or hexadecimal colors like #ff00ff.
#selection:
# text: CellBackground
# background: CellForeground
# Search colors
#
# Colors used for the search bar and match highlighting.
#
# Allowed values are CellForeground and CellBackground, which reference the
# affected cell, or hexadecimal colors like #ff00ff.
#search:
# matches:
# foreground: '#000000'
# background: '#ffffff'
#
# bar:
# background: CellForeground
# foreground: CellBackground
# Normal colors
#normal:
# black: '#1d1f21'
# red: '#cc6666'
# green: '#b5bd68'
# yellow: '#f0c674'
# blue: '#81a2be'
# magenta: '#b294bb'
# cyan: '#8abeb7'
# white: '#c5c8c6'
# Bright colors
#bright:
# black: '#666666'
# red: '#d54e53'
# green: '#b9ca4a'
# yellow: '#e7c547'
# blue: '#7aa6da'
# magenta: '#c397d8'
# cyan: '#70c0b1'
# white: '#eaeaea'
# Dim colors
#
# If the dim colors are not set, they will be calculated automatically based
# on the `normal` colors.
#dim:
# black: '#131415'
# red: '#864343'
# green: '#777c44'
# yellow: '#9e824c'
# blue: '#556a7d'
# magenta: '#75617b'
# cyan: '#5b7d78'
# white: '#828482'
# Indexed Colors
#
# The indexed colors include all colors from 16 to 256.
# When these are not set, they're filled with sensible defaults.
#
# Example:
# `- { index: 16, color: '#ff00ff' }`
#
#indexed_colors: []
#bell:
#animation: EaseOutExpo
#duration: 50
#color: '#000000'
#command: None
#selection:
#semantic_escape_chars: ",│`|:\"' ()[]{}<>\t"
#save_to_clipboard: false
# Allow terminal applications to change Alacritty's window title.
# dynamic_title: true
#cursor:
#style: Block
#vi_mode_style: None
#unfocused_hollow: true
#thickness: 0.15
#live_config_reload: true
#shell:
# program: /bin/bash
# args:
# - --login
#working_directory: None
#alt_send_esc: true
hints:
#alphabet: "jfkdls;ahgurieowpq"
enabled:
- regex: "(magnet|mailto|gemini|gopher|https|http|news|file|git|ssh|ftp):\
[^\u0000-\u001F\u007F-\u009F<>\"\\s{-}\\^⟨⟩`]+"
command: xdg-open
post_processing: true
mouse:
enabled: true
mods: None
binding:
key: U
mods: Control|Shift
#mouse:
#double_click: { threshold: 300 }
#triple_click: { threshold: 300 }
#hide_when_typing: false
key_bindings:
- { key: Return, mods: Control|Super, action: SpawnNewInstance }
#- { key: Paste, action: Paste }
#- { key: Copy, action: Copy }
#- { key: L, mods: Control, action: ClearLogNotice }
#- { key: L, mods: Control, mode: ~Vi, chars: "\x0c" }
#- { key: PageUp, mods: Shift, mode: ~Alt, action: ScrollPageUp, }
#- { key: PageDown, mods: Shift, mode: ~Alt, action: ScrollPageDown }
#- { key: Home, mods: Shift, mode: ~Alt, action: ScrollToTop, }
#- { key: End, mods: Shift, mode: ~Alt, action: ScrollToBottom }
# Vi Mode
#- { key: Space, mods: Shift|Control, mode: Vi, action: ScrollToBottom }
#- { key: Space, mods: Shift|Control, action: ToggleViMode }
#- { key: Escape, mode: Vi, action: ClearSelection }
#- { key: I, mode: Vi, action: ScrollToBottom }
#- { key: I, mode: Vi, action: ToggleViMode }
#- { key: Y, mods: Control, mode: Vi, action: ScrollLineUp }
#- { key: E, mods: Control, mode: Vi, action: ScrollLineDown }
#- { key: G, mode: Vi, action: ScrollToTop }
#- { key: G, mods: Shift, mode: Vi, action: ScrollToBottom }
#- { key: B, mods: Control, mode: Vi, action: ScrollPageUp }
#- { key: F, mods: Control, mode: Vi, action: ScrollPageDown }
#- { key: U, mods: Control, mode: Vi, action: ScrollHalfPageUp }
#- { key: D, mods: Control, mode: Vi, action: ScrollHalfPageDown }
#- { key: Y, mode: Vi, action: Copy }
#- { key: Y, mode: Vi, action: ClearSelection }
#- { key: Copy, mode: Vi, action: ClearSelection }
#- { key: V, mode: Vi, action: ToggleNormalSelection }
#- { key: V, mods: Shift, mode: Vi, action: ToggleLineSelection }
#- { key: V, mods: Control, mode: Vi, action: ToggleBlockSelection }
#- { key: V, mods: Alt, mode: Vi, action: ToggleSemanticSelection }
#- { key: Return, mode: Vi, action: Open }
#- { key: K, mode: Vi, action: Up }
#- { key: J, mode: Vi, action: Down }
#- { key: H, mode: Vi, action: Left }
#- { key: L, mode: Vi, action: Right }
#- { key: Up, mode: Vi, action: Up }
#- { key: Down, mode: Vi, action: Down }
#- { key: Left, mode: Vi, action: Left }
#- { key: Right, mode: Vi, action: Right }
#- { key: Key0, mode: Vi, action: First }
#- { key: Key4, mods: Shift, mode: Vi, action: Last }
#- { key: Key6, mods: Shift, mode: Vi, action: FirstOccupied }
#- { key: H, mods: Shift, mode: Vi, action: High }
#- { key: M, mods: Shift, mode: Vi, action: Middle }
#- { key: L, mods: Shift, mode: Vi, action: Low }
#- { key: B, mode: Vi, action: SemanticLeft }
#- { key: W, mode: Vi, action: SemanticRight }
#- { key: E, mode: Vi, action: SemanticRightEnd }
#- { key: B, mods: Shift, mode: Vi, action: WordLeft }
#- { key: W, mods: Shift, mode: Vi, action: WordRight }
#- { key: E, mods: Shift, mode: Vi, action: WordRightEnd }
#- { key: Key5, mods: Shift, mode: Vi, action: Bracket }
#- { key: Slash, mode: Vi, action: SearchForward }
#- { key: Slash, mods: Shift, mode: Vi, action: SearchBackward }
#- { key: N, mode: Vi, action: SearchNext }
#- { key: N, mods: Shift, mode: Vi, action: SearchPrevious }
# (Windows, Linux, and BSD only)
#- { key: V, mods: Control|Shift, action: Paste }
#- { key: C, mods: Control|Shift, action: Copy }
#- { key: F, mods: Control|Shift, action: SearchForward }
#- { key: B, mods: Control|Shift, action: SearchBackward }
#- { key: C, mods: Control|Shift, mode: Vi, action: ClearSelection }
#- { key: Insert, mods: Shift, action: PasteSelection }
#- { key: Key0, mods: Control, action: ResetFontSize }
#- { key: Equals, mods: Control, action: IncreaseFontSize }
#- { key: Add, mods: Control, action: IncreaseFontSize }
#- { key: Subtract, mods: Control, action: DecreaseFontSize }
#- { key: Minus, mods: Control, action: DecreaseFontSize }
# (Windows only)
#- { key: Return, mods: Alt, action: ToggleFullscreen }
# (macOS only)
#- { key: K, mods: Command, mode: ~Vi, chars: "\x0c" }
#- { key: Key0, mods: Command, action: ResetFontSize }
#- { key: Equals, mods: Command, action: IncreaseFontSize }
#- { key: Add, mods: Command, action: IncreaseFontSize }
#- { key: Minus, mods: Command, action: DecreaseFontSize }
#- { key: K, mods: Command, action: ClearHistory }
#- { key: V, mods: Command, action: Paste }
#- { key: C, mods: Command, action: Copy }
#- { key: C, mods: Command, mode: Vi, action: ClearSelection }
#- { key: H, mods: Command, action: Hide }
#- { key: M, mods: Command, action: Minimize }
#- { key: Q, mods: Command, action: Quit }
#- { key: W, mods: Command, action: Quit }
#- { key: N, mods: Command, action: SpawnNewInstance }
#- { key: F, mods: Command|Control, action: ToggleFullscreen }
#- { key: F, mods: Command, action: SearchForward }
#- { key: B, mods: Command, action: SearchBackward }
#debug:
#render_timer: false
#persistent_logging: false
#log_level: Warn
#print_events: false

View file

@ -0,0 +1,6 @@
Lightline colorschemes
======================
These are the color schemes for the Lightline plugin which sets the status
line. The light and dark one are pretty much the same except the `baseX` and
`base0X` colors are each swapped.

View file

@ -0,0 +1,57 @@
" -----------------------------------------------------------------------------
" File: gruvbox.vim
" Description: Gruvbox colorscheme for Lightline (itchyny/lightline.vim)
" Author: gmoe <me@griffinmoe.com>
" Source: https://github.com/morhetz/gruvbox
" Last Modified: 20 Sep 2017
" -----------------------------------------------------------------------------
function! s:getGruvColor(group)
let guiColor = synIDattr(hlID(a:group), "fg", "gui")
let termColor = synIDattr(hlID(a:group), "fg", "cterm")
return [ guiColor, termColor ]
endfunction
if exists('g:lightline')
let s:bg0 = s:getGruvColor('GruvboxBg0')
let s:bg1 = s:getGruvColor('GruvboxBg1')
let s:bg2 = s:getGruvColor('GruvboxBg2')
let s:bg4 = s:getGruvColor('GruvboxBg4')
let s:fg1 = s:getGruvColor('GruvboxFg1')
let s:fg4 = s:getGruvColor('GruvboxFg4')
let s:yellow = s:getGruvColor('GruvboxYellow')
let s:blue = s:getGruvColor('GruvboxBlue')
let s:aqua = s:getGruvColor('GruvboxAqua')
let s:orange = s:getGruvColor('GruvboxOrange')
let s:green = s:getGruvColor('GruvboxGreen')
let s:p = {'normal':{}, 'inactive':{}, 'insert':{}, 'replace':{}, 'visual':{}, 'tabline':{}, 'terminal':{}}
let s:p.normal.left = [ [ s:bg0, s:fg4, 'bold' ], [ s:fg4, s:bg2 ] ]
let s:p.normal.right = [ [ s:bg0, s:fg4 ], [ s:fg4, s:bg2 ] ]
let s:p.normal.middle = [ [ s:fg4, s:bg1 ] ]
let s:p.inactive.right = [ [ s:bg4, s:bg1 ], [ s:bg4, s:bg1 ] ]
let s:p.inactive.left = [ [ s:bg4, s:bg1 ], [ s:bg4, s:bg1 ] ]
let s:p.inactive.middle = [ [ s:bg4, s:bg1 ] ]
let s:p.insert.left = [ [ s:bg0, s:blue, 'bold' ], [ s:fg1, s:bg2 ] ]
let s:p.insert.right = [ [ s:bg0, s:blue ], [ s:fg1, s:bg2 ] ]
let s:p.insert.middle = [ [ s:fg4, s:bg2 ] ]
let s:p.terminal.left = [ [ s:bg0, s:green, 'bold' ], [ s:fg1, s:bg2 ] ]
let s:p.terminal.right = [ [ s:bg0, s:green ], [ s:fg1, s:bg2 ] ]
let s:p.terminal.middle = [ [ s:fg4, s:bg2 ] ]
let s:p.replace.left = [ [ s:bg0, s:aqua, 'bold' ], [ s:fg1, s:bg2 ] ]
let s:p.replace.right = [ [ s:bg0, s:aqua ], [ s:fg1, s:bg2 ] ]
let s:p.replace.middle = [ [ s:fg4, s:bg2 ] ]
let s:p.visual.left = [ [ s:bg0, s:orange, 'bold' ], [ s:bg0, s:bg4 ] ]
let s:p.visual.right = [ [ s:bg0, s:orange ], [ s:bg0, s:bg4 ] ]
let s:p.visual.middle = [ [ s:fg4, s:bg1 ] ]
let s:p.tabline.left = [ [ s:fg4, s:bg2 ] ]
let s:p.tabline.tabsel = [ [ s:bg0, s:fg4 ] ]
let s:p.tabline.middle = [ [ s:bg0, s:bg0 ] ]
let s:p.tabline.right = [ [ s:bg0, s:orange ] ]
let s:p.normal.error = [ [ s:bg0, s:orange ] ]
let s:p.normal.warning = [ [ s:bg2, s:yellow ] ]
let g:lightline#colorscheme#gruvbox#palette = lightline#colorscheme#flatten(s:p)
endif

View file

@ -0,0 +1,55 @@
" -----------------------------------------------------------------------------
" File: gruvbox_custom.vim
" -----------------------------------------------------------------------------
function! s:getGruvColor(group)
let guiColor = synIDattr(hlID(a:group), "fg", "gui")
let termColor = synIDattr(hlID(a:group), "fg", "cterm")
return [ guiColor, termColor ]
endfunction
if exists('g:lightline')
let s:bg0 = s:getGruvColor('GruvboxBg0')
let s:bg1 = s:getGruvColor('GruvboxBg1')
let s:bg2 = s:getGruvColor('GruvboxBg2')
let s:bg4 = s:getGruvColor('GruvboxBg4')
let s:fg1 = s:getGruvColor('GruvboxFg1')
let s:fg2 = s:getGruvColor('GruvboxFg2')
let s:fg4 = s:getGruvColor('GruvboxFg4')
let s:yellow = s:getGruvColor('GruvboxYellow')
let s:blue = s:getGruvColor('GruvboxBlue')
let s:aqua = s:getGruvColor('GruvboxAqua')
let s:orange = s:getGruvColor('GruvboxOrange')
let s:red = s:getGruvColor('GruvboxRed')
let s:green = s:getGruvColor('GruvboxGreen')
let s:p = {'normal':{}, 'inactive':{}, 'insert':{}, 'replace':{}, 'visual':{}, 'tabline':{}, 'terminal':{}}
let s:p.normal.left = [ [ s:bg0, s:fg4, 'bold' ], [ s:fg2, s:bg2 ] ]
let s:p.normal.right = [ [ s:bg0, s:fg4 ], [ s:fg2, s:bg2 ] ]
let s:p.normal.middle = [ [ s:fg4, s:bg1 ] ]
let s:p.inactive.right = [ [ s:bg4, s:bg1 ], [ s:bg4, s:bg1 ] ]
let s:p.inactive.left = [ [ s:bg4, s:bg1 ], [ s:bg4, s:bg1 ] ]
let s:p.inactive.middle = [ [ s:bg4, s:bg1 ] ]
let s:p.insert.left = [ [ s:bg0, s:blue, 'bold' ], [ s:fg2, s:bg2 ] ]
let s:p.insert.right = [ [ s:bg0, s:blue ], [ s:fg2, s:bg2 ] ]
let s:p.insert.middle = [ [ s:fg4, s:bg1 ] ]
let s:p.terminal.left = [ [ s:bg0, s:green, 'bold' ], [ s:fg2, s:bg2 ] ]
let s:p.terminal.right = [ [ s:bg0, s:green ], [ s:fg2, s:bg2 ] ]
let s:p.terminal.middle = [ [ s:fg4, s:bg1 ] ]
let s:p.replace.left = [ [ s:bg0, s:aqua, 'bold' ], [ s:fg2, s:bg2 ] ]
let s:p.replace.right = [ [ s:bg0, s:aqua ], [ s:fg2, s:bg2 ] ]
let s:p.replace.middle = [ [ s:fg4, s:bg1 ] ]
let s:p.visual.left = [ [ s:bg0, s:yellow, 'bold' ], [ s:bg0, s:bg4 ] ]
let s:p.visual.right = [ [ s:bg0, s:yellow ], [ s:bg0, s:bg4 ] ]
let s:p.visual.middle = [ [ s:fg4, s:bg1 ] ]
let s:p.tabline.left = [ [ s:fg4, s:bg2 ] ]
let s:p.tabline.tabsel = [ [ s:bg0, s:fg4 ] ]
let s:p.tabline.middle = [ [ s:bg0, s:bg0 ] ]
let s:p.tabline.right = [ [ s:bg0, s:orange ] ]
let s:p.normal.error = [ [ s:bg0, s:red ] ]
let s:p.normal.warning = [ [ s:bg2, s:orange ] ]
let g:lightline#colorscheme#gruvbox_custom#palette = lightline#colorscheme#flatten(s:p)
endif

View file

@ -0,0 +1,59 @@
" [onedark.vim](https://github.com/joshdick/onedark.vim/)
" This is a [lightline.vim](https://github.com/itchyny/lightline.vim) colorscheme for use with
" the [onedark.vim](https://github.com/joshdick/onedark.vim) colorscheme.
let s:colors = onedark#GetColors()
if get(g:, 'onedark_termcolors', 256) == 16
let s:term_red = s:colors.red.cterm16
let s:term_green = s:colors.green.cterm16
let s:term_yellow = s:colors.yellow.cterm16
let s:term_blue = s:colors.blue.cterm16
let s:term_purple = s:colors.purple.cterm16
let s:term_white = s:colors.white.cterm16
let s:term_black = s:colors.black.cterm16
let s:term_grey = s:colors.cursor_grey.cterm16
else
let s:term_red = s:colors.red.cterm
let s:term_green = s:colors.green.cterm
let s:term_yellow = s:colors.yellow.cterm
let s:term_blue = s:colors.blue.cterm
let s:term_purple = s:colors.purple.cterm
let s:term_white = s:colors.white.cterm
let s:term_black = s:colors.black.cterm
let s:term_grey = s:colors.cursor_grey.cterm
endif
let s:red = [ s:colors.red.gui, s:term_red ]
let s:green = [ s:colors.green.gui, s:term_green ]
let s:yellow = [ s:colors.yellow.gui, s:term_yellow ]
let s:blue = [ s:colors.blue.gui, s:term_blue ]
let s:purple = [ s:colors.purple.gui, s:term_purple ]
let s:white = [ s:colors.white.gui, s:term_white ]
let s:black = [ s:colors.black.gui, s:term_black ]
let s:grey = [ s:colors.visual_grey.gui, s:term_grey ]
let s:p = {'normal': {}, 'inactive': {}, 'insert': {}, 'replace': {}, 'visual': {}, 'tabline': {}}
let s:p.normal.left = [ [ s:black, s:green ], [ s:white, s:grey ] ]
let s:p.normal.right = [ [ s:black, s:green ], [ s:white, s:grey ] ]
let s:p.inactive.left = [ [ s:white, s:grey ], [ s:white, s:grey ] ]
let s:p.inactive.right = [ [ s:black, s:white ], [ s:black, s:white ] ]
let s:p.insert.left = [ [ s:black, s:blue ], [ s:white, s:grey ] ]
let s:p.insert.right = [ [ s:black, s:blue ], [ s:white, s:grey ] ]
let s:p.replace.left = [ [ s:black, s:red ], [ s:white, s:grey ] ]
let s:p.replace.right = [ [ s:black, s:red ], [ s:white, s:grey ] ]
let s:p.visual.left = [ [ s:black, s:purple ], [ s:white, s:grey ] ]
let s:p.visual.right = [ [ s:black, s:purple ], [ s:white, s:grey ] ]
let s:p.normal.middle = [ [ s:white, s:black ] ]
let s:p.inactive.middle = [ [ s:white, s:grey ] ]
let s:p.tabline.left = [ [ s:white, s:grey ] ]
let s:p.tabline.tabsel = [ [ s:black, s:white ] ]
let s:p.tabline.middle = [ [ s:white, s:black ] ]
let s:p.tabline.right = [ [ s:white, s:grey ] ]
let s:p.normal.error = [ [ s:black, s:red ] ]
let s:p.normal.warning = [ [ s:black, s:yellow ] ]
let g:lightline#colorscheme#onedark#palette = lightline#colorscheme#flatten(s:p)

View file

@ -0,0 +1,47 @@
" =============================================================================
" Filename: autoload/lightline/colorscheme/termcolors.vim
" =============================================================================
let s:mono0 = [ '#14171d', 236 ]
let s:mono1 = [ '#4d4754', 238 ]
let s:mono2 = [ '#ada0a8', 243 ]
let s:mono3 = [ '#c7c6c3', 255 ]
let s:yellow = [ '#f0c767', 180 ]
let s:red = [ '#cc5c5c', 168 ]
let s:magenta = [ '#a97fb3', 176 ]
let s:blue = [ '#789ebf', 75 ]
let s:cyan = [ '#82bfb3', 73 ]
let s:green = [ '#97bd5e', 114 ]
let s:p = {'normal': {}, 'inactive': {}, 'insert': {}, 'replace': {}, 'visual': {}, 'tabline': {}}
let s:p.normal.left = [ [ s:mono0, s:green ], [ s:mono3, s:mono2 ] ]
let s:p.normal.middle = [ [ s:green, s:mono1 ] ]
let s:p.normal.right = [ [ s:mono0, s:green ], [ s:mono3, s:mono2 ] ]
let s:p.normal.error = [ [ s:mono0, s:red ] ]
let s:p.normal.warning = [ [ s:mono0, s:yellow ] ]
let s:p.inactive.left = [ [ s:mono3, s:mono2 ], [ s:mono3, s:mono2 ] ]
let s:p.inactive.middle = [ [ s:mono3, s:mono1 ] ]
let s:p.inactive.right = [ [ s:mono0, s:mono3 ], [ s:mono3, s:mono2 ] ]
let s:p.insert.left = [ [ s:mono0, s:blue ], [ s:mono3, s:mono2 ] ]
let s:p.insert.middle = [ [ s:blue, s:mono1 ] ]
let s:p.insert.right = [ [ s:mono0, s:blue ], [ s:mono3, s:mono2 ] ]
let s:p.replace.left = [ [ s:mono0, s:red ], [ s:mono3, s:mono2 ] ]
let s:p.replace.middle = [ [ s:red, s:mono1 ] ]
let s:p.replace.right = [ [ s:mono0, s:red ], [ s:mono3, s:mono2 ] ]
let s:p.visual.left = [ [ s:mono0, s:yellow ], [ s:mono3, s:mono2 ] ]
let s:p.visual.middle = [ [ s:yellow, s:mono1 ] ]
let s:p.visual.right = [ [ s:mono0, s:yellow ], [ s:mono3, s:mono2 ] ]
let s:p.tabline.left = [ [ s:mono2, s:mono1] ]
let s:p.tabline.tabsel = [ [ s:mono3, s:mono2 ] ]
let s:p.tabline.middle = [ [ s:mono2, s:mono1] ]
let s:p.tabline.right = [ [ s:mono0, s:mono3 ] ]
let g:lightline#colorscheme#termcolors#palette = lightline#colorscheme#flatten(s:p)

View file

@ -0,0 +1,264 @@
" pathogen.vim - path option manipulation
" Maintainer: Tim Pope <http://tpo.pe/>
" Version: 2.4
" Install in ~/.vim/autoload (or ~\vimfiles\autoload).
"
" For management of individually installed plugins in ~/.vim/bundle (or
" ~\vimfiles\bundle), adding `execute pathogen#infect()` to the top of your
" .vimrc is the only other setup necessary.
"
" The API is documented inline below.
if exists("g:loaded_pathogen") || &cp
finish
endif
let g:loaded_pathogen = 1
" Point of entry for basic default usage. Give a relative path to invoke
" pathogen#interpose() or an absolute path to invoke pathogen#surround().
" Curly braces are expanded with pathogen#expand(): "bundle/{}" finds all
" subdirectories inside "bundle" inside all directories in the runtime path.
" If no arguments are given, defaults "bundle/{}", and also "pack/{}/start/{}"
" on versions of Vim without native package support.
function! pathogen#infect(...) abort
if a:0
let paths = filter(reverse(copy(a:000)), 'type(v:val) == type("")')
else
let paths = ['bundle/{}', 'pack/{}/start/{}']
endif
if has('packages')
call filter(paths, 'v:val !~# "^pack/[^/]*/start/[^/]*$"')
endif
let static = '^\%([$~\\/]\|\w:[\\/]\)[^{}*]*$'
for path in filter(copy(paths), 'v:val =~# static')
call pathogen#surround(path)
endfor
for path in filter(copy(paths), 'v:val !~# static')
if path =~# '^\%([$~\\/]\|\w:[\\/]\)'
call pathogen#surround(path)
else
call pathogen#interpose(path)
endif
endfor
call pathogen#cycle_filetype()
if pathogen#is_disabled($MYVIMRC)
return 'finish'
endif
return ''
endfunction
" Split a path into a list.
function! pathogen#split(path) abort
if type(a:path) == type([]) | return a:path | endif
if empty(a:path) | return [] | endif
let split = split(a:path,'\\\@<!\%(\\\\\)*\zs,')
return map(split,'substitute(v:val,''\\\([\\,]\)'',''\1'',"g")')
endfunction
" Convert a list to a path.
function! pathogen#join(...) abort
if type(a:1) == type(1) && a:1
let i = 1
let space = ' '
else
let i = 0
let space = ''
endif
let path = ""
while i < a:0
if type(a:000[i]) == type([])
let list = a:000[i]
let j = 0
while j < len(list)
let escaped = substitute(list[j],'[,'.space.']\|\\[\,'.space.']\@=','\\&','g')
let path .= ',' . escaped
let j += 1
endwhile
else
let path .= "," . a:000[i]
endif
let i += 1
endwhile
return substitute(path,'^,','','')
endfunction
" Convert a list to a path with escaped spaces for 'path', 'tag', etc.
function! pathogen#legacyjoin(...) abort
return call('pathogen#join',[1] + a:000)
endfunction
" Turn filetype detection off and back on again if it was already enabled.
function! pathogen#cycle_filetype() abort
if exists('g:did_load_filetypes')
filetype off
filetype on
endif
endfunction
" Check if a bundle is disabled. A bundle is considered disabled if its
" basename or full name is included in the list g:pathogen_blacklist or the
" comma delimited environment variable $VIMBLACKLIST.
function! pathogen#is_disabled(path) abort
if a:path =~# '\~$'
return 1
endif
let sep = pathogen#slash()
let blacklist = get(g:, 'pathogen_blacklist', get(g:, 'pathogen_disabled', [])) + pathogen#split($VIMBLACKLIST)
if !empty(blacklist)
call map(blacklist, 'substitute(v:val, "[\\/]$", "", "")')
endif
return index(blacklist, fnamemodify(a:path, ':t')) != -1 || index(blacklist, a:path) != -1
endfunction
" Prepend the given directory to the runtime path and append its corresponding
" after directory. Curly braces are expanded with pathogen#expand().
function! pathogen#surround(path) abort
let sep = pathogen#slash()
let rtp = pathogen#split(&rtp)
let path = fnamemodify(a:path, ':s?[\\/]\=$??')
let before = filter(pathogen#expand(path), '!pathogen#is_disabled(v:val)')
let after = filter(reverse(pathogen#expand(path, sep.'after')), '!pathogen#is_disabled(v:val[0:-7])')
call filter(rtp, 'index(before + after, v:val) == -1')
let &rtp = pathogen#join(before, rtp, after)
return &rtp
endfunction
" For each directory in the runtime path, add a second entry with the given
" argument appended. Curly braces are expanded with pathogen#expand().
function! pathogen#interpose(name) abort
let sep = pathogen#slash()
let name = a:name
if has_key(s:done_bundles, name)
return ""
endif
let s:done_bundles[name] = 1
let list = []
for dir in pathogen#split(&rtp)
if dir =~# '\<after$'
let list += reverse(filter(pathogen#expand(dir[0:-6].name, sep.'after'), '!pathogen#is_disabled(v:val[0:-7])')) + [dir]
else
let list += [dir] + filter(pathogen#expand(dir.sep.name), '!pathogen#is_disabled(v:val)')
endif
endfor
let &rtp = pathogen#join(pathogen#uniq(list))
return 1
endfunction
let s:done_bundles = {}
" Invoke :helptags on all non-$VIM doc directories in runtimepath.
function! pathogen#helptags() abort
let sep = pathogen#slash()
for glob in pathogen#split(&rtp)
for dir in map(split(glob(glob), "\n"), 'v:val.sep."/doc/".sep')
if (dir)[0 : strlen($VIMRUNTIME)] !=# $VIMRUNTIME.sep && filewritable(dir) == 2 && !empty(split(glob(dir.'*.txt'))) && (!filereadable(dir.'tags') || filewritable(dir.'tags'))
silent! execute 'helptags' pathogen#fnameescape(dir)
endif
endfor
endfor
endfunction
command! -bar Helptags :call pathogen#helptags()
" Execute the given command. This is basically a backdoor for --remote-expr.
function! pathogen#execute(...) abort
for command in a:000
execute command
endfor
return ''
endfunction
" Section: Unofficial
function! pathogen#is_absolute(path) abort
return a:path =~# (has('win32') ? '^\%([\\/]\|\w:\)[\\/]\|^[~$]' : '^[/~$]')
endfunction
" Given a string, returns all possible permutations of comma delimited braced
" alternatives of that string. pathogen#expand('/{a,b}/{c,d}') yields
" ['/a/c', '/a/d', '/b/c', '/b/d']. Empty braces are treated as a wildcard
" and globbed. Actual globs are preserved.
function! pathogen#expand(pattern, ...) abort
let after = a:0 ? a:1 : ''
let pattern = substitute(a:pattern, '^[~$][^\/]*', '\=expand(submatch(0))', '')
if pattern =~# '{[^{}]\+}'
let [pre, pat, post] = split(substitute(pattern, '\(.\{-\}\){\([^{}]\+\)}\(.*\)', "\\1\001\\2\001\\3", ''), "\001", 1)
let found = map(split(pat, ',', 1), 'pre.v:val.post')
let results = []
for pattern in found
call extend(results, pathogen#expand(pattern))
endfor
elseif pattern =~# '{}'
let pat = matchstr(pattern, '^.*{}[^*]*\%($\|[\\/]\)')
let post = pattern[strlen(pat) : -1]
let results = map(split(glob(substitute(pat, '{}', '*', 'g')), "\n"), 'v:val.post')
else
let results = [pattern]
endif
let vf = pathogen#slash() . 'vimfiles'
call map(results, 'v:val =~# "\\*" ? v:val.after : isdirectory(v:val.vf.after) ? v:val.vf.after : isdirectory(v:val.after) ? v:val.after : ""')
return filter(results, '!empty(v:val)')
endfunction
" \ on Windows unless shellslash is set, / everywhere else.
function! pathogen#slash() abort
return !exists("+shellslash") || &shellslash ? '/' : '\'
endfunction
function! pathogen#separator() abort
return pathogen#slash()
endfunction
" Convenience wrapper around glob() which returns a list.
function! pathogen#glob(pattern) abort
let files = split(glob(a:pattern),"\n")
return map(files,'substitute(v:val,"[".pathogen#slash()."/]$","","")')
endfunction
" Like pathogen#glob(), only limit the results to directories.
function! pathogen#glob_directories(pattern) abort
return filter(pathogen#glob(a:pattern),'isdirectory(v:val)')
endfunction
" Remove duplicates from a list.
function! pathogen#uniq(list) abort
let i = 0
let seen = {}
while i < len(a:list)
if (a:list[i] ==# '' && exists('empty')) || has_key(seen,a:list[i])
call remove(a:list,i)
elseif a:list[i] ==# ''
let i += 1
let empty = 1
else
let seen[a:list[i]] = 1
let i += 1
endif
endwhile
return a:list
endfunction
" Backport of fnameescape().
function! pathogen#fnameescape(string) abort
if exists('*fnameescape')
return fnameescape(a:string)
elseif a:string ==# '-'
return '\-'
else
return substitute(escape(a:string," \t\n*?[{`$\\%#'\"|!<"),'^[+>]','\\&','')
endif
endfunction
" Like findfile(), but hardcoded to use the runtimepath.
function! pathogen#runtime_findfile(file,count) abort
let rtp = pathogen#join(1,pathogen#split(&rtp))
let file = findfile(a:file,rtp,a:count)
if file ==# ''
return ''
else
return fnamemodify(file,':p')
endif
endfunction
" vim:set et sw=2 foldmethod=expr foldexpr=getline(v\:lnum)=~'^\"\ Section\:'?'>1'\:getline(v\:lnum)=~#'^fu'?'a1'\:getline(v\:lnum)=~#'^endf'?'s1'\:'=':

@ -0,0 +1 @@
Subproject commit cf6dd11baf62fb6ce18308e96c0ab43428b7c686

@ -0,0 +1 @@
Subproject commit b255382d6242d7ea3877bf059d2934125e0c4d95

@ -0,0 +1 @@
Subproject commit f35d02204b4813d1dbe8b0e98cc39701a4b8e15e

@ -0,0 +1 @@
Subproject commit c7abd7827f41056b134002eea986518d90215a67

@ -0,0 +1 @@
Subproject commit b1e91b41f5028d65fa3d31a425ff21591d5d957f

@ -0,0 +1 @@
Subproject commit fc85a6f07c2cd694be93496ffad75be126240068

@ -0,0 +1 @@
Subproject commit 2cc00ba72929ea5f9456a26782db57fb4cc56a65

@ -0,0 +1 @@
Subproject commit 339091ac4dd1f17e225fe7d57b48aff55f99b23a

@ -0,0 +1 @@
Subproject commit 0afd43425bc54a13ef59c0ac902c48a4eae399c2

@ -0,0 +1 @@
Subproject commit d0a562f8bdb107a50595aefe53b1a690460c3822

@ -0,0 +1 @@
Subproject commit bfd330a271933c3372fcfa8ce052970746c8e9dd

@ -0,0 +1 @@
Subproject commit 5d3d1b6cbdc4be0b4c6105c1ab1f769d76d3c68f

@ -0,0 +1 @@
Subproject commit 7668b018fe9461c6b51e0b736ed84aa84d6bafce

@ -0,0 +1 @@
Subproject commit a7eea09ba654a371a90ca77186bf10930b897e80

@ -0,0 +1 @@
Subproject commit 9555a3e6e5bcf285ec181b7fc983eea90500feb4

@ -0,0 +1 @@
Subproject commit d36caa6b1cf508a4df1c691f915572fc02143258

@ -0,0 +1 @@
Subproject commit 63af6e72dd3fa840bffb3ebcb8c96970c02e0913

View file

@ -0,0 +1,218 @@
" ==============================================================================
" Name: Termcolors
"
" Based on OneHalf
" ==============================================================================
set background=dark
highlight clear
syntax reset
let g:colors_name="termcolors"
let colors_name="termcolors"
let s:red = { "gui": "#cc5c5c", "cterm": "167" }
let s:green = { "gui": "#97bd5e", "cterm": "107" }
let s:yellow = { "gui": "#f0c767", "cterm": "222" }
let s:blue = { "gui": "#789ebf", "cterm": "110" }
let s:purple = { "gui": "#a97fb3", "cterm": "139" }
let s:cyan = { "gui": "#82bfb3", "cterm": "109" }
let s:black = { "gui": "0", "cterm": "0" }
let s:darkgray = { "gui": "#2c2b3b", "cterm": "236" }
let s:gray = { "gui": "#4d4754", "cterm": "239" }
let s:lightgray = { "gui": "#ada0a8", "cterm": "248" }
let s:white = { "gui": "#c7c6c3", "cterm": "251" }
let s:fg = s:white
let s:bg = s:black
let s:comment_fg = s:gray
let s:gutter_bg = s:darkgray
let s:gutter_fg = s:lightgray
let s:cursor_line = s:lightgray
let s:color_col = s:lightgray
let s:selection = s:lightgray
let s:vertsplit = s:lightgray
function! s:h(group, fg, bg, attr)
if type(a:fg) == type({})
exec "hi " . a:group . " guifg=" . a:fg.gui . " ctermfg=" . a:fg.cterm
else
exec "hi " . a:group . " guifg=NONE cterm=NONE"
endif
if type(a:bg) == type({})
exec "hi " . a:group . " guibg=" . a:bg.gui . " ctermbg=" . a:bg.cterm
else
exec "hi " . a:group . " guibg=NONE ctermbg=NONE"
endif
if a:attr != ""
exec "hi " . a:group . " gui=" . a:attr . " cterm=" . a:attr
else
exec "hi " . a:group . " gui=NONE cterm=NONE"
endif
endfun
" User interface colors {
call s:h("Normal", s:fg, s:bg, "")
call s:h("NonText", s:fg, "", "")
call s:h("Cursor", s:bg, s:blue, "")
call s:h("CursorColumn", "", s:cursor_line, "")
call s:h("CursorLine", "", s:cursor_line, "")
call s:h("LineNr", s:gutter_fg, s:gutter_bg, "")
call s:h("CursorLineNr", s:fg, "", "")
call s:h("DiffAdd", s:green, "", "")
call s:h("DiffChange", s:yellow, "", "")
call s:h("DiffDelete", s:red, "", "")
call s:h("DiffText", s:blue, "", "")
call s:h("IncSearch", s:bg, s:yellow, "")
call s:h("Search", s:bg, s:yellow, "")
call s:h("ErrorMsg", s:fg, "", "")
call s:h("ModeMsg", s:fg, "", "")
call s:h("MoreMsg", s:fg, "", "")
call s:h("WarningMsg", s:red, "", "")
call s:h("Question", s:purple, "", "")
call s:h("Pmenu", s:bg, s:fg, "")
call s:h("PmenuSel", s:fg, s:blue, "")
call s:h("PmenuSbar", "", s:selection, "")
call s:h("PmenuThumb", "", s:fg, "")
call s:h("SpellBad", s:red, "", "")
call s:h("SpellCap", s:yellow, "", "")
call s:h("SpellLocal", s:yellow, "", "")
call s:h("SpellRare", s:yellow, "", "")
call s:h("StatusLine", s:blue, s:cursor_line, "")
call s:h("StatusLineNC", s:comment_fg, s:cursor_line, "")
call s:h("TabLine", s:comment_fg, s:cursor_line, "")
call s:h("TabLineFill", s:comment_fg, s:cursor_line, "")
call s:h("TabLineSel", s:fg, s:bg, "")
call s:h("Visual", "", s:selection, "")
call s:h("VisualNOS", "", s:selection, "")
call s:h("ColorColumn", "", s:color_col, "")
call s:h("Conceal", s:fg, "", "")
call s:h("Directory", s:blue, "", "")
call s:h("VertSplit", s:vertsplit, s:vertsplit, "")
call s:h("Folded", s:fg, "", "")
call s:h("FoldColumn", s:fg, "", "")
call s:h("SignColumn", s:fg, "", "")
call s:h("MatchParen", s:blue, "", "underline")
call s:h("SpecialKey", s:fg, "", "")
call s:h("Title", s:green, "", "")
call s:h("WildMenu", s:fg, "", "")
" }
" Syntax colors {
call s:h("Comment", s:comment_fg, "", "italic")
call s:h("Constant", s:cyan, "", "")
call s:h("String", s:green, "", "")
call s:h("Character", s:green, "", "")
call s:h("Number", s:yellow, "", "")
call s:h("Boolean", s:yellow, "", "")
call s:h("Float", s:yellow, "", "")
call s:h("Identifier", s:red, "", "italic")
call s:h("Function", s:blue, "", "")
call s:h("Statement", s:purple, "", "")
call s:h("Conditional", s:purple, "", "")
call s:h("Repeat", s:purple, "", "")
call s:h("Label", s:purple, "", "")
call s:h("Operator", s:fg, "", "")
call s:h("Keyword", s:red, "", "")
call s:h("Exception", s:purple, "", "")
call s:h("PreProc", s:yellow, "", "")
call s:h("Include", s:blue, "", "")
call s:h("Define", s:purple, "", "")
call s:h("Macro", s:purple, "", "")
call s:h("PreCondit", s:yellow, "", "")
call s:h("Type", s:yellow, "", "")
call s:h("StorageClass", s:yellow, "", "")
call s:h("Structure", s:yellow, "", "")
call s:h("Typedef", s:yellow, "", "")
call s:h("Special", s:yellow, "", "")
call s:h("SpecialChar", s:fg, "", "")
call s:h("Tag", s:fg, "", "")
call s:h("Delimiter", s:fg, "", "")
call s:h("SpecialComment", s:fg, "", "italic")
call s:h("Debug", s:fg, "", "")
call s:h("Underlined", s:fg, "", "underline")
call s:h("Ignore", s:lightgray, "", "")
call s:h("Error", s:red, s:gutter_bg, "")
call s:h("Todo", s:purple, "", "")
" }
" Plugins {
" GitGutter
call s:h("GitGutterAdd", s:green, s:gutter_bg, "")
call s:h("GitGutterDelete", s:red, s:gutter_bg, "")
call s:h("GitGutterChange", s:yellow, s:gutter_bg, "")
call s:h("GitGutterChangeDelete", s:red, s:gutter_bg, "")
" Fugitive
call s:h("diffAdded", s:green, "", "")
call s:h("diffRemoved", s:red, "", "")
" }
" Git {
call s:h("gitcommitComment", s:comment_fg, "", "")
call s:h("gitcommitUnmerged", s:red, "", "")
call s:h("gitcommitOnBranch", s:fg, "", "")
call s:h("gitcommitBranch", s:purple, "", "")
call s:h("gitcommitDiscardedType", s:red, "", "")
call s:h("gitcommitSelectedType", s:green, "", "")
call s:h("gitcommitHeader", s:fg, "", "")
call s:h("gitcommitUntrackedFile", s:cyan, "", "")
call s:h("gitcommitDiscardedFile", s:red, "", "")
call s:h("gitcommitSelectedFile", s:green, "", "")
call s:h("gitcommitUnmergedFile", s:yellow, "", "")
call s:h("gitcommitFile", s:fg, "", "")
hi link gitcommitNoBranch gitcommitBranch
hi link gitcommitUntracked gitcommitComment
hi link gitcommitDiscarded gitcommitComment
hi link gitcommitSelected gitcommitComment
hi link gitcommitDiscardedArrow gitcommitDiscardedFile
hi link gitcommitSelectedArrow gitcommitSelectedFile
hi link gitcommitUnmergedArrow gitcommitUnmergedFile
" }
" Fix colors in neovim terminal buffers {
if has('nvim')
let g:terminal_color_0 = s:black.gui
let g:terminal_color_1 = s:red.gui
let g:terminal_color_2 = s:green.gui
let g:terminal_color_3 = s:yellow.gui
let g:terminal_color_4 = s:blue.gui
let g:terminal_color_5 = s:purple.gui
let g:terminal_color_6 = s:cyan.gui
let g:terminal_color_7 = s:white.gui
let g:terminal_color_8 = s:black.gui
let g:terminal_color_9 = s:red.gui
let g:terminal_color_10 = s:green.gui
let g:terminal_color_11 = s:yellow.gui
let g:terminal_color_12 = s:blue.gui
let g:terminal_color_13 = s:purple.gui
let g:terminal_color_14 = s:cyan.gui
let g:terminal_color_15 = s:white.gui
let g:terminal_color_background = s:bg.gui
let g:terminal_color_foreground = s:fg.gui
endif
" }

112
.config/nvim/init.vim Executable file
View file

@ -0,0 +1,112 @@
let mapleader =","
set nocompatible
filetype off
execute pathogen#infect()
set rtp+=~/.config/nvim/bundle/Vundle.vim
call vundle#begin()
Plugin 'VundleVim/Vundle.vim'
let $NVIM_TUI_ENABLE_TRUE_COLOR=1
let &t_8f = "\<Esc>[38:2:%lu:%lu:%lum"
let &t_8b = "\<Esc>[48:2:%lu:%lu:%lum"
set termguicolors
colo termcolors
let g:python_highlight_all = 1
syntax on
filetype plugin indent on
autocmd BufNewFile,BufRead,BufWritePost *.zsh-theme set syntax=zsh
autocmd BufNewFile,BufRead,BufWritePost *.lalrpop set syntax=rust
autocmd BufNewFile,BufRead,BufWritePost *.cxpr set syntax=complexpr
nnoremap <leader>B :call box#Draw()<CR>
" settings
set autoindent
set hlsearch
set tabstop=4
set shiftwidth=0
set expandtab
set number relativenumber
set encoding=utf-8
set nofoldenable
set laststatus=2
set noshowmode
set modeline
set mouse=a
let g:lightline = {
\ 'colorscheme': 'termcolors',
\ }
let g:LanguageClient_serverCommands = {
\ 'rust': ['rust-analyzer'],
\ }
" Custom bindings for system copy-paste
nmap <C-y> "+yy
nmap <C-x> "+cc
nmap <C-p> "+p
vmap <C-y> "+y
vmap <C-x> "+c
vmap <C-p> "+p
" Switching tabs
nmap <A-TAB> :tabedit
nmap <A-1> 1gt
nmap <A-2> 2gt
nmap <A-3> 3gt
nmap <A-4> 4gt
nmap <A-5> 5gt
nmap <A-6> 6gt
nmap <A-7> 7gt
nmap <A-8> 8gt
nmap <A-9> 9gt
nmap <A-0> 10gt
nmap H gT
nmap L gt
" Split navigation
set splitbelow
set splitright
nmap <A-h> <C-w>h
nmap <A-j> <C-w>j
nmap <A-k> <C-w>k
nmap <A-l> <C-w>l
" hexHighlight plugin
nmap <leader>h <Plug>ToggleHexHighlight
nmap <leader>H <Plug>ToggleSchemeHighlight
" Remove arrow key functionality
noremap <Up> <Nop>
noremap <Down> <Nop>
noremap <Left> <Nop>
noremap <Right> <Nop>
inoremap <Up> <Nop>
inoremap <Down> <Nop>
inoremap <Left> <Nop>
inoremap <Right> <Nop>
" remove ex mode shortcut
map Q <Nop>
" Run file from shell
nnoremap <leader>r :w<CR>:!%:p<CR>
" Map <leader><leader> to stop highlighting matches
map <leader><leader> :noh<CR>
" VimWiki bindings
map <leader><CR>t :VimwikiTabnewLink<CR>
map <leader><CR>s :VimwikiSplitLink<CR>
" resize automatically
autocmd VimEnter * :silent exec "!kill -s SIGWINCH $PPID"

178
.config/sway/config Normal file
View file

@ -0,0 +1,178 @@
#
# Copy this to ~/.config/sway/config and edit it to your liking.
#
# Read `man 5 sway` for a complete reference.
set $mod Mod4
set $left h
set $down j
set $up k
set $right l
set $term alacritty
set $browser librewolf
# Note: pass the final command to swaymsg so that the resulting window can be opened
set $menu wofi -S run | xargs swaymsg exec --
exec --no-startup-id ydotoold
exec --no-startup-id dunst -b
exec --no-startup-id rand-wallpaper
exec --no-startup-id webcord.sh
exec --no-startup-id autotiling
exec --no-startup-id nm-applet --indicator
exec --no-startup-id mqtt_notify.lua >/tmp/mqtt_notify.log
exec --no-startup-id element-desktop
exec --no-startup-id "sleep 1; nextcloud"
assign [class="Element"] workspace number 8
assign [app_id="WebCord"] workspace number 9
workspace 1 output DP-1
workspace 9 output eDP-1
for_window [app_id="scratch_term"] move scratchpad, resize set 960 640
for_window [app_id="scratch_calc"] move scratchpad, resize set 960 640
for_window [app_id="scratch_cmus"] move scratchpad, resize set 960 640
for_window [app_id="scratch_htop"] move scratchpad, resize set 960 640
# gnome time
set $gnome-schema org.gnome.desktop.interface
exec_always {
gsettings set $gnome-schema gtk-theme 'Adwaita-dark'
gsettings set $gnome-schema icon-theme 'Adwaita'
gsettings set $gnome-schema font-name 'Cantarell 11'
gsettings set org.gnome.desktop.default-applications.terminal exec $term
}
# swaymsg -t get_outputs
output eDP-1 resolution 3840x2400 position 2133,0
output DP-1 resolution 2560x1440 position 0,0 scale 1.2
#output eDP-1 resolution 3840x2400 position 1920,0
#output DP-1 resolution 1920x1080 position 0,0
input "type:keyboard" {
xkb_layout us
xkb_options compose:menu,caps:escape
}
# Idle configuration
exec swayidle -w \
timeout 300 'swaylock -f -c 14171d' \
timeout 300 'swaymsg "output * dpms off"' resume 'swaymsg "output * dpms on"' \
before-sleep 'swaylock -f -c 14171d'
floating_modifier $mod normal
gaps inner 16
default_border pixel 2
default_floating_border pixel 2
# Key bindings
bindsym $mod+Shift+Escape exit
bindsym Print exec screenshot
bindsym Shift+Print exec slurp -p | grim -g - - | convert - txt:- | tail -n 1 | awk '{print $3}' | wl-copy
bindsym $mod+Return exec $term
bindsym $mod+space focus mode_toggle
bindsym XF86AudioRaiseVolume exec pactl set-sink-volume @DEFAULT_SINK@ +5%
bindsym XF86AudioLowerVolume exec pactl set-sink-volume @DEFAULT_SINK@ -5%
bindsym XF86AudioMute exec pactl set-sink-mute @DEFAULT_SINK@ toggle
bindsym XF86AudioMicMute exec pactl set-source-mute @DEFAULT_SOURCE@ toggle
bindsym XF86MonBrightnessDown exec brightnessctl set 5%-
bindsym XF86MonBrightnessUp exec brightnessctl set 5%+
bindsym XF86AudioPlay exec playerctl play-pause
bindsym XF86AudioNext exec playerctl next
bindsym XF86AudioPrev exec playerctl previous
bindsym XF86Search exec $menu
bindsym $mod+F5 reload
bindsym $mod+F2 exec mpv ~/videos/soviet.webm
bindsym $mod+1 workspace number 1
bindsym $mod+2 workspace number 2
bindsym $mod+3 workspace number 3
bindsym $mod+4 workspace number 4
bindsym $mod+5 workspace number 5
bindsym $mod+6 workspace number 6
bindsym $mod+7 workspace number 7
bindsym $mod+8 workspace number 8
bindsym $mod+9 workspace number 9
bindsym $mod+Shift+1 move container to workspace number 1
bindsym $mod+Shift+2 move container to workspace number 2
bindsym $mod+Shift+3 move container to workspace number 3
bindsym $mod+Shift+4 move container to workspace number 4
bindsym $mod+Shift+5 move container to workspace number 5
bindsym $mod+Shift+6 move container to workspace number 6
bindsym $mod+Shift+7 move container to workspace number 7
bindsym $mod+Shift+8 move container to workspace number 8
bindsym $mod+Shift+9 move container to workspace number 9
# Kill focused window
bindsym $mod+q kill
bindsym $mod+Shift+q exec xkill
bindsym $mod+w exec $browser
bindsym $mod+e move workspace to output left
bindsym $mod+r move workspace to output right
bindsym $mod+t floating toggle
bindsym $mod+y exec ~/.config/sway/scratchpads.sh scratch_term zsh
bindsym $mod+u exec dmenu_specialchars
bindsym $mod+Shift+u exec dmenu_unicode
bindsym $mod+i exec ~/.config/sway/scratchpads.sh scratch_calc ~/.cargo/bin/complexpr
bindsym $mod+o exec ~/.config/sway/scratchpads.sh scratch_cmus cmus
bindsym $mod+p exec ~/.config/sway/scratchpads.sh scratch_htop htop
# Move focus to the parent container
bindsym $mod+a focus parent
bindsym $mod+s exec prismlauncher
# Start your launcher
bindsym $mod+d exec $menu
bindsym $mod+Shift+d exec dmenu_editconfig
bindsym $mod+f fullscreen
bindsym $mod+g exec vscodium --enable-features=UseOzonePlatform --ozone-platform=wayland
bindsym $mod+h focus left
bindsym $mod+Shift+h move left
bindsym $mod+Ctrl+h resize shrink width 10px
bindsym $mod+j focus down
bindsym $mod+Shift+j move down
bindsym $mod+Ctrl+j resize grow height 10px
bindsym $mod+k focus up
bindsym $mod+Shift+k move up
bindsym $mod+Ctrl+k resize shrink height 10px
bindsym $mod+l focus right
bindsym $mod+Shift+l move right
bindsym $mod+Ctrl+l resize grow width 10px
bindsym $mod+c exec dmenu_kblayout
bindsym $mod+b splith
bindsym $mod+v splitv
bindsym $mod+n exec pkill -USR1 gammastep || gammastep -O 4000
bindsym $mod+Shift+n exec pkill -USR1 gammastep || gammastep -O 2500
bindgesture swipe:right workspace next
bindgesture swipe:left workspace prev
# class border backgr. text indicator child_border
client.focused #4d4754 #14171d #ffffff #ada0a8 #4d4754
client.focused_inactive #14171d #14171d #ffffff #4d4754 #14171d
client.unfocused #14171d #14171d #ffffff #4d4754 #14171d
client.urgent #a63a3a #a63a3a #ffffff #cc5c5c #a63a3a
client.placeholder #14171d #14171d #ffffff #14171d #14171d
client.background #14171d
# Status Bar:
bar {
swaybar_command waybar
}
include /etc/sway/config.d/*

4
.config/sway/scratchpads.sh Executable file
View file

@ -0,0 +1,4 @@
#!/bin/sh
( swaymsg -t get_tree | /bin/grep '"app_id": "'$1'"' ) || ( ( $TERMINAL --class=$1 -e $2 & ) && sleep 0.2 )
swaymsg "[app_id=\"$1\"]" scratchpad show

64
.config/waybar/config Normal file
View file

@ -0,0 +1,64 @@
{
"height": 24,
"spacing": 4,
"modules-left": [
"sway/workspaces",
"sway/window"
],
"modules-center": [],
"modules-right": [
"custom/cmus",
"custom/newsboat",
"cpu",
"memory",
"temperature",
"battery",
"clock",
"tray"
],
"sway/workspaces": {
"disable-scroll": true,
"all-outputs": true,
"format": "{name}"
},
"tray": {
"spacing": 10
},
"clock": {
"format": "{:%Y-%m-%d %a %H:%M}"
},
"cpu": {
"format": " {usage}%",
"tooltip": false
},
"memory": {
"format": " {}%",
"tooltip": false
},
"temperature": {
"thermal-zone": 10,
"critical-threshold": 80,
"format": " {temperatureC}°"
},
"battery": {
"states": {
"warning": 30,
"critical": 15
},
"format": " {capacity}%",
"format-charging": " {capacity}%",
"format-plugged": " {capacity}%",
"format-full": " {capacity}%",
"format-warning": " {capacity}%",
"format-critical": " {capacity}%"
},
"custom/cmus": {
"return-type": "json",
"exec": "$HOME/.config/waybar/custom_cmus.lua 2> /dev/null"
},
"custom/newsboat": {
"format": " {}",
"exec": "$HOME/.config/waybar/custom_newsboat.sh 2> /dev/null",
"on-click": "alacritty -e newsboat -r"
}
}

58
.config/waybar/custom_cmus.lua Executable file
View file

@ -0,0 +1,58 @@
#!/usr/bin/lua
json = require("dkjson")
posix = require("posix")
function htmlescape(s)
s = string.gsub(s, "&", "&amp;")
s = string.gsub(s, "<", "&lt;")
s = string.gsub(s, ">", "&gt;")
return s
end
function timefmt(n)
local s = n % 60
local m = math.floor(n / 60)
return string.format("%d:%02d", m, s)
end
function output(text, tooltip)
text = htmlescape(text)
tooltip = htmlescape(tooltip)
print(json.encode{text=text, tooltip=tooltip, class="custom-cmus"})
end
function getstat(status, name)
for _, line in ipairs(status) do
if string.match(line, "^" .. name) then
return string.sub(line, string.len(name)+2)
end
end
end
while true do
local pipe = io.popen("cmus-remote -Q")
local status = {}
for line in pipe:lines() do
table.insert(status, line)
end
local success = pipe:close()
if not success then
output(" Not running", "Not running")
elseif getstat(status, "status") == "stopped" then
output(" Not running", "Not running")
else
local playing = getstat(status, "status")
local symbol = ({playing="", paused=""})[playing]
local title = getstat(status, "tag title")
local artist = getstat(status, "tag artist")
local duration = getstat(status, "duration")
local position = getstat(status, "position")
local text = string.format("%s %s (%s)", symbol, title, timefmt(position))
local tooltip = string.format("%s - %s (%s / %s)",
artist, title, timefmt(position), timefmt(duration)
)
output(text, tooltip)
end
posix.sleep(1)
end

View file

@ -0,0 +1,12 @@
#!/bin/sh
while :; do
until newsboat -x reload >/dev/null; do
sleep 1;
done
until unread="$(newsboat -x print-unread)"; do
sleep 1;
done
echo "$unread" | awk '{ print $1 }'
sleep 300
done

117
.config/waybar/style.css Normal file
View file

@ -0,0 +1,117 @@
* {
font-family: "Fira Mono", "Font Awesome 6 Pro", monospace;
font-size: 13.5px;
transition: none;
}
#waybar {
background-color: rgba(20, 23, 29, 0.85);
color: #c7c6c3;
}
button {
border: none;
border-radius: 0;
}
#workspaces button {
padding: 0 5px;
color: #c7c6c3;
background-color: rgba(0, 0, 0, 0);
}
#workspaces button:hover {
box-shadow: inherit;
text-shadow: inherit;
}
#workspaces button.focused {
background-color: #789ebf;
color: #14171d;
box-shadow: inherit;
text-shadow: inherit;
}
#workspaces button.urgent {
background-color: #cc5c5c;
box-shadow: inherit;
text-shadow: inherit;
}
#clock,
#battery,
#cpu,
#memory,
#disk,
#temperature,
#backlight,
#network,
#pulseaudio,
#custom-media,
#tray,
#mode,
#idle_inhibitor,
#scratchpad,
#custom-cmus,
#custom-newsboat,
#mpd {
padding: 0 10px;
border-right: 1px solid #4d4754;
color: #c7c6c3;
}
#tray {
border: none;
}
#window {
padding: 0 10px;
border-left: 1px solid #4d4754;
color: #c7c6c3;
}
#window,
#workspaces {
margin: 0 4px;
}
#battery {
color: #97bd5e;
}
#battery.warning:not(.charging) {
color: #f0c767;
}
#battery.critical:not(.charging) {
color: #cc5c5c;
}
#cpu {
color: #789ebf;
}
#memory {
color: #a97fb3;
}
#temperature {
color: #97bd5e;
}
#temperature.critical {
color: #cc5c5c;
}
#custom-newsboat {
color: #de7e54;
}
#tray > .passive {
-gtk-icon-effect: dim;
}
#tray > .needs-attention {
-gtk-icon-effect: highlight;
}