Created
December 3, 2020 02:22
-
-
Save airglow923/102530db3d2077a94a9b4a00fde4d80b to your computer and use it in GitHub Desktop.
Clean up the LaTeX related files other than .pdf and .tex.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
usage() { | |
echo "Usage: $0 [FILENAME]" | |
1>&2; | |
exit 1; | |
} | |
if [ "$#" -ne 1 ]; then | |
echo "Only a filename is needed." | |
usage | |
fi | |
EXTENSIONS=('aux' 'fdb_latexmk' 'fls' 'log' 'synctex.gz') | |
for extension in ${EXTENSIONS[@]}; do | |
if [[ -f $1.$extension ]]; then | |
rm $1.$extension | |
fi | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment