
# Makefile for converting Lecture Notes

# Find all .tex files in the folder
TEXFILES := $(wildcard *.tex)

# Define the output files: We want one .pdf and one .html for every .tex
PDFS := $(TEXFILES:.tex=.pdf)
HTMLS := $(TEXFILES:.tex=.html)

# The default "make" command will build BOTH formats
all: $(PDFS) $(HTMLS)

# Rule to build PDF (using standard pdflatex)
%.pdf: %.tex
	pdflatex $<

# Rule to build HTML (using Pandoc with your styling)
%.html: %.tex
	pandoc $< -o $@ --standalone --mathjax -H mathjax_conf.html --css=academic.css
	
# Clean up command to remove messy logs
clean:
	rm -f *.aux *.log *.out *.toc



