First Commit
This is a first dotfiles config. I think I have a lot more to add tho...
This commit is contained in:
		
							
								
								
									
										4
									
								
								vim/.vim/UltiSnips/c.snippets
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										4
									
								
								vim/.vim/UltiSnips/c.snippets
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,4 @@
 | 
			
		||||
snippet pline "print a line" i
 | 
			
		||||
printf("----------------------------------------\n");
 | 
			
		||||
endsnippet
 | 
			
		||||
	
 | 
			
		||||
							
								
								
									
										2
									
								
								vim/.vim/UltiSnips/htmljinja.snippets
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										2
									
								
								vim/.vim/UltiSnips/htmljinja.snippets
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,2 @@
 | 
			
		||||
extends jinja
 | 
			
		||||
extends html
 | 
			
		||||
							
								
								
									
										49
									
								
								vim/.vim/UltiSnips/markdown_tex.snippets
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										49
									
								
								vim/.vim/UltiSnips/markdown_tex.snippets
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,49 @@
 | 
			
		||||
# Md related
 | 
			
		||||
 | 
			
		||||
snippet check "put a open check box"
 | 
			
		||||
- [ ] ${1:${VISUAL:item}} $0
 | 
			
		||||
endsnippet
 | 
			
		||||
 | 
			
		||||
# Tex related
 | 
			
		||||
snippet tex "Inline Latex" i
 | 
			
		||||
\\\\( ${1:${VISUAL}} \\\\) $0
 | 
			
		||||
endsnippet
 | 
			
		||||
 | 
			
		||||
snippet Tex "Latex block" b
 | 
			
		||||
\\\\[
 | 
			
		||||
	${1:${VISUAL}}
 | 
			
		||||
\\\\]
 | 
			
		||||
$0
 | 
			
		||||
endsnippet
 | 
			
		||||
 | 
			
		||||
snippet bb "mathbb" i
 | 
			
		||||
\mathbb{${1:${VISUAL:R}}} $0
 | 
			
		||||
endsnippet
 | 
			
		||||
 | 
			
		||||
snippet text "implement text in tex" i
 | 
			
		||||
\text{ ${1:${VISUAL:text}} } $0
 | 
			
		||||
endsnippet
 | 
			
		||||
 | 
			
		||||
snippet br "break a line in tex mode" i
 | 
			
		||||
\\\\\\\\
 | 
			
		||||
$0
 | 
			
		||||
endsnippet
 | 
			
		||||
 | 
			
		||||
snippet frac "fractions" i
 | 
			
		||||
\frac{$1}{$2} $0
 | 
			
		||||
endsnippet
 | 
			
		||||
 | 
			
		||||
snippet beg "Beggin and end with the cursor on the type" i
 | 
			
		||||
\begin{${1:matrix}}}
 | 
			
		||||
	${2:${VISUAL}}
 | 
			
		||||
\end{$1}
 | 
			
		||||
endsnippet
 | 
			
		||||
 | 
			
		||||
snippet set "prepare for a set in tex {}" i
 | 
			
		||||
\\\\{ ${1:${VISUAL:e}} \\\\} $0
 | 
			
		||||
endsnippet
 | 
			
		||||
 | 
			
		||||
priority -1
 | 
			
		||||
snippet "(\w+)" "latex default" r
 | 
			
		||||
\\`!p snip.rv = match.group(1)` $1
 | 
			
		||||
endsnippet
 | 
			
		||||
							
								
								
									
										23
									
								
								vim/.vim/compiler/esp.vim
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										23
									
								
								vim/.vim/compiler/esp.vim
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,23 @@
 | 
			
		||||
" Vim compiler file modified for llvm esp
 | 
			
		||||
" Compiler:            	llvm 
 | 
			
		||||
" Previous Maintainer:  Nikolai Weibull <now@bitwi.se>
 | 
			
		||||
" Latest Revision:     	2023-10-19 
 | 
			
		||||
" 						forking by tonitch
 | 
			
		||||
 | 
			
		||||
if exists("current_compiler")
 | 
			
		||||
  finish
 | 
			
		||||
endif
 | 
			
		||||
let current_compiler = "esp"
 | 
			
		||||
 | 
			
		||||
let s:cpo_save = &cpo
 | 
			
		||||
set cpo&vim
 | 
			
		||||
 | 
			
		||||
let g:ycm_clangd_binary_path="/opt/llvm-esp/esp-clang/bin/clangd"
 | 
			
		||||
YcmRestartServer
 | 
			
		||||
let &makeprg="idf.py -C .."
 | 
			
		||||
 | 
			
		||||
"Should do a CompilerSet One day
 | 
			
		||||
 | 
			
		||||
let &cpo = s:cpo_save
 | 
			
		||||
unlet s:cpo_save
 | 
			
		||||
 | 
			
		||||
							
								
								
									
										5
									
								
								vim/.vim/ftplugin/c.vim
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								vim/.vim/ftplugin/c.vim
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,5 @@
 | 
			
		||||
" nnoremap <F12> :vert term ./build.sh<CR>
 | 
			
		||||
" nnoremap <Leader><F12> :execute 'tab term ./'. $prgname<CR>
 | 
			
		||||
 | 
			
		||||
let $MANPAGER='cat'
 | 
			
		||||
let $MANWIDTH=(&columns/2-4)
 | 
			
		||||
							
								
								
									
										3
									
								
								vim/.vim/ftplugin/go.vim
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										3
									
								
								vim/.vim/ftplugin/go.vim
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,3 @@
 | 
			
		||||
set keywordprg=go\ doc
 | 
			
		||||
unmap K
 | 
			
		||||
set makeprg=go\ run\ .
 | 
			
		||||
							
								
								
									
										1
									
								
								vim/.vim/ftplugin/python.vim
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								vim/.vim/ftplugin/python.vim
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1 @@
 | 
			
		||||
set foldmethod=indent
 | 
			
		||||
							
								
								
									
										61
									
								
								vim/.vim/plugin/Make.vim
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										61
									
								
								vim/.vim/plugin/Make.vim
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,61 @@
 | 
			
		||||
let s:making = 0
 | 
			
		||||
 | 
			
		||||
command -nargs=* Make call s:make(<q-args>)
 | 
			
		||||
 | 
			
		||||
function s:make(args) abort
 | 
			
		||||
 | 
			
		||||
	if s:making
 | 
			
		||||
		if bufwinid(s:make_buf) == -1
 | 
			
		||||
			" show making buffer
 | 
			
		||||
			exe 'sbuffer' s:make_buf
 | 
			
		||||
			wincmd p
 | 
			
		||||
		else
 | 
			
		||||
			"hide making buffer
 | 
			
		||||
			exe printf('%d wincmd q', bufwinnr(s:make_buf))
 | 
			
		||||
		endif
 | 
			
		||||
		return
 | 
			
		||||
	endif
 | 
			
		||||
 | 
			
		||||
	" delete last result
 | 
			
		||||
	if exists('s:make_buf') && bufexists(s:make_buf)
 | 
			
		||||
		silent! exe 'bdelete' s:make_buf
 | 
			
		||||
	endif
 | 
			
		||||
 | 
			
		||||
	"spawn new make
 | 
			
		||||
	let cmd = &makeprg 
 | 
			
		||||
	if !empty(a:args)
 | 
			
		||||
		let cmd .= ' ' . a:args
 | 
			
		||||
	endif
 | 
			
		||||
 | 
			
		||||
	let options = {'close_cb': function('s:make_callback'), 'term_rows': 16}
 | 
			
		||||
 | 
			
		||||
	let s:make_buf = term_start(cmd, options)
 | 
			
		||||
	let s:making = 1
 | 
			
		||||
 | 
			
		||||
	wincmd p
 | 
			
		||||
endfunction
 | 
			
		||||
 | 
			
		||||
func s:make_callback(channel)
 | 
			
		||||
 | 
			
		||||
  " look, you can not get buffer content directly here.
 | 
			
		||||
  call timer_start(10, function('s:make_callback_impl'))
 | 
			
		||||
endfunction
 | 
			
		||||
 | 
			
		||||
function s:make_callback_impl(timer) abort
 | 
			
		||||
 | 
			
		||||
  exe 'cgetbuffer' s:make_buf
 | 
			
		||||
 | 
			
		||||
  " consider entry with num zero bufnr and lnum an error or warning
 | 
			
		||||
  let qfl = filter(getqflist(), {k,v -> v.bufnr != 0 && v.lnum != 0})
 | 
			
		||||
 | 
			
		||||
  if empty(qfl)
 | 
			
		||||
    echo "make successful"
 | 
			
		||||
  else
 | 
			
		||||
    echohl WarningMsg
 | 
			
		||||
    echom printf('found %d qf entries', len(qfl))
 | 
			
		||||
    echohl None
 | 
			
		||||
  endif
 | 
			
		||||
 | 
			
		||||
  let s:making = 0
 | 
			
		||||
 | 
			
		||||
endfunction
 | 
			
		||||
							
								
								
									
										6
									
								
								vim/.vim/vimfile/after/syntax/html.vim
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										6
									
								
								vim/.vim/vimfile/after/syntax/html.vim
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,6 @@
 | 
			
		||||
syn region djangotagmarkers start="{{" end="}}"
 | 
			
		||||
syn region djangovariablemarkers start="{%" end="%}"
 | 
			
		||||
command! -nargs=+ HiLink hi def link <args>
 | 
			
		||||
HiLink djangotagmarkers PreProc
 | 
			
		||||
HiLink djangovariablemarkers PreProc
 | 
			
		||||
delcommand HiLink
 | 
			
		||||
		Reference in New Issue
	
	Block a user