Skip to content

Instantly share code, notes, and snippets.

Created January 6, 2013 17:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/4c4c2a1bb5933113ff08 to your computer and use it in GitHub Desktop.
Save anonymous/4c4c2a1bb5933113ff08 to your computer and use it in GitHub Desktop.
#!/bin/bash
#make clean
make latexpdfja
TEXFILE=_build/latex/hoge.tex
sed -i -e 's/commandchars/frame=single,commandchars/' $TEXFILE
sed -i -e '/\maketitle/d' $TEXFILE
sed -i -e '/tableofcontents/d' $TEXFILE
sed -i -e '/\phantomsection\label{index::doc}/d' $TEXFILE
sed -i -e '/Contents:/d' $TEXFILE
sed -i -e '/\section{Indices and tables}/d' $TEXFILE
sed -i -e '/\label{index:indices-and-tables}\begin{itemize}/d' $TEXFILE
sed -i -e '/\emph{genindex}/d' $TEXFILE
sed -i -e '/\emph{modindex}/d' $TEXFILE
sed -i -e '/\emph{search}/d' $TEXFILE
sed -i -e '/\renewcommand{\indexname}{索引}/d' $TEXFILE
sed -i -e '/\printindex/d' $TEXFILE
cd _build/latex/
platex hoge.tex && dvipdfmx -p b5 -r 600 -v -V 3 -o index-b5.pdf hoge.dvi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment