diverse changes for qol

- remapping the substitution to <leader>ss in nvim to not conflict with line replacement
- moving the gitrepo directory
- making compiler for octave silent
master
TiynGER 4 years ago
parent 5445b3c088
commit e878a83893

@ -106,7 +106,7 @@ vnoremap <C-c> "+y
cnoremap w!! execute 'silent! write !sudo tee % >/dev/null' <bar> edit! cnoremap w!! execute 'silent! write !sudo tee % >/dev/null' <bar> edit!
" alias for replacing " alias for replacing
nnoremap S :%s//gI<Left><Left><Left> nnoremap <leader>ss :%s//gI<Left><Left><Left>
" read files correctly " read files correctly
autocmd BufRead,BufNewFile *.tex set filetype=tex autocmd BufRead,BufNewFile *.tex set filetype=tex

@ -1,7 +1,7 @@
#!/bin/bash #!/bin/bash
# copying tex templates # copying tex templates
latexdir=~/gitrepos/main/latextemplates/ latexdir=~/code/main/latextemplates/
[ -z "$2" ] && echo "missing argument: filename (no ending)" && return 1 [ -z "$2" ] && echo "missing argument: filename (no ending)" && return 1

@ -28,7 +28,7 @@ case "$file" in
*\.[0-9]) refer -PS -e "$file" | groff -mandoc -T pdf > "$base".pdf ;; *\.[0-9]) refer -PS -e "$file" | groff -mandoc -T pdf > "$base".pdf ;;
*\.rmd) echo "require(rmarkdown); render('$file')" | R -q --vanilla ;; *\.rmd) echo "require(rmarkdown); render('$file')" | R -q --vanilla ;;
*\.tex) textype "$file" ;; *\.tex) textype "$file" ;;
*\.m) octave --no-window-system "$file" ;; *\.m) octave -qW "$file" ;;
*\.md) pandoc "$file" --pdf-engine=xelatex -o "$base".pdf ;; *\.md) pandoc "$file" --pdf-engine=xelatex -o "$base".pdf ;;
*config.h) sudo make install ;; *config.h) sudo make install ;;
*\.c) if [ -f Makefile ]; then make run; else cc "$file" -o "$base" && "$base"; fi ;; *\.c) if [ -f Makefile ]; then make run; else cc "$file" -o "$base" && "$base"; fi ;;

Loading…
Cancel
Save