diff options
author | tdro <tdro@users.noreply.github.com> | 2025-03-24 00:00:00 +0000 |
---|---|---|
committer | tdro <tdro@users.noreply.github.com> | 2025-03-24 00:00:00 +0000 |
commit | b0d214818c7b78fe880f4bf301cbeffc6048c630 (patch) | |
tree | eb93347db458d450e82e37abbc2cfde8d69d2ab5 | |
parent | f27c9d730bdc528ae874ee3a67e69455a163b3a4 (diff) | |
download | dotfiles-b0d214818c7b78fe880f4bf301cbeffc6048c630.tar.gz dotfiles-b0d214818c7b78fe880f4bf301cbeffc6048c630.tar.bz2 dotfiles-b0d214818c7b78fe880f4bf301cbeffc6048c630.zip |
.local/bin/latex-compile: Update
-rw-r--r-- | .config/vim/vimrc | 2 | ||||
-rwxr-xr-x | .local/bin/latex-compile | 7 |
2 files changed, 2 insertions, 7 deletions
diff --git a/.config/vim/vimrc b/.config/vim/vimrc index 52fdcc2..8ae6664 100644 --- a/.config/vim/vimrc +++ b/.config/vim/vimrc @@ -272,6 +272,7 @@ augroup AutoCommands autocmd FileType toml autocmd! BufWritePost <buffer> exe 'Notify(''tomll ' . expand('%') . ' 2>&1 && printf "TOML OK: ' . expand('%') . '"'')' | :e | Make autocmd FileType nim autocmd! BufWritePost <buffer> exe 'Notify(''nimpretty ' . expand('%') . ' 2>&1 && printf "Nim OK: ' . expand('%') . '"'')' | :e | Make autocmd FileType rust autocmd! BufWritePost <buffer> exe 'Notify(''rustfmt ' . expand('%') . ' 2>&1 && printf "rustfmt OK: ' . expand('%') . '"'')' | :e | Make + autocmd FileType tex autocmd! BufWritePost <buffer> exe 'Notify(''latexindent ' . expand('%') . ' 2>&1 && printf "LaTeX OK: ' . expand('%') . '"'')' | :e | Make autocmd FileType python autocmd! BufWritePost <buffer> exe 'Notify(''ruff check --no-cache ' . expand('%') . ' 2>&1 && black ' . expand('%') . ' 2>&1'')' | :e | Make autocmd FileType ruby autocmd! BufWritePost <buffer> exe 'Notify(''rubocop --fix-layout ' . expand('%') . ' 2>&1 && rubocop ' . expand('%') . ' 2>&1'')' | :e | Make autocmd FileType javascript autocmd! BufWritePost <buffer> exe 'Notify(''eslint --fix ' . expand('%') . ' 2>&1 && printf "JavaScript OK: '. expand('%') . '"'')' | :e | Make @@ -283,7 +284,6 @@ augroup AutoCommands autocmd FileType go autocmd! BufWritePost <buffer> exe 'Notify(''gofmt -w -s -e ' . expand('%') . ' 2>&1 && go vet ' . expand('%') . ' 2>&1 && printf "Go Format OK: ' . expand('%') . '"'')' | :e | Make autocmd FileType nix autocmd! BufWritePost <buffer> exe 'Notify(''nix-linter ' . expand('%') . ' 2>&1 && printf "Nix Lint OK: ' . expand('%') . '"' . ' && nixfmt ' . expand('%') . ' 2>&1' . ''')' | :e | Make autocmd FileType php autocmd! BufWritePost <buffer> exe 'Notify(''phpcbf ' . expand('%') . ' 2>&1 && phpstan --no-progress --no-ansi --no-interaction analyze --level max ' . expand('%') . ' 2>&1'')' | :e | Make - autocmd FileType tex autocmd! BufWritePost <buffer> exe 'Notify(''latexindent ' . expand('%') . ' 2>&1 && printf "LaTeX OK: ' . expand('%') . '"'')' | :e | :only | :term ++close ++rows=10 latex-compile % | Make autocmd FileType bindzone autocmd! BufWritePost <buffer> exe 'Notify(''file="' . expand('%') . '" && named-checkzone "$(head --lines=1 "$file" | cut --delimiter=" " --fields=2 | perl -ple "chop")" $file'')' | :e | Make autocmd FileType json,jsonc autocmd! BufWritePost <buffer> exe 'Notify(''json5 ' . expand('%') . ' -o ' . expand('%') . ' && ' . 'jsonlint -i ' . expand('%') . ' 2>&1 && printf "JSON OK: ' . expand('%') . '"'')' | :e | Make autocmd FileType *react autocmd! BufWritePost <buffer> exe 'Notify(''export DENO_DIR=/dev/null && deno fmt --ext=tsx ' . expand('%') . ' 2>&1 && NO_COLOR=true deno lint --ext=tsx ' . expand('%') . ' 2>&1'')' | :e | Make diff --git a/.local/bin/latex-compile b/.local/bin/latex-compile index 25f92b6..3fb5b8c 100755 --- a/.local/bin/latex-compile +++ b/.local/bin/latex-compile @@ -1,8 +1,3 @@ #!/bin/sh -eu -if ! { - pdflatex -shell-escape -halt-on-error "$1" || - xelatex -shell-escape -halt-on-error "$1" -}; then - cat -fi +pdflatex -shell-escape -halt-on-error "$1" || xelatex -shell-escape -halt-on-error "$1" |