Commit 29544e9a authored by Michael Vernier's avatar Michael Vernier

Added run commands to makefile

parent c436ed61
......@@ -16,10 +16,18 @@ IMAGENAMES_PNGSMALL_FULLPATH = $(foreach image,$(IMAGENAMES_PNGSMALL),$(IMAGESDI
all: images miscimages doc pdf
doc: images
pandoc -f markdown -t docx --data-dir=. $(TARGET).md -o $(TARGET).docx
@echo Generating "$(TARGET).docx"
@pandoc -f markdown -t docx --data-dir=. "$(TARGET).md" -o "$(TARGET).docx"
pdf: doc
word2pdf $(TARGET).docx $(TARGET).pdf
ifeq ($(OS),Windows_NT)
@echo Generating "$(TARGET).pdf"
@word2pdf "$(TARGET).docx" "$(TARGET).pdf"
else
@echo Generating "$(TARGET).pdf"
@echo Warning: PDF generated using LaTEX instead of directly from "$(TARGET).docx". Output will look different
@pandoc -s "$(TARGET).md" -o "$(TARGET).pdf"
endif
miscimages:
......@@ -32,14 +40,15 @@ images: $(IMAGENAMES_PNGSMALL_FULLPATH)
%.png: %.jpg
$(CONVERTPATH)/convert $< $@
rundoc:
@start "" "$(TARGET).docx"
runpdf:
@start "" "$(TARGET).pdf"
.SECONDARY:
clean:
rm -rf $(IMAGENAMES_PNG_FULLPATH)
rm -rf $(IMAGENAMES_PNGSMALL_FULLPATH)
# run:
# cmd -c "start $(TARGET).docx"
# runpdf:
# cmd -c "start $(TARGET).pdf"
\ No newline at end of file
rm "$(TARGET).docx" "$(TARGET).pdf"
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment