From 8a2e1006b3b272126332aa064f3ad95387129544 Mon Sep 17 00:00:00 2001 From: Biswakalyan Bhuyan Date: Thu, 13 Feb 2025 14:13:49 +0530 Subject: new dot files --- .local/bin/texclear | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100755 .local/bin/texclear (limited to '.local/bin/texclear') diff --git a/.local/bin/texclear b/.local/bin/texclear new file mode 100755 index 0000000..6ad3c12 --- /dev/null +++ b/.local/bin/texclear @@ -0,0 +1,9 @@ +#!/bin/sh + +# Clears the build files of a LaTeX/XeLaTeX build. +# I have vim run this file whenever I exit a .tex file. + +[ "${1##*.}" = "tex" ] && { + find "$(dirname "${1}")" -regex '.*\(_minted.*\|.*\.\(4tc\|xref\|tmp\|pyc\|pyg\|pyo\|fls\|vrb\|fdb_latexmk\|bak\|swp\|aux\|log\|synctex\(busy\)\|lof\|lot\|maf\|idx\|mtc\|mtc0\|nav\|out\|snm\|toc\|bcf\|run\.xml\|synctex\.gz\|blg\|bbl\)\)' -delete +} || printf "Provide a .tex file.\n" + -- cgit v1.2.3-59-g8ed1b