26 lines
626 B
Makefile
Executable File
26 lines
626 B
Makefile
Executable File
# An example makefile to generate a pdf slideshow from markdown
|
|
# Uses pandoc, beamer
|
|
#
|
|
# Ideas from this video https://youtu.be/dum7q6UXiCE
|
|
#
|
|
# Kitsune Scientific 2021
|
|
|
|
# Get vars
|
|
hash := $(shell git rev-parse --short HEAD)
|
|
|
|
# Do everything
|
|
all: generate clean
|
|
|
|
# Generate artifacts and output binaries
|
|
generate: example_slides.md
|
|
# Copy over our source file to a temporary working one
|
|
cp example_slides.md working.md
|
|
# Replace any vars in the text
|
|
sed -i "s/&hash/$(hash)/" working.md
|
|
# Generate a doc with pandoc!
|
|
pandoc working.md -t beamer -o changeme.pdf
|
|
|
|
# Clean any artifacts up
|
|
clean: working.md
|
|
rm working.md
|