Merge branch 'master' of git://projects.mako.cc:/latex_mako into groceryheist
This commit is contained in:
commit
42469788ed
2
paper_template/.gitignore
vendored
2
paper_template/.gitignore
vendored
@ -11,3 +11,5 @@
|
|||||||
/*.fdb_latexmk
|
/*.fdb_latexmk
|
||||||
/*.fls
|
/*.fls
|
||||||
/*.ttt
|
/*.ttt
|
||||||
|
/*.bcf
|
||||||
|
/*.run.xml
|
||||||
|
|||||||
@ -7,19 +7,14 @@ all: $(patsubst %.tex,%.pdf,$(wildcard *.tex))
|
|||||||
# %.tex: %.Rnw
|
# %.tex: %.Rnw
|
||||||
# Rscript -e "library(knitr); knit('$<')"
|
# Rscript -e "library(knitr); knit('$<')"
|
||||||
|
|
||||||
refs-processed.bib:
|
%.pdf: %.tex
|
||||||
perl -p -e 's/©//' refs.bib > refs-processed.bib
|
|
||||||
perl -0pe 's/,\s+(file|abstract) = \{.*?\}(,\n|\n)/\2/sg' refs-processed.bib |sponge refs-processed.bib
|
|
||||||
recode -d u8..ltex < refs-processed.bib | sponge refs-processed.bib
|
|
||||||
|
|
||||||
%.pdf: %.tex refs-processed.bib vc
|
|
||||||
latexmk -f -pdf $<
|
latexmk -f -pdf $<
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
latexmk -C *.tex
|
latexmk -C *.tex
|
||||||
rm -f *.tmp
|
rm -f *.tmp *.run.xml
|
||||||
rm -f vc
|
rm -f vc
|
||||||
rm -f refs-processed.bib
|
rm -f *.bbl
|
||||||
# the following lines are useful for Rnw/knitr
|
# the following lines are useful for Rnw/knitr
|
||||||
# rm -rf cache/ figure/
|
# rm -rf cache/ figure/
|
||||||
# rm -f *.tex
|
# rm -f *.tex
|
||||||
@ -33,3 +28,4 @@ vc:
|
|||||||
pdf: all
|
pdf: all
|
||||||
|
|
||||||
.PHONY: clean all
|
.PHONY: clean all
|
||||||
|
# .PRECIOUS: %.tex
|
||||||
|
|||||||
@ -209,8 +209,8 @@
|
|||||||
\makepsmarks{mako-mem-git}{\@gitmarks}
|
\makepsmarks{mako-mem-git}{\@gitmarks}
|
||||||
\makeevenhead{mako-mem-git}{}{}{\scshape\thepage}
|
\makeevenhead{mako-mem-git}{}{}{\scshape\thepage}
|
||||||
\makeoddhead{mako-mem-git}{}{}{\scshape\thepage}
|
\makeoddhead{mako-mem-git}{}{}{\scshape\thepage}
|
||||||
\makeevenfoot{mako-mem-git}{}{\texttt{\footnotesize{\textcolor{Blue}{git revision \VCRevision\ on \VCDateTEX}}}}{}
|
\makeevenfoot{mako-mem-git}{}{\texttt{\footnotesize{\textcolor{BrickRed}{git revision \VCRevision\ on \VCDateTEX}}}}{}
|
||||||
\makeoddfoot{mako-mem-git}{}{\texttt{\footnotesize \textcolor{Blue}{git revision \VCRevision\ on \VCDateTEX}}}{}
|
\makeoddfoot{mako-mem-git}{}{\texttt{\footnotesize \textcolor{BrickRed}{git revision \VCRevision\ on \VCDateTEX}}}{}
|
||||||
|
|
||||||
%% Create a command to make a note at the top of the first page describing the
|
%% Create a command to make a note at the top of the first page describing the
|
||||||
%% publication status of the paper.
|
%% publication status of the paper.
|
||||||
|
|||||||
@ -8,8 +8,7 @@
|
|||||||
% with article-3 \chapterstyle, change to: \pagestyle{memo}
|
% with article-3 \chapterstyle, change to: \pagestyle{memo}
|
||||||
\pagestyle{mako-mem}
|
\pagestyle{mako-mem}
|
||||||
|
|
||||||
\usepackage{ucs}
|
\usepackage[utf8]{inputenc}
|
||||||
\usepackage[utf8x]{inputenc}
|
|
||||||
|
|
||||||
\usepackage[T1]{fontenc}
|
\usepackage[T1]{fontenc}
|
||||||
\usepackage{textcomp}
|
\usepackage{textcomp}
|
||||||
@ -34,7 +33,19 @@
|
|||||||
urlcolor=Blue, unicode=true}
|
urlcolor=Blue, unicode=true}
|
||||||
|
|
||||||
% add bibliographic stuff
|
% add bibliographic stuff
|
||||||
\usepackage[round]{natbib}
|
% add bibliographic stuff
|
||||||
|
\usepackage[american]{babel}
|
||||||
|
\usepackage{csquotes}
|
||||||
|
\usepackage[natbib=true, style=apa, backend=biber]{biblatex}
|
||||||
|
\addbibresource{refs.bib}
|
||||||
|
\DeclareLanguageMapping{american}{american-apa}
|
||||||
|
|
||||||
|
\defbibheading{secbib}[\bibname]{%
|
||||||
|
\section*{#1}%
|
||||||
|
\markboth{#1}{#1}%
|
||||||
|
\baselineskip 14.2pt%
|
||||||
|
\prebibhook}
|
||||||
|
|
||||||
\def\citepos#1{\citeauthor{#1}'s (\citeyear{#1})}
|
\def\citepos#1{\citeauthor{#1}'s (\citeyear{#1})}
|
||||||
\def\citespos#1{\citeauthor{#1}' (\citeyear{#1})}
|
\def\citespos#1{\citeauthor{#1}' (\citeyear{#1})}
|
||||||
|
|
||||||
@ -162,10 +173,8 @@ lazy dog. The quick brown fox jumps over the lazy dog. The quick brown
|
|||||||
fox jumps over the lazy dog \citep{989866}.
|
fox jumps over the lazy dog \citep{989866}.
|
||||||
|
|
||||||
% bibliography here
|
% bibliography here
|
||||||
\renewcommand{\bibsection}{\section{\bibname}\prebibhook}
|
\printbibliography[title = {References}, heading=secbib]
|
||||||
\baselineskip 14.2pt
|
|
||||||
\bibliography{refs-processed}
|
|
||||||
\bibliographystyle{apalike}
|
|
||||||
|
|
||||||
\end{document}
|
\end{document}
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user