From 461f3d24698dfc648d18ebece8f2a517ee976011 Mon Sep 17 00:00:00 2001 From: kageru Date: Sun, 28 Jan 2024 11:33:08 +0100 Subject: [PATCH] update configs --- .config/alacritty/alacritty.toml | 138 ++++++++++++++ .config/alacritty/alacritty.yml | 252 -------------------------- .config/htop/htoprc | 35 +++- .config/i3/config | 2 +- .config/polybar/config | 4 +- .config/sway/config | 22 ++- .config/zathura/zathurarc | 4 +- .vimrc | 300 ------------------------------- bin/autostart | 2 +- bin/autostart_sway | 10 +- 10 files changed, 188 insertions(+), 581 deletions(-) create mode 100644 .config/alacritty/alacritty.toml delete mode 100644 .config/alacritty/alacritty.yml delete mode 100644 .vimrc diff --git a/.config/alacritty/alacritty.toml b/.config/alacritty/alacritty.toml new file mode 100644 index 0000000..d0f2c88 --- /dev/null +++ b/.config/alacritty/alacritty.toml @@ -0,0 +1,138 @@ +live_config_reload = true + +[bell] +animation = "EaseOutExpo" +duration = 0 + +[colors] +draw_bold_text_with_bright_colors = true + +[colors.bright] +black = "0x727072" +blue = "0xfc9867" +cyan = "0x78dce8" +green = "0xa9dc76" +magenta = "0xab9df2" +red = "0xff6188" +white = "0xfcfcfa" +yellow = "0xffd866" + +[colors.dim] +black = "0x333333" +blue = "0x6699cc" +cyan = "0x66cccc" +green = "0x99cc99" +magenta = "0xcc99cc" +red = "0xf2777a" +white = "0xdddddd" +yellow = "0xffcc66" + +[colors.normal] +black = "0x403e41" +blue = "0xfc9867" +cyan = "0x78dce8" +green = "0xa9dc76" +magenta = "0xab9df2" +red = "0xff6188" +white = "0xfcfcfa" +yellow = "0xffd866" + +[colors.primary] +background = "0x303031" +foreground = "0xfcfcfa" + +[cursor] +style = "Beam" + +[env] +TERM = "xterm-256color" + +[font] +size = 13.0 + +[font.bold] +family = "Hack Nerd Font Mono" +style = "Bold" + +[font.glyph_offset] +x = 0 +y = 0 + +[font.italic] +family = "Hack Nerd Font Mono" +style = "Italic" + +[font.normal] +family = "Hack Nerd Font Mono" +style = "Regular" + +[font.offset] +x = 0 +y = 1 + +[[keyboard.bindings]] +action = "Paste" +key = "V" +mods = "Control|Shift" + +[[keyboard.bindings]] +action = "Paste" +key = "V" +mods = "Alt" + +[[keyboard.bindings]] +action = "Copy" +key = "C" +mods = "Control|Shift" + +[[keyboard.bindings]] +action = "Copy" +key = "C" +mods = "Alt" + +[[keyboard.bindings]] +action = "PasteSelection" +key = "Insert" +mods = "Shift" + +[[keyboard.bindings]] +action = "ResetFontSize" +key = "Key0" +mods = "Control" + +[[keyboard.bindings]] +action = "IncreaseFontSize" +key = "K" +mods = "Alt|Shift" + +[[keyboard.bindings]] +action = "DecreaseFontSize" +key = "J" +mods = "Alt|Shift" + +[[keyboard.bindings]] +action = "ScrollLineDown" +key = "J" +mods = "Alt" + +[[keyboard.bindings]] +action = "ScrollLineUp" +key = "K" +mods = "Alt" + +[[keyboard.bindings]] +action = "ScrollPageDown" +key = "D" +mods = "Alt" + +[[keyboard.bindings]] +action = "ScrollPageUp" +key = "U" +mods = "Alt" + +[[mouse.bindings]] +action = "PasteSelection" +mouse = "Middle" + +[selection] +semantic_escape_chars = ",│`|:\"' ()[]{}<>" diff --git a/.config/alacritty/alacritty.yml b/.config/alacritty/alacritty.yml deleted file mode 100644 index 6108654..0000000 --- a/.config/alacritty/alacritty.yml +++ /dev/null @@ -1,252 +0,0 @@ -# Configuration for Alacritty, the GPU enhanced terminal emulator - - -# Any items in the `env` entry below will be added as -# environment variables. Some entries may override variables -# set by alacritty it self. -env: - # TERM env customization. - # - # If this property is not set, alacritty will set it to xterm-256color. - # - # Note that some xterm terminfo databases don't declare support for italics. - # You can verify this by checking for the presence of `smso` and `sitm` in - # `infocmp xterm-256color`. - TERM: xterm-256color - # xterm-256color - -# Window dimensions in character columns and lines -# Falls back to size specified by window manager if set to 0x0. -# (changes require restart) -window.dimensions: - columns: 80 - lines: 24 - -window.opacity: 1.0 - -# Adds this many blank pixels of padding around the window -# Units are physical pixels; this is not DPI aware. -# (change requires restart) -window.padding: - x: 2 - y: 2 - -# When true, bold text is drawn using the bright variant of colors. -draw_bold_text_with_bright_colors: true - -# Font configuration (changes require restart) -# -# Important font attributes like antialiasing, subpixel aa, and hinting can be -# controlled through fontconfig. Specifically, the following attributes should -# have an effect: -# -# * hintstyle -# * antialias -# * lcdfilter -# * rgba -# -# For instance, if you wish to disable subpixel antialiasing, you might set the -# rgba property to "none". If you wish to completely disable antialiasing, you -# can set antialias to false. -# -# Please see these resources for more information on how to use fontconfig -# -# * https://wiki.archlinux.org/index.php/font_configuration#Fontconfig_configuration -# * file:///usr/share/doc/fontconfig/fontconfig-user.html -font: - # The normal (roman) font face to use. - normal: - family: Hack Nerd Font Mono # should be "Menlo" or something on macOS. - # Style can be specified to pick a specific face. - style: Regular - - # The bold font face - bold: - family: Hack Nerd Font Mono # should be "Menlo" or something on macOS. - # Style can be specified to pick a specific face. - style: Bold - - # The italic font face - italic: - family: Hack Nerd Font Mono # should be "Menlo" or something on macOS. - # Style can be specified to pick a specific face. - style: Italic - - # Point size of the font - size: 13.0 - - # Offset is the extra space around each character. offset.y can be thought of - # as modifying the linespacing, and offset.x as modifying the letter spacing. - offset: - x: 0 - y: 1 - - # Glyph offset determines the locations of the glyphs within their cells with - # the default being at the bottom. Increase the x offset to move the glyph to - # the right, increase the y offset to move the glyph upward. - glyph_offset: - x: 0 - y: 0 - -cursor: - style: Beam - -colors: - # Default colors - primary: - #background: '0x403e41' - background: '0x303031' - foreground: '0xfcfcfa' - - # Colors the cursor will use if `custom_cursor_colors` is true - #cursor: - # text: '0x000000' - # cursor: '0x20b57c' - - normal: - black: '0x403e41' - red: '0xff6188' - green: '0xa9dc76' - yellow: '0xffd866' - blue: '0xfc9867' - magenta: '0xab9df2' - cyan: '0x78dce8' - white: '0xfcfcfa' - - # Bright colors - bright: - black: '0x727072' - red: '0xff6188' - green: '0xa9dc76' - yellow: '0xffd866' - blue: '0xfc9867' - magenta: '0xab9df2' - cyan: '0x78dce8' - white: '0xfcfcfa' - - # Dim colors (Optional) - dim: - black: '0x333333' - red: '0xf2777a' - green: '0x99cc99' - yellow: '0xffcc66' - blue: '0x6699cc' - magenta: '0xcc99cc' - cyan: '0x66cccc' - white: '0xdddddd' - -# Visual Bell -# -# Any time the BEL code is received, Alacritty "rings" the visual bell. Once -# rung, the terminal background will be set to white and transition back to the -# default background color. You can control the rate of this transition by -# setting the `duration` property (represented in milliseconds). You can also -# configure the transition function by setting the `animation` property. -# -# Possible values for `animation` -# `Ease` -# `EaseOut` -# `EaseOutSine` -# `EaseOutQuad` -# `EaseOutCubic` -# `EaseOutQuart` -# `EaseOutQuint` -# `EaseOutExpo` -# `EaseOutCirc` -# `Linear` -# -# To completely disable the visual bell, set its duration to 0. -# -bell: - animation: EaseOutExpo - duration: 0 - -# Mouse bindings -# -# Currently doesn't support modifiers. Both the `mouse` and `action` fields must -# be specified. -# -# Values for `mouse`: -# - Middle -# - Left -# - Right -# - Numeric identifier such as `5` -# -# Values for `action`: -# - Paste -# - PasteSelection -# - Copy (TODO) -mouse_bindings: - - { mouse: Middle, action: PasteSelection } - -mouse: - double_click: { threshold: 300 } - triple_click: { threshold: 300 } - -selection: - semantic_escape_chars: ",│`|:\"' ()[]{}<>" - -mouse.hide_when_typing: false - -# Live config reload (changes require restart) -live_config_reload: true - -# Shell -# -# You can set shell.program to the path of your favorite shell, e.g. /bin/fish. -# Entries in shell.args are passed unmodified as arguments to the shell. -# shell: -# program: /bin/bash -# args: -# - --login - - -# Key bindings -# -# Each binding is defined as an object with some properties. Most of the -# properties are optional. All of the alphabetical keys should have a letter for -# the `key` value such as `V`. Function keys are probably what you would expect -# as well (F1, F2, ..). The number keys above the main keyboard are encoded as -# `Key1`, `Key2`, etc. Keys on the number pad are encoded `Number1`, `Number2`, -# etc. These all match the glutin::VirtualKeyCode variants. -# -# Possible values for `mods` -# `Command`, `Super` refer to the super/command/windows key -# `Control` for the control key -# `Shift` for the Shift key -# `Alt` and `Option` refer to alt/option -# -# mods may be combined with a `|`. For example, requiring control and shift -# looks like: -# -# mods: Control|Shift -# -# The parser is currently quite sensitive to whitespace and capitalization - -# capitalization must match exactly, and piped items must not have whitespace -# around them. -# -# Either an `action`, `chars`, or `command` field must be present. -# `action` must be one of `Paste`, `PasteSelection`, `Copy`, or `Quit`. -# `chars` writes the specified string every time that binding is activated. -# These should generally be escape sequences, but they can be configured to -# send arbitrary strings of bytes. -# `command` must be a map containing a `program` string, and `args` array of -# strings. For example: -# - { ... , command: { program: "alacritty", args: ["-e", "vttest"] } } -# -# Want to add a binding (e.g. "PageUp") but are unsure what the X sequence -# (e.g. "\x1b[5~") is? Open another terminal (like xterm) without tmux, -# then run `showkey -a` to get the sequence associated to a key combination. -key_bindings: - - { key: V, mods: Control|Shift, action: Paste } - - { key: V, mods: Alt, action: Paste } - - { key: C, mods: Control|Shift, action: Copy } - - { key: C, mods: Alt, action: Copy } - - { key: Insert, mods: Shift, action: PasteSelection } - - { key: Key0, mods: Control, action: ResetFontSize } - - { key: K, mods: Alt|Shift, action: IncreaseFontSize } - - { key: J, mods: Alt|Shift, action: DecreaseFontSize } - - { key: J, mods: Alt, action: ScrollLineDown } - - { key: K, mods: Alt, action: ScrollLineUp } - - { key: D, mods: Alt, action: ScrollPageDown } - - { key: U, mods: Alt, action: ScrollPageUp } diff --git a/.config/htop/htoprc b/.config/htop/htoprc index dddd219..7282ac1 100644 --- a/.config/htop/htoprc +++ b/.config/htop/htoprc @@ -1,12 +1,8 @@ # Beware! This file is rewritten by htop when settings are changed in the interface. # The parser is also very primitive, and not human-friendly. -htop_version=3.1.1 -config_reader_min_version=2 +htop_version=3.2.1 +config_reader_min_version=3 fields=48 38 39 46 47 111 1 -sort_key=47 -sort_direction=-1 -tree_sort_key=47 -tree_sort_direction=1 hide_kernel_threads=1 hide_userland_threads=0 shadow_other_users=0 @@ -21,10 +17,8 @@ highlight_changes_delay_secs=5 find_comm_in_cmdline=1 strip_exe_from_cmdline=1 show_merged_command=0 -tree_view=0 -tree_view_always_by_pid=0 -all_branches_collapsed=0 header_margin=1 +screen_tabs=0 detailed_cpu_time=0 cpu_count_from_one=0 show_cpu_usage=1 @@ -42,3 +36,26 @@ column_meters_0=AllCPUs2 Memory CPU Tasks column_meter_modes_0=1 1 2 2 column_meters_1=CPU Memory Blank LoadAverage Uptime column_meter_modes_1=3 3 2 2 2 +tree_view=0 +sort_key=46 +tree_sort_key=46 +sort_direction=-1 +tree_sort_direction=-1 +tree_view_always_by_pid=0 +all_branches_collapsed=0 +screen:Main=USER M_VIRT M_RESIDENT PERCENT_CPU PERCENT_MEM IO_RATE Command +.sort_key=PERCENT_CPU +.tree_sort_key=PERCENT_CPU +.tree_view=0 +.tree_view_always_by_pid=0 +.sort_direction=-1 +.tree_sort_direction=-1 +.all_branches_collapsed=0 +screen:I/O=PID USER IO_PRIORITY IO_RATE IO_READ_RATE IO_WRITE_RATE PERCENT_SWAP_DELAY PERCENT_IO_DELAY Command +.sort_key=IO_RATE +.tree_sort_key=PID +.tree_view=0 +.tree_view_always_by_pid=0 +.sort_direction=-1 +.tree_sort_direction=1 +.all_branches_collapsed=0 diff --git a/.config/i3/config b/.config/i3/config index 8a84528..46e5fb1 100644 --- a/.config/i3/config +++ b/.config/i3/config @@ -276,7 +276,7 @@ for_window [class="mpv"] floating enable for_window [class="tModLoader.bin.x86_64"] floating enable for_window [class="mono-sgen"] floating enable for_window [class="feh"] floating enable -for_window [workspace=$ws12] floating enable +for_window [workspace=$ws8] floating enable for_window [urgent=latest] none diff --git a/.config/polybar/config b/.config/polybar/config index dcc170f..09d253c 100644 --- a/.config/polybar/config +++ b/.config/polybar/config @@ -73,7 +73,7 @@ width = 100% height = 28 radius = 0.0 fixed-center = true -bottom = false +bottom = true background = ${colors.background} foreground = ${colors.foreground} @@ -116,7 +116,7 @@ offset-x = 0% offset-y = 0% radius = 0.0 fixed-center = true -bottom = false +bottom = true background = ${colors.background} foreground = ${colors.foreground} diff --git a/.config/sway/config b/.config/sway/config index a198024..ac59d4c 100644 --- a/.config/sway/config +++ b/.config/sway/config @@ -5,6 +5,7 @@ # Read `man 5 sway` for a complete reference. gaps inner 10 +gaps outer -10 ### Variables # # Logo key. Use Mod1 for Alt. @@ -22,6 +23,8 @@ set $term alacritty #set $menu dmenu_path | wofi --dmenu | xargs swaymsg exec -- set $menu wofi --show run +smart_borders on + bindsym XF86AudioPlay exec mpc toggle bindsym XF86AudioNext exec mpc next bindsym $mod+F7 exec mpc next @@ -29,7 +32,7 @@ bindsym $mod+F7 exec mpc next ### Output configuration # # Default wallpaper (more resolutions are available in /usr/share/backgrounds/sway/) -output * bg /home/kageru/Pictures/bg.png fill +output * bg /home/kageru/Pictures/bg_train.jpg fill # # Example configuration: # @@ -38,9 +41,9 @@ output * bg /home/kageru/Pictures/bg.png fill # You can get the names of your outputs by running: swaymsg -t get_outputs output HDMI-A-1 mode 2560x1440@144Hz -output HDMI-A-1 position 0 0 +output HDMI-A-1 position 2560 0 output DP-1 mode 2560x1440@240Hz -output DP-1 position 2560 0 +output DP-1 position 0 0 default_border pixel 2 default_floating_border pixel 3 @@ -51,11 +54,11 @@ bindsym $mod+y border pixel 3 # # Example configuration: # -# exec swayidle -w \ +# exec swayidle # timeout 300 'swaylock -f -c 000000' \ # timeout 600 'swaymsg "output * dpms off"' resume 'swaymsg "output * dpms on"' \ exec swayidle -w timeout 600 'swaymsg "output * dpms off"' resume 'swaymsg "output * dpms on"' \ - before-sleep 'swaylock -f -c 000000' \ + before-sleep 'swaylock -e -f -c 000000' \ after-resume /home/kageru/bin/tunnel # # This will lock your screen after 300 seconds of inactivity, then turn off @@ -89,13 +92,20 @@ input "type:mouse" { pointer_accel 0 accel_profile flat } + +input 1386:221:Wacom_Bamboo_Connect_Pen { + map_from_region 0.0x0.0 0.7x0.7 + map_to_output DP-1 +} # You can get the names of your inputs by running: swaymsg -t get_inputs # Read `man 5 sway-input` for more information about this section. for_window [app_id="mpv"] floating enable for_window [class="feh"] floating enable +for_window [app_id="org.qutebrowser.qutebrowser"] border none for_window [class="sxiv"] floating enable -for_window [app_id="Alacritty"] opacity 0.9 +for_window [title="YGO Omega"] floating enable +for_window [app_id="Alacritty"] opacity 0.95 no_focus [class="jetbrains-.*"] no_focus [class=".*discord.*"] for_window [urgent=latest] none diff --git a/.config/zathura/zathurarc b/.config/zathura/zathurarc index 2eca8ea..61ce781 100644 --- a/.config/zathura/zathurarc +++ b/.config/zathura/zathurarc @@ -31,6 +31,6 @@ set completion-highlight-bg "#EBCB8B" set recolor-lightcolor "#313132" set recolor-darkcolor "#c5c8c6" -set recolor "false" -set recolor-keephue "false" +# set recolor "true" +set recolor-keephue "true" diff --git a/.vimrc b/.vimrc deleted file mode 100644 index 804ba7e..0000000 --- a/.vimrc +++ /dev/null @@ -1,300 +0,0 @@ -set nocompatible " be iMproved, required -filetype on " required - -call plug#begin('~/.vim/plugged') - -Plug 'scrooloose/syntastic' -Plug 'rust-lang/rust.vim' -Plug 'fatih/vim-go' -Plug 'kageru/kotlin-vim' -Plug 'phanviet/vim-monokai-pro' -Plug 'cespare/vim-toml' -Plug 'sirver/UltiSnips' -Plug 'honza/vim-snippets' -Plug 'lotabout/skim', { 'dir': '~/.skim', 'do': './install' } -Plug 'lotabout/skim.vim' -" Plug 'powerline/powerline' -Plug 'vim-airline/vim-airline' -Plug 'elmcast/elm-vim' -Plug 'tpope/vim-fugitive' -Plug 'mileszs/ack.vim' - -Plug 'neoclide/coc.nvim', {'branch': 'release'} -"Plug 'zxqfl/tabnine-vim' - -call plug#end() -"set rtp+=~/code/tabnine-vim -filetype plugin on -autocmd BufNewFile,BufRead *.vpy setfiletype python -autocmd BufNewFile,BufRead *.kt setfiletype kotlin - -" for ncm2 completion -"autocmd BufEnter * call ncm2#enable_for_buffer() -"set completeopt=noinsert,menuone,noselect -" When the key is pressed while the popup menu is visible, it only -" hides the menu. Use this mapping to close the menu and also start a new line. -"inoremap (pumvisible() ? "\\" : "\") -" Use to select the popup menu: -"imap -"inoremap pumvisible() ? "\" : "\" -"inoremap pumvisible() ? "\" : "\" - -" Required for operations modifying multiple buffers like rename. -set hidden - - "\ 'rust': ['rustup', 'run', 'stable', 'rls'], - "\ 'rust': ['rustup', 'run', 'nightly', 'rls'], - "\ 'c': ['/usr/bin/ccls'], -let g:LanguageClient_serverCommands = { - \ 'rust': ['rust-analyzer'], - \ 'haskell': ['hie-wrapper'], - \ 'python': ['/usr/bin/pyls'], - \ 'kotlin': ['/usr/bin/kotlin-language-server'], - \ } - -nnoremap :call LanguageClient_contextMenu() -" Or map each action separately -nnoremap K :call LanguageClient#textDocument_hover() -"nnoremap gd :call LanguageClient#textDocument_definition() -nnoremap :call LanguageClient#textDocument_rename() -" rename without language server -nnoremap gr gd[{V%::s////gc - -set number -set showmatch - -set hlsearch -set ignorecase -set smartcase -set incsearch - -set autoindent -set cindent -set expandtab -set shiftwidth=2 -set smartindent -set smarttab -set softtabstop=2 -set relativenumber - -" set beam cursor in insert mode -let &t_SI = "\[5 q" -let &t_SR = "\[5 q" -let &t_EI = "\[2 q" - -set undolevels=1000 -set backspace=indent,eol,start - -set background=dark -let &t_8f = "\[38;2;%lu;%lu;%lum" -let &t_8b = "\[48;2;%lu;%lu;%lum" -let g:autofmt_autosave = 1 -set termguicolors -colorscheme monokai_pro -syntax on - -let g:netrw_liststyle = 3 -let g:netrw_banner = 0 -let g:netrw_browse_split = 4 -let g:netrw_winsize = 15 -nmap :Vexplore -autocmd BufNewFile,BufRead *.rs nmap :RustFmt -autocmd BufNewFile,BufRead *.elm nmap :ElmFormat - - -set statusline+=%#warningmsg# -set statusline+=%{SyntasticStatuslineFlag()} -set statusline+=%* - -let g:syntastic_always_populate_loc_list = 1 -let g:syntastic_auto_loc_list = 1 -let g:syntastic_check_on_open = 0 -let g:syntastic_check_on_wq = 0 -let g:syntastic_check_on_write = 0 -let g:syntastic_mode_map = { 'mode': 'passive' } -nmap :SyntasticCheck - -let g:elm_syntastic_show_warnings = 1 -let g:ycm_semantic_triggers = { - \ 'elm' : ['.'], - \} - -let g:LanguageClient_rootMarkers = { - \ 'elm': ['elm.json'], - \ } - - -nnoremap j -nnoremap k -"nnoremap l -nnoremap h -set splitbelow -set splitright - -nmap :Snippets -nmap :Files -imap :Files -nmap :BLines -nmap :Lines -nmap :Buffers -imap :Buffers - -" let g:powerline_pycmd="py3" - -let g:ackprg = 'rg --vimgrep --smart-case' -let g:ack_autoclose = 1 -let g:ack_use_cword_for_empty_search = 1 -nnoremap / :Ack! - -" COC stuff from here - - -" Some servers have issues with backup files, see #649. -set nobackup -set nowritebackup - -" Give more space for displaying messages. -"set cmdheight=2 - -" Having longer updatetime (default is 4000 ms = 4 s) leads to noticeable -" delays and poor user experience. -set updatetime=300 - -" Don't pass messages to |ins-completion-menu|. -set shortmess+=c - -if has("patch-8.1.1564") - " Recently vim can merge signcolumn and number column into one - set signcolumn=number -else - set signcolumn=yes -endif - -" Use tab for trigger completion with characters ahead and navigate. -" NOTE: Use command ':verbose imap ' to make sure tab is not mapped by -" other plugin before putting this into your config. -inoremap - \ pumvisible() ? "\" : - \ check_back_space() ? "\" : - \ coc#refresh() -inoremap pumvisible() ? "\" : "\" - -function! s:check_back_space() abort - let col = col('.') - 1 - return !col || getline('.')[col - 1] =~# '\s' -endfunction - -" Use to trigger completion. -if has('nvim') - inoremap coc#refresh() -else - inoremap coc#refresh() -endif - -" Use to confirm completion, `u` means break undo chain at current -" position. Coc only does snippet and additional edit on confirm. -" could be remapped by other vim plugin, try `:verbose imap `. -if exists('*complete_info') - inoremap complete_info()["selected"] != "-1" ? "\" : "\u\" -else - inoremap pumvisible() ? "\" : "\u\" -endif - -" Use `[g` and `]g` to navigate diagnostics -" Use `:CocDiagnostics` to get all diagnostics of current buffer in location list. -nmap [g (coc-diagnostic-prev) -nmap ]g (coc-diagnostic-next) - -" GoTo code navigation. -nmap gd (coc-definition) -nmap gy (coc-type-definition) -nmap gi (coc-implementation) -nmap gr (coc-references) - -" Use K to show documentation in preview window. -nnoremap K :call show_documentation() - -function! s:show_documentation() - if (index(['vim','help'], &filetype) >= 0) - execute 'h '.expand('') - else - call CocAction('doHover') - endif -endfunction - -" Highlight the symbol and its references when holding the cursor. -autocmd CursorHold * silent call CocActionAsync('highlight') - -" Symbol renaming. -nmap rn (coc-rename) -nmap F6 (coc-rename) - -" Formatting selected code. -xmap f (coc-format-selected) -nmap f (coc-format-selected) - -augroup mygroup - autocmd! - " Setup formatexpr specified filetype(s). - autocmd FileType typescript,json setl formatexpr=CocAction('formatSelected') - " Update signature help on jump placeholder. - autocmd User CocJumpPlaceholder call CocActionAsync('showSignatureHelp') -augroup end - -" Applying codeAction to the selected region. -" Example: `aap` for current paragraph -xmap a (coc-codeaction-selected) -nmap a (coc-codeaction-selected) - -" Remap keys for applying codeAction to the current buffer. -nmap ac (coc-codeaction) -" Apply AutoFix to problem on the current line. -nmap qf (coc-fix-current) - -" Map function and class text objects -" NOTE: Requires 'textDocument.documentSymbol' support from the language server. -xmap if (coc-funcobj-i) -omap if (coc-funcobj-i) -xmap af (coc-funcobj-a) -omap af (coc-funcobj-a) -xmap ic (coc-classobj-i) -omap ic (coc-classobj-i) -xmap ac (coc-classobj-a) -omap ac (coc-classobj-a) - -" Use CTRL-S for selections ranges. -" Requires 'textDocument/selectionRange' support of language server. -nmap (coc-range-select) -xmap (coc-range-select) - -" Add `:Format` command to format current buffer. -command! -nargs=0 Format :call CocAction('format') - -" Add `:Fold` command to fold current buffer. -command! -nargs=? Fold :call CocAction('fold', ) - -" Add `:OR` command for organize imports of the current buffer. -command! -nargs=0 OR :call CocAction('runCommand', 'editor.action.organizeImport') - -" Add (Neo)Vim's native statusline support. -" NOTE: Please see `:h coc-status` for integrations with external plugins that -" provide custom statusline: lightline.vim, vim-airline. -set statusline^=%{coc#status()}%{get(b:,'coc_current_function','')} - -" Mappings for CoCList -" Show all diagnostics. -nnoremap a :CocList diagnostics -" Manage extensions. -nnoremap e :CocList extensions -" Show commands. -nnoremap c :CocList commands -" Find symbol of current document. -nnoremap o :CocList outline -" Search workspace symbols. -nnoremap s :CocList -I symbols -" Do default action for next item. -nnoremap j :CocNext -" Do default action for previous item. -nnoremap k :CocPrev -" Resume latest coc list. -nnoremap p :CocListResume diff --git a/bin/autostart b/bin/autostart index d1bdc1a..99aa474 100755 --- a/bin/autostart +++ b/bin/autostart @@ -8,7 +8,7 @@ xrandr --fb 5120x1440 --dpi 96 \ rm -rf /home/kageru/temp/* cp ~/webpw.kdbx /mnt/calliope/ cp ~/webpw.kdbx ~/Sync/webpw.kdbx -fcitx +# fcitx sshfs -i ~/.ssh/lain lain:/home/kgt/download /mnt/lain -C & #syncthing & xrdb ~/.Xresources diff --git a/bin/autostart_sway b/bin/autostart_sway index 9d62424..e002eb5 100755 --- a/bin/autostart_sway +++ b/bin/autostart_sway @@ -3,14 +3,8 @@ rm -rf /home/kageru/temp/* cp ~/webpw.kdbx /mnt/calliope/ cp ~/webpw.kdbx ~/Sync/webpw.kdbx -fcitx +# fcitx sshfs -i ~/.ssh/lain lain:/home/kgt/download /mnt/lain -C & -#syncthing & -#xrandr --fb 5120x1440 --dpi 96 \ - #--output HDMI-A-0 --mode 2560x1440 -r 120 --pos 0x0 \ - #--output DisplayPort-0 --right-of HDMI-A-0 -r 240 --mode 2560x1440 -#~/bin/fixkeyboard -#xrdb ~/.Xresources gammastep -t 6500:3200 -l 54:10 & -waybar& +waybar & mako &