From f1c74050126755ca07299ed3438eccac3613812b Mon Sep 17 00:00:00 2001 From: aartoni Date: Sat, 9 Nov 2024 14:43:31 +0700 Subject: latexmk --- .local/bin/compiler | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) (limited to '.local') diff --git a/.local/bin/compiler b/.local/bin/compiler index 5713590..7497ad2 100755 --- a/.local/bin/compiler +++ b/.local/bin/compiler @@ -6,9 +6,6 @@ # Compiles .tex. groff (.mom, .ms), .rmd, .md, .org. Opens .sent files as sent # presentations. Runs scripts based on extension or shebang. -# Note that .tex files which you wish to compile with XeLaTeX should have the -# string "xelatex" somewhere in a comment/command in the first 5 lines. - file="${1}" ext="${file##*.}" dir=${file%/*} @@ -38,15 +35,6 @@ case "${ext}" in sass) sassc -a "${file}" "${base}.css" ;; scad) openscad -o "${base}.stl" "${file}" ;; sent) setsid -f sent "${file}" 2> "/dev/null" ;; - tex) - textarget="$(getcomproot "${file}" || echo "${file}")" - command="pdflatex" - head -n5 "${textarget}" | grep -qi "xelatex" && command="xelatex" - ${command} --output-directory="${textarget%/*}" "${textarget%.*}" && - grep -qi addbibresource "${textarget}" && - biber --input-directory "${textarget%/*}" "${textarget%.*}" && - ${command} --output-directory="${textarget%/*}" "${textarget%.*}" && - ${command} --output-directory="${textarget%/*}" "${textarget%.*}" - ;; + tex) latexmk ;; *) sed -n '/^#!/s/^#!//p; q' "${file}" | xargs -r -I % "${file}" ;; esac -- cgit v1.3.1