summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/latex/cquthesis/makewin-en.bat
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2018-03-06 22:52:46 +0000
committerKarl Berry <karl@freefriends.org>2018-03-06 22:52:46 +0000
commit68f82734361bd2681fdbec0be05baa870c9c5381 (patch)
tree34c5ef50efa226f21a1d523a4494207d23dda9a6 /Master/texmf-dist/source/latex/cquthesis/makewin-en.bat
parent6f23c60d38f2b753f974e3c2173c3ddd76e3b346 (diff)
cquthesis (6mar18)
git-svn-id: svn://tug.org/texlive/trunk@46863 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source/latex/cquthesis/makewin-en.bat')
-rwxr-xr-xMaster/texmf-dist/source/latex/cquthesis/makewin-en.bat141
1 files changed, 141 insertions, 0 deletions
diff --git a/Master/texmf-dist/source/latex/cquthesis/makewin-en.bat b/Master/texmf-dist/source/latex/cquthesis/makewin-en.bat
new file mode 100755
index 00000000000..5feedc19dc9
--- /dev/null
+++ b/Master/texmf-dist/source/latex/cquthesis/makewin-en.bat
@@ -0,0 +1,141 @@
+@echo off
+
+
+cd /d "%~dp0"
+
+title CQUThesis Build Helper
+
+set flag=%1
+if %flag%x == x (
+ set flag=thesis
+)
+
+if %flag%x == thesisx (
+ call:thesis
+ goto :EOF
+)
+if %flag%x == thesisxx (
+ call:thesisx
+ goto :EOF
+)
+if %flag%x == docx (
+ call:extract
+ call:document
+ goto :EOF
+)
+if %flag%x == cleanx (
+ call:cleanaux
+ goto :EOF
+)
+if %flag%x == cleanpdfx (
+ call:cleanpdf
+ goto :EOF
+)
+if %flag%x == cleanallx (
+ call:cleanaux
+ call:cleanpdf
+ goto :EOF
+)
+if %flag%x == extractx (
+ call:extract
+ goto :EOF
+)
+if %flag%x == allx (
+ call:thesis
+ call:document
+ goto :EOF
+)
+if %flag%x == buildx (
+ call:extract
+ call:thesis
+ goto :EOF
+)
+if %flag%x == buildxx (
+ call:extract
+ call:thesis
+ call:document
+ goto :EOF
+)
+
+:help
+ echo *************************************************************
+ echo This is the Makefile script for CQUThesis on Windows.
+ echo For CQUThesis: https://github.com/nanmu42/CQUThesis
+ echo by Zhennan Li (C) 2016 under LPPL 1.3
+ echo The idea comes from Github Liam0205/sduthesis, Many thanks!
+ echo *************************************************************
+ echo *
+ echo USAGE:
+ echo makewin [param]
+ echo param:
+ echo help Display this help text
+ echo thesis (default)Compile the thesis via latexmk
+ echo thesisx Compile the thesis via XeLaTeX(only if latexmk is not installed.)
+ echo doc Compile the documentation of CQUThesis
+ echo clean Clean all aux files
+ echo cleanpdf Clean all PDFs
+ echo cleanall Clean all aux files and all PDFs
+ echo extract Extract the Thesis Template from .dtx files.
+ echo all thesis + doc
+ echo build extract + thesis
+ echo buildx extract + thesis + doc
+ echo *
+ echo ***********************Happy TeXing**************************
+goto :EOF
+
+:checkfiles
+ IF NOT EXIST cquthesis.cls call:extract
+ IF NOT EXIST cquthesis.cfg call:extract
+goto :EOF
+
+:thesis
+ call:checkfiles
+ latexmk -xelatex main.tex
+goto :EOF
+
+:thesisx
+ call:checkfiles
+ xelatex main.tex
+ bibtex main.tex
+ xelatex main.tex
+ xelatex main.tex
+ xelatex main.tex
+goto :EOF
+
+:cleanaux
+ echo cleaning aux...
+ for %%i in (*.aux *.bbl *.equ *.glo *.gls *.hd *.idx *.ilg *.ind *.lof *.lot *.out *.blg *.log *.thm *.toc *.synctex.gz *.lofEN *.lotEN *.equEN) do (
+ del %%i
+ )
+ echo Done.
+goto :EOF
+
+:cleanpdf
+ echo cleaning pdf...
+ for %%i in (*.pdf) do (
+ del %%i
+ )
+ echo Done.
+goto :EOF
+
+:clean_all
+ call:cleanaux
+ call:cleanpdf
+goto :EOF
+
+:extract
+ echo extracting...
+ latex cquthesis.ins
+ echo *******CQUThesis has been extracted.********
+goto :EOF
+
+:document
+ echo building documents...
+ set cmode=-interaction=batchmode
+ xelatex cquthesis.dtx
+ makeindex -s gind.ist -o cquthesis.ind cquthesis.idx
+ makeindex -s gglo.ist -o cquthesis.gls cquthesis.glo
+ xelatex cquthesis.dtx
+ xelatex cquthesis.dtx
+ xelatex cquthesis.dtx
+goto :EOF