1
0
Fork 0
mirror of https://github.com/SinTan1729/random.git synced 2024-12-26 21:18:36 -06:00

rewrote latex-cleanup

This commit is contained in:
Sayantan Santra 2021-06-29 22:50:52 +05:30
parent d833e8eaa9
commit e681db38f3

View file

@ -2,6 +2,14 @@
#!/bin/bash #!/bin/bash
[ 0 -lt $(ls *.tex 2>/dev/null | wc -w) ] && find . -maxdepth 1 -type f -regex ".*\.\(aux\|log\|synctex.gz\|bbl\|blg\)" -exec totrash {} \; for f in *.tex; do
h=$(basename "$f" .tex)
echo "Trashing files accompanying $h.tex..."
for g in "$h".*; do
if [[ ${g: -4} != ".tex" && ${g: -4} != ".pdf" ]] ; then
echo "Trashing $g..."
totrash "$g"
fi
done
done
echo "Done!" echo "Done!"