2024-05-17 08:52:18 +02:00
|
|
|
Zapiski in skripte za pretvarjanje zapiskov v različne formate in generiranje
|
|
|
|
<https://bavbavhaus.net>. Glavni repozitorij se nahaja na
|
|
|
|
<https://git.kompot.si/urosm/bavbavhaus.net>.
|
2024-03-19 01:29:25 +01:00
|
|
|
|
2024-05-17 08:52:18 +02:00
|
|
|
Recepti za generiranje <https://bavbavhaus.net> so opisani v `Makefile`:
|
|
|
|
|
|
|
|
```make
|
|
|
|
NOTES := $(shell pandoc lua pandoc/collect_notes.lua index.md)
|
|
|
|
PAGES := $(patsubst %.md,public_html/%.html,$(NOTES))
|
|
|
|
GETDEPS = $(patsubst %.md,public_html/%.html.part,$(shell pandoc lua pandoc/collect_links.lua $(1))) public_html/sitemap.html.part
|
|
|
|
|
|
|
|
.PHONY: all
|
|
|
|
all: $(PAGES)
|
|
|
|
|
|
|
|
public_html/%.html: flags = $(patsubst %,-M linkparts=%,$(filter-out $<,$^))
|
|
|
|
.SECONDEXPANSION:
|
|
|
|
public_html/%.html: %.md $$(call GETDEPS,%.md)
|
|
|
|
pandoc --data-dir pandoc -d bavbavhaus.net.yaml -M slug=$* $(flags) -o $@ $<
|
|
|
|
```
|
|
|
|
|
|
|
|
[`Makefile`](https://git.kompot.si/urosm/bavbavhaus.net/Makefile). Za delovanje potrebuje `pandoc`. Gl. tudi
|
2024-05-02 20:16:37 +02:00
|
|
|
[`pandoc/links.lua`](pandoc/links.lua) za skript, ki išče interne povezave. Gl.
|
|
|
|
tudi filtre v [`pandoc/filters`](pandoc/filters).
|
2024-03-19 01:29:25 +01:00
|
|
|
|
2024-04-12 22:33:48 +02:00
|
|
|
Navodila za uporabo:
|
2024-03-19 01:29:25 +01:00
|
|
|
|
2024-04-12 22:33:48 +02:00
|
|
|
```sh
|
2024-05-02 20:16:37 +02:00
|
|
|
sudo apt install pandoc # namestitev potrebščin (debian)
|
2024-04-12 22:33:48 +02:00
|
|
|
make
|
2024-03-19 01:29:25 +01:00
|
|
|
```
|