Skip to content

Commit

Permalink
update coc.nvim and add modern cpp syntax highlighting
Browse files Browse the repository at this point in the history
  • Loading branch information
DanielSchuette committed Jun 27, 2021
1 parent 91169bc commit 1e82ea0
Show file tree
Hide file tree
Showing 17,807 changed files with 5,333 additions and 2,855,155 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
28 changes: 14 additions & 14 deletions .bashrc
Original file line number Diff line number Diff line change
Expand Up @@ -50,15 +50,15 @@ export PATH
PATH="$HOME/.cabal/bin:$PATH"
export PATH

# set environment variables for go
GOBIN="$HOME/code/go_src/bin"
export GOBIN
GOPATH="$HOME/code/go_src"
export GOPATH
GOROOT="/usr/local/go" # needs to be set if go is in custom location
export GOROOT
PATH="$GOROOT/bin:$PATH"
export PATH
# set environment variables for go (is this even necessary with modern Go?)
#GOBIN="$HOME/code/go_src/bin"
#export GOBIN
#GOPATH="$HOME/code/go_src"
#export GOPATH
#GOROOT="/usr/local/go" # needs to be set if go is in custom location
#export GOROOT
#PATH="$GOROOT/bin:$PATH"
#export PATH

# prevent ranger from loading rc.conf from
# /usr/share/doc/config/ and ~/.config/ranger
Expand All @@ -84,10 +84,10 @@ alias src="source ~/.bashrc && echo 'sourced .bashrc'"
alias xup="xrdb ~/dotfiles/.Xresources"

# always use vim-x11 for system clipboard access
alias nv="nvim -p"
alias v="nvim -p"
alias vi="nvim -p"
alias vim="nvim -p"
alias nv="nvim"
alias v="nvim"
alias vi="nvim"
alias vim="nvim"

# create for file browsing and viewing
alias c="clear"
Expand Down Expand Up @@ -123,7 +123,7 @@ alias py="ipython"
alias xclip="xclip -selection clipboard"

# access music player more easily
alias n="sudo ncmpcpp --screen=media_library --bindings=\$HOME/.ncmpcpp/bindings --config=\$HOME/.ncmpcpp/config"
alias n="ncmpcpp --screen=media_library --bindings=\$HOME/.config/ncmpcpp/bindings --config=\$HOME/.config/ncmpcpp/config"

# open ipython in vim mode automatically
alias ipython="ipython --TerminalInteractiveShell.editing_mode=vi"
Expand Down
22 changes: 18 additions & 4 deletions vim-config/configs.vim
Original file line number Diff line number Diff line change
Expand Up @@ -304,6 +304,10 @@ highlight CocWarningSign ctermfg=Yellow ctermbg=Blue
" enable autocompletion on tab
set completeopt=longest,menuone

" disable completion for TypeScript
autocmd BufNew,BufEnter *.ts execute "silent! CocDisable"
autocmd BufLeave *.ts execute "silent! CocEnable"

" Use tab for trigger completion with characters ahead and navigate.
" NOTE: Use command ':verbose imap <tab>' to make sure tab is not mapped by
" other plugin before putting this into your config.
Expand Down Expand Up @@ -425,6 +429,10 @@ set updatetime=300
" automatically highlight matching identifiers
let g:go_auto_sameids = 1

" Vim-Modern-Cpp Configs
" ----------------------
let g:cpp_no_function_highlight = 1

" Ale Configs
" -----------
" enable highlighting of linter findings
Expand Down Expand Up @@ -457,9 +465,8 @@ let g:completor_python_binary = '/usr/bin/python3'
" Usually, tools only need to be installed to work without
" additional settings in this file. Some language configs are set
" manually, anyways.
" NOTE: tslint is sometimes slow, the same is true for clangtidy
let g:ale_linters = {
\ 'typescript': ['tslint'],
\ 'typescript': ['eslint', 'tsserver'],
\ 'javascript': ['prettier', 'eslint', 'jshint'],
\ 'python': ['flake8', 'mypy'],
\ 'go': ['go', 'golint', 'errcheck'],
Expand All @@ -472,8 +479,8 @@ let g:ale_linters = {
let g:ale_cpp_clang_options = '-Wall -Wextra -std=c++20 -x c++'
let g:ale_cpp_clangtidy_options = '-Wall -Wextra -std=c++20 -x c++'
let g:ale_cpp_clangcheck_options = '-- -Wall -Wextra -std=c++20 -x c++'
let g:ale_c_clangtidy_options = '-Wall -Wextra -std=c99 -x c'
let g:ale_c_clangcheck_options = '-- -Wall -Wextra -std=c99 -x c'
let g:ale_c_clangtidy_options = '-Wall -Wextra -std=c11 -x c'
let g:ale_c_clangcheck_options = '-- -Wall -Wextra -std=c11 -x c'

let g:ale_elm_ls_use_global = 1
let g:ale_elm_ls_executable = '/usr/local/bin/elm-language-server'
Expand Down Expand Up @@ -660,6 +667,13 @@ highlight clear Todo
"**********************"
"** Helper Functions **"
"**********************"
" Displays the highlight group of the word under the cursor.
" Very useful for color scheme design.
function! SynGroup()
let l:s = synID(line('.'), col('.'), 1)
echo synIDattr(l:s, 'name') . ' -> ' . synIDattr(synIDtrans(l:s), 'name')
endfun

" Returns true if paste mode is enabled
function! HasPaste()
if &paste
Expand Down
14 changes: 7 additions & 7 deletions vim-config/plugins/ale/.netrwhist
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
let g:netrw_dirhistmax =10
let g:netrw_dirhistcnt =1
let g:netrw_dirhistcnt =7
let g:netrw_dirhist_7='/home/daniel/code/cc_src/opengl/tut4/src'
let g:netrw_dirhist_6='/home/daniel/code/cc_src/opengl/tut4/src/json'
let g:netrw_dirhist_5='/home/daniel/code/cc_src/sjp/.git'
let g:netrw_dirhist_4='/home/daniel/code/cc_src/sjp/.git/hooks'
let g:netrw_dirhist_3='/home/daniel/code/cc_src/sjp/.git'
let g:netrw_dirhist_2='/home/daniel/code/js_src/webgl2/webgl_ts/dist'
let g:netrw_dirhist_1='/home/daniel/dotfiles/vim-config/plugins/gruvbox/colors'
let g:netrw_dirhist_0='/home/daniel/code/cc_src/opengl/tut4/assets'
let g:netrw_dirhist_9='/home/daniel/code/cc_src/opengl/tut3'
let g:netrw_dirhist_8='/home/daniel/code/cc_src/opengl/tut4/src'
let g:netrw_dirhist_7='/home/daniel/edit/src'
let g:netrw_dirhist_6='/home/daniel/edit'
let g:netrw_dirhist_5='/home/daniel/tmp/src'
let g:netrw_dirhist_4='/home/daniel/code/cc_src/mario'
let g:netrw_dirhist_3='/home/daniel/code/rand/graphviz/dot.demo'
let g:netrw_dirhist_2='/home/daniel/code/cc_src/comp/utils'
4 changes: 0 additions & 4 deletions vim-config/plugins/coc.nvim/.eslintignore

This file was deleted.

Loading

0 comments on commit 1e82ea0

Please sign in to comment.