summaryrefslogtreecommitdiffstats
path: root/.local
diff options
context:
space:
mode:
authorDennis Lee <dennis@dennislee.xyz>2020-05-24 10:13:27 -0700
committerGitHub <noreply@github.com>2020-05-24 13:13:27 -0400
commit7f3437710586fd7a019e9524fcf8ab7f38ab6ef8 (patch)
tree687e45248d5fc7c6db3654f599603a34cf39e0d8 /.local
parentc9f0d747a80fb95be6efc4d50fd94baa6a02809f (diff)
downloadeibhear-7f3437710586fd7a019e9524fcf8ab7f38ab6ef8.tar.gz
eibhear-7f3437710586fd7a019e9524fcf8ab7f38ab6ef8.tar.zst
eibhear-7f3437710586fd7a019e9524fcf8ab7f38ab6ef8.zip
run preconv and pipe its output into refer to prevent unicode problems (#647)
* compiler: preconv to prevent `refer` unicode error * compiler: fix formatting
Diffstat (limited to '.local')
-rwxr-xr-x.local/bin/compiler10
1 files changed, 5 insertions, 5 deletions
diff --git a/.local/bin/compiler b/.local/bin/compiler
index 0f693d2..51d14f5 100755
--- a/.local/bin/compiler
+++ b/.local/bin/compiler
@@ -20,17 +20,17 @@ textype() { \
biber --input-directory "$dir" "$base" &&
$command --output-directory="$dir" "$base" &&
$command --output-directory="$dir" "$base"
- }
+}
case "$file" in
- *\.ms) refer -PS -e "$file" | groff -me -ms -kept -T pdf > "$base".pdf ;;
- *\.mom) refer -PS -e "$file" | groff -mom -kept -T pdf > "$base".pdf ;;
- *\.[0-9]) refer -PS -e "$file" | groff -mandoc -T pdf > "$base".pdf ;;
+ *\.ms) preconv "$file" | refer -PS -e | groff -me -ms -kept -T pdf > "$base".pdf ;;
+ *\.mom) preconv "$file" | refer -PS -e | groff -mom -kept -T pdf > "$base".pdf ;;
+ *\.[0-9]) preconv "$file" | refer -PS -e | groff -mandoc -T pdf > "$base".pdf ;;
*\.[rR]md) Rscript -e "rmarkdown::render('$file', quiet=TRUE)" ;;
*\.tex) textype "$file" ;;
*\.md) pandoc "$file" --pdf-engine=xelatex -o "$base".pdf ;;
*config.h) sudo make install ;;
- *\.c) cc "$file" -o "$base" && "$base" ;;
+ *\.c) cc "$file" -o "$base" && "$base" ;;
*\.py) python "$file" ;;
*\.m) octave "$file" ;;
*\.scad) openscad -o "$base".stl "$file" ;;