Skip to content

Commit

Permalink
Make the makefile compatible across linux and osx
Browse files Browse the repository at this point in the history
  • Loading branch information
andycasey committed Aug 23, 2016
1 parent 4ede20e commit bc309bd
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions article/Makefile
Expand Up @@ -9,6 +9,9 @@ vc.tex: ../.git/logs/HEAD
git config --get remote.origin.url | sed "s/\.git$$//" | sed "s/ssh:\/\/git\@/https:\/\/www\./" >> vc.tex
echo '}}' >> vc.tex
git log -1 --date=short --format="format:\\newcommand{\\githash}{%h}\\newcommand{\\gitdate}{%ad}\\newcommand{\\gitauthor}{%an}" >> vc.tex
# Safely replace newline character if it exists
cat vc.tex | sed "s/^ewcommand/\\\newcommand/" > vc_safe.tex
mv vc_safe.tex vc.tex

%.pdf: %.tex vc.tex
${LATEX} $<
Expand Down

0 comments on commit bc309bd

Please sign in to comment.