aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortdro <tdro@users.noreply.github.com>2021-11-05 00:50:45 -0400
committertdro <tdro@users.noreply.github.com>2021-11-05 00:50:45 -0400
commit59f76b360b5e837055e06d95a9a6bfdab9909003 (patch)
tree9aa6eb4911952576a580dc5b510c3d398b848368
parentfb5381832c7e90011abcb59856b290f70cc62aff (diff)
downloaddotfiles-59f76b360b5e837055e06d95a9a6bfdab9909003.tar.gz
dotfiles-59f76b360b5e837055e06d95a9a6bfdab9909003.tar.bz2
dotfiles-59f76b360b5e837055e06d95a9a6bfdab9909003.zip
.local/bin/latexindent: Move defaults here
Allow modifying line-breaks.
-rwxr-xr-x.local/bin/latexindent8
-rw-r--r--.vimrc2
2 files changed, 8 insertions, 2 deletions
diff --git a/.local/bin/latexindent b/.local/bin/latexindent
index 09b9750..44e7459 100755
--- a/.local/bin/latexindent
+++ b/.local/bin/latexindent
@@ -1,2 +1,8 @@
#!/bin/sh -eu
-$(which latexindent --all | grep --invert-match "local/bin" | head -n 1) --local="$HOME/.config/latexindent/settings.yaml" "$@";
+$(which latexindent --all | grep --invert-match "local/bin" | head -n 1) \
+ --modifylinebreaks \
+ --overwrite \
+ --silent \
+ --cruft=/tmp \
+ --local="$HOME/.config/latexindent/settings.yaml" \
+ "$@";
diff --git a/.vimrc b/.vimrc
index 5f2d275..f6da3a4 100644
--- a/.vimrc
+++ b/.vimrc
@@ -311,10 +311,10 @@ augroup AutoCommands
autocmd FileType haskell autocmd! BufWritePost <buffer> exe 'Notify(''hlint ' . expand('%') . ' 2>&1 && brittany --write-mode inplace ' . expand('%') . ' 2>&1'')' | :e
autocmd FileType c autocmd! BufWritePost <buffer> exe 'Notify(''clang-format -i ' . expand('%') . ' 2>&1 && printf "Clang Format OK: ' . expand('%') . '"'')' | :e
autocmd FileType bash,sh autocmd! BufWritePost <buffer> exe 'Notify(''shellcheck -x --exclude=SC1090,SC1091 ' . expand('%') . ' 2>&1 && printf "Shellcheck OK: ' . expand('%') . '"'')'
- autocmd FileType tex autocmd! BufWritePost <buffer> exe 'Notify(''latexindent --silent --cruft=/tmp --overwrite ' . expand('%') . ' 2>&1 && printf "LaTeX OK: ' . expand('%') . '"'')' | :e | :only | :term ++close ++rows=10 latex-compile %
autocmd FileType javascript autocmd! BufWritePost <buffer> exe 'Notify(''eslint -c $HOME/.config/eslintrc.yml --fix ' . expand('%') . ' 2>&1 && printf "JavaScript OK: '. expand('%') . '"'')' | :e
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
autocmd FileType nix autocmd! BufWritePost <buffer> exe 'Notify(''nix-linter ' . expand('%') . ' 2>&1 && printf "Nix Lint OK: ' . expand('%') . '"' . ' && nixfmt ' . expand('%') . ' 2>&1' . ''')' | :e
+ autocmd FileType tex autocmd! BufWritePost <buffer> exe 'Notify(''latexindent ' . expand('%') . ' 2>&1 && printf "LaTeX OK: ' . expand('%') . '"'')' | :e | :only | :term ++close ++rows=10 latex-compile %
autocmd FileType awk autocmd! BufWritePost <buffer> exe 'Notify(''awk -g -f ' . expand('%') . ' 2>&1 && awk -o- -f ' . expand('%') . ' | sponge ' . expand('%') . ' && printf "AWK OK: ' . expand('%') . '"'')' | :e
autocmd FileType yaml autocmd! BufWritePost <buffer> exe 'Notify(''yaml round-trip --indent 2 --save ' . expand('%') . ' 2>&1 && yamllint -s ' . expand('%') . ' 2>&1 && printf "YAML OK: ' . expand('%') . '"'')' | :e
autocmd FileType typescript autocmd! BufWritePost <buffer> exe 'Notify(''deno fmt ' . expand('%') . ' 2>&1 && NO_COLOR=true deno lint ' . expand('%') . ' 2>&1'')' | :e | :only | :term ++rows=10 deno run --config tsconfig.json --allow-all --location https://example.com/ %