Add make target to automatically regenerate html fixtures
After changing something the fixtures need to be updated to reflect the new output. This just moves those steps from my bash history to make.
This commit is contained in:
parent
8cefd9fabc
commit
9826aa2143
3 changed files with 10 additions and 1 deletions
4
Makefile
4
Makefile
|
@ -25,3 +25,7 @@ render:
|
|||
.PHONY: generate-gh-pages
|
||||
generate-gh-pages: build
|
||||
./etc/generate-gh-pages
|
||||
|
||||
.PHONY: generate-html-fixtures
|
||||
generate-html-fixtures: build
|
||||
./etc/generate-html-fixtures
|
||||
|
|
5
etc/generate-html-fixtures
Executable file
5
etc/generate-html-fixtures
Executable file
|
@ -0,0 +1,5 @@
|
|||
#!/bin/bash
|
||||
|
||||
for org_file in org/testdata/*.org; do
|
||||
./go-org $org_file html > org/testdata/$(basename $org_file .org).html
|
||||
done
|
2
main.go
2
main.go
|
@ -38,7 +38,7 @@ func main() {
|
|||
default:
|
||||
log.Fatal("Unsupported output format")
|
||||
}
|
||||
log.Println(out)
|
||||
log.Print(out)
|
||||
}
|
||||
|
||||
func highlightCodeBlock(source, lang string) string {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue