set runtimepath^=/.vim runtimepath+=~/.vim/after let &packpath = &runtimepath "syntax on set modelines=0 set hidden set number set ruler set visualbell set textwidth=120 set cursorline hi CursorLine term=bold cterm=bold ctermbg=darkgrey set tabstop=2 set shiftwidth=2 set matchpairs+=<:> set showmode set showcmd set showmatch set hlsearch set ignorecase set smartcase set incsearch set wrapscan set scrolloff=999 set backspace=indent,eol,start set mouse=nicr set termguicolors call plug#begin(stdpath('data') . '/plugged') Plug 'junegunn/vim-easy-align' Plug 'morhetz/gruvbox' Plug 'junegunn/fzf', {'do': {->fzf#install()}} Plug 'junegunn/fzf.vim' Plug 'gfanto/fzf-lsp.nvim' Plug 'nvim-lua/lsp-status.nvim' Plug 'jiangmiao/auto-pairs' Plug 'machakann/vim-sandwich' Plug 'machakann/vim-highlightedyank' Plug 'bling/vim-airline' Plug 'airblade/vim-gitgutter' Plug 'rhysd/vim-clang-format' Plug 'easymotion/vim-easymotion' Plug 'neovim/nvim-lspconfig' Plug 'kosayoda/nvim-lightbulb' Plug 'hrsh7th/cmp-nvim-lsp' Plug 'hrsh7th/cmp-buffer' Plug 'hrsh7th/cmp-path' Plug 'hrsh7th/cmp-cmdline' Plug 'hrsh7th/nvim-cmp' Plug 'saadparwaiz1/cmp_luasnip' Plug 'L3MON4D3/LuaSnip' Plug 'kyazdani42/nvim-web-devicons' Plug 'kyazdani42/nvim-tree.lua' Plug 'tpope/vim-fugitive' Plug 'mfussenegger/nvim-dap' Plug 'David-Kunz/jester' Plug 'nvim-treesitter/nvim-treesitter', {'do': ':TSUpdate'} Plug 'waycrate/swhkd-vim' Plug 'kmonad/kmonad-vim' call plug#end() autocmd vimenter * colorscheme gruvbox autocmd BufEnter *.60 :setlocal filetype=sixtyfps let g:clang_format#auto_format=0 set completeopt=menuone,noselect "nvim-tree let g:nvim_tree_git_hl = 1 "0 by default, will enable file highlight for git attributes (can be used without the icons). let g:nvim_tree_highlight_opened_files = 1 "0 by default, will enable folder and file icon highlight for opened files/directories. let g:nvim_tree_root_folder_modifier = ':~' "This is the default. See :help filename-modifiers for more options let g:nvim_tree_add_trailing = 1 "0 by default, append a trailing slash to folder names let g:nvim_tree_icon_padding = ' ' "one space by default, used for rendering the space between the icon and the filename. Use with caution, it could break rendering if you set an empty string depending on your font. let g:nvim_tree_symlink_arrow = ' >> ' " defaults to ' ➛ '. used as a separator between symlinks' source and target. let g:nvim_tree_respect_buf_cwd = 1 "0 by default, will change cwd of nvim-tree to that of new buffer's when opening nvim-tree. let g:nvim_tree_special_files = { 'README.md': 1, 'Makefile': 1, 'MAKEFILE': 1 } " List of filenames that gets highlighted with NvimTreeSpecialFile let g:nvim_tree_show_icons = { \ 'git': 1, \ 'folders': 1, \ 'files': 1, \ 'folder_arrows': 0, \ } "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 " default shows no icon by default let g:nvim_tree_icons = { \ 'default': '', \ 'symlink': '', \ 'git': { \ 'unstaged': "✗", \ 'staged': "✓", \ 'unmerged': "", \ 'renamed': "➜", \ 'untracked': "★", \ 'deleted': "", \ 'ignored': "◌" \ }, \ 'folder': { \ 'arrow_open': "", \ 'arrow_closed': "", \ 'default': "", \ 'open': "", \ 'empty': "", \ 'empty_open': "", \ 'symlink': "", \ 'symlink_open': "", \ } \ } " a list of groups can be found at `:help nvim_tree_highlight` highlight NvimTreeFolderIcon guibg=blue lua require('nvimtree') lua require('lsp_config') lua require('treesitter_config') lua require('dap_config') lua require('jester') "Leader nnoremap let mapleader=" " "mappings map h :set cursorline! "map c :!yarn copy-start "map b :!yarn build "map bs :!yarn build-start nnoremap :NvimTreeToggle nnoremap r :NvimTreeRefresh nnoremap n :NvimTreeFindFile " NvimTreeOpen, NvimTreeClose, NvimTreeFocus, NvimTreeFindFileToggle, and NvimTreeResize are also available if you need them xnoremap p "_dP nnoremap :noh map f :FZF map F :Rg nnoremap ca lua vim.lsp.buf.code_action() nnoremap gd lua vim.lsp.buf.definition() nnoremap gD lua vim.lsp.buf.declaration() nnoremap gr lua vim.lsp.buf.references() nnoremap rn lua vim.lsp.buf.rename() nnoremap K lua vim.lsp.buf.hover() nnoremap J lua vim.diagnostic.open_float() nnoremap lua vim.lsp.buf.formatting() inoremap lua vim.lsp.buf.signature_help() nnoremap lua require'dap'.toggle_breakpoint() nnoremap lua require'dap'.continue() nnoremap lua require'dap'.step_over() nnoremap lua require'dap'.step_into() autocmd BufWritePre *.ts lua vim.lsp.buf.formatting_sync(nil, 1000) command JestRun :lua require'jester'.run({cmd = "yarn run test -t '$result' -- $file"}) command JestRunFile :lua require'jester'.run_file({cmd = "yarn run test -t '$result' -- $file"}) command JestRunLast :lua require'jester'.run_last({cmd = "yarn run test -t '$result' -- $file"}) command JestDebug :lua require'jester'.debug({cmd = "yarn run test -t '$result' -- $file"}) command JestDebugFile :lua require'jester'.debug_file({cmd = "yarn run test -t '$result' -- $file"}) command JestDebugLast :lua require'jester'.debug_last({cmd = "yarn run test -t '$result' -- $file"})