-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2e8409d
commit 82c6fad
Showing
20 changed files
with
148 additions
and
155 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
BASE = | ||
SITE = _site | ||
|
||
PAGES = $(filter-out index, $(basename $(notdir $(wildcard md/*.md)))) | ||
CONTENT = $(addprefix $(SITE)/, css img index.html $(addsuffix /index.html, $(PAGES))) | ||
|
||
PANDOC = pandoc --defaults defaults.yml --metadata base=$(abspath $(BASE)) | ||
|
||
MKDIR = mkdir -p | ||
CP = cp -r | ||
RM = rm -rf | ||
|
||
all: $(SITE) $(CONTENT) | ||
|
||
$(SITE): | ||
@$(MKDIR) $@ | ||
|
||
$(SITE)/%: % | ||
@echo ">> Copying $^" | ||
@$(MKDIR) $(@D) | ||
@$(CP) $^ $@ | ||
|
||
$(SITE)/%.html $(SITE)/%/index.html: md/%.md | ||
@echo ">> Converting $^" | ||
@$(MKDIR) $(@D) | ||
@$(PANDOC) --metadata page=$* --output $@ $^ | ||
|
||
serve: | ||
@python3 -m http.server --bind 127.0.0.1 --directory $(SITE) | ||
|
||
clean: | ||
@$(RM) $(SITE) |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
standalone: true | ||
template: page.html | ||
|
||
reader: markdown-implicit_figures | ||
writer: html | ||
|
||
highlight-style: null | ||
wrap: none | ||
|
||
metadata-file: metadata.yml | ||
filters: [filters.lua] |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
local meta = {} | ||
local title = nil | ||
local stringify = pandoc.utils.stringify | ||
|
||
function get_title(h) | ||
if h.level == 1 and not title then | ||
title = h.content | ||
return h | ||
end | ||
end | ||
|
||
function change_meta(m) | ||
meta = m | ||
if m.page == "index" then | ||
m.canonical = stringify(m.baseurl) .. "/" | ||
else | ||
m.canonical = stringify(m.baseurl) .. "/" .. m.page .. "/" | ||
end | ||
m.title = title or m.site_title | ||
return m | ||
end | ||
|
||
function change_link_target(l) | ||
if meta[l.target] then | ||
l.target = stringify(meta[l.target]) | ||
elseif l.target:sub(1, 1) == "/" then | ||
l.target = meta.base .. l.target | ||
end | ||
return l | ||
end | ||
|
||
function change_image_src(i) | ||
if i.src:sub(1, 1) == "/" then | ||
i.src = meta.base .. i.src | ||
end | ||
return i | ||
end | ||
|
||
return { | ||
{ | ||
Header = get_title, | ||
Meta = change_meta | ||
}, | ||
{ | ||
Link = change_link_target, | ||
Image = change_image_src | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,3 @@ | ||
--- | ||
permalink: / | ||
--- | ||
|
||
1. [List of components](/components/) | ||
1. [Links](/links/) | ||
1. [LED blinker](/led-blinker/) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
site_title: Eclypse Z7 Notes | ||
|
||
description: Notes on the Eclypse Z7 development board | ||
|
||
baseurl: https://pavel-demin.github.io/eclypse-z7-notes | ||
|
||
source: https://github.com/pavel-demin/eclypse-z7-notes | ||
issues: https://github.com/pavel-demin/eclypse-z7-notes/issues | ||
|
||
release_image: https://github.com/pavel-demin/eclypse-z7-notes/releases/download/20230222/eclypse-z7-alpine-3.14-armv7-20230222.zip | ||
|
||
extio_file: https://www.dropbox.com/scl/fi/pl8gfjn2ay267or1zkohu/extio_red_pitaya.dll?rlkey=zhmv6qktymfeno8bdap94noq9&dl=1 |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.