Spellcheck creates now an intermediate file with the spellcheck results and the make target intends the mis-spelled words
This commit is contained in:
parent
992edcfad1
commit
cd598e3e88
20
Makefile
20
Makefile
@ -10,6 +10,7 @@ BIBFILE=$(INPUTDIR)/literatur.bib
|
||||
METADATAFILE = $(INPUTDIR)/metadata.yaml
|
||||
OUTPUTFILE = $(OUTPUTDIR)/diplomarbeit.pdf
|
||||
LOGFILE = $(OUTPUTFILE).log
|
||||
SPELLERRORFILE = $(OUTPUTDIR)/spellcheck-results.txt
|
||||
|
||||
SHELL := /bin/bash
|
||||
|
||||
@ -30,7 +31,6 @@ help:
|
||||
|
||||
|
||||
# Helper Targets
|
||||
|
||||
build-stage:
|
||||
# Kopieren der DA-Quellen in das staging Verzeichnis
|
||||
@echo "Source directory = $(SOURCEDIR)"
|
||||
@ -70,9 +70,17 @@ compile-pdf:
|
||||
@rsync -az $(LOGFILE) $(SOURCEDIR)/
|
||||
|
||||
do-spellcheck:
|
||||
# Überprüft die staging Dateien auf Rechtschreibfehler
|
||||
@pandoc "$(STAGINGDIR)"/*.md -t plain | hunspell -d de_AT,de_AT_frami,en_US -p ignore.dict -l -t | sort | uniq
|
||||
|
||||
@echo "Performing a spellcheck on all Markdown files"
|
||||
|
||||
# Überprüft die staging Dateien auf Rechtschreibfehler
|
||||
@pandoc "$(STAGINGDIR)"/*.md -t plain | hunspell -d de_AT,de_AT_frami,en_US -p ignore.dict -l -t | sort | uniq > "$(SPELLERRORFILE)"
|
||||
|
||||
# Ausgabe der Rechtschreibfehler
|
||||
@cat "$(SPELLERRORFILE)" | sed 's/^/ /'
|
||||
|
||||
# Spell resultate zuueckkopieren
|
||||
@rsync -az $(SPELLERRORFILE) $(SOURCEDIR)/
|
||||
|
||||
remove-stage:
|
||||
#Remove the staging directory
|
||||
@ -85,5 +93,9 @@ spellcheck: build-stage do-spellcheck remove-stage
|
||||
|
||||
pdf: build-stage compile-pdf remove-stage
|
||||
|
||||
|
||||
# Special Targets
|
||||
.PHONY: help pdf clean
|
||||
|
||||
|
||||
|
||||
|
||||
|
1
example/.gitignore
vendored
1
example/.gitignore
vendored
@ -1,2 +1,3 @@
|
||||
/*.pdf
|
||||
/*.log
|
||||
/spellcheck-result.txt
|
||||
|
Loading…
Reference in New Issue
Block a user