Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add minor Makefile improvements #51

Merged
merged 4 commits into from
Oct 2, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 8 additions & 9 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,25 +1,24 @@
# Source Latex files
# Source LaTeX files
TEX_MAIN_PAPER = paper.tex
TEX_MAIN_SUBMISSION = submission.tex

# Generate PDF files
PDF_PAPER = paper.pdf
PDF_SUBMISSION = submission.pdf
# Generated PDF files
PDF_PAPER := $(TEX_MAIN_PAPER:.tex=.pdf)
PDF_SUBMISSION := $(TEX_MAIN_SUBMISSION:.tex=.pdf)

# Resources
IMAGES := $(wildcard images/*.jpg images/*.pdf images/*.png)

# grammar is a phony rule, it generates index.html
# from textidote
.PHONY: grammar
.PHONY: all grammar paper submission view-paper view-submission clean

all: ${PDF_SUBMISSION} ${PDF_PAPER}

# spelling and grammar
grammar: paper.tex
grammar: $(TEX_MAIN_PAPER)
# check that textidote exists.
@textidote --version
# allowed to fail since it throws error if we have grammar mistakes
-textidote --check en --output html paper.tex > index.html
-textidote --check en --output html $< > index.html
python3 -m http.server

${PDF_PAPER}: ${TEX_MAIN_PAPER} ${IMAGES}
Expand Down
Loading