Skip to content

Commit bb0e975

Browse files
committed
Initial reference page generated from doc comments of prelude.cog
1 parent 22dcc82 commit bb0e975

File tree

20 files changed

+2119
-326
lines changed

20 files changed

+2119
-326
lines changed

Makefile

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,14 @@ HUGO=hugo
33

44
.PHONY: build
55
build:
6+
# NOTE: Requires gawk
7+
tree-sitter query --test scripts/doc-comments.scm prelude.cog | $(AWK) -v linkURL="https://github.com/cognate-lang/cognate/blob/master/src/" -f scripts/doc-comments.awk > content/reference/prelude.md
68
$(HUGO)
7-
make public/*.html
8-
make public/**/*.html
9+
make $(shell find public -type f -name "*.html")
910

1011
public/%.html: .FORCE
1112
@mv $@ tmp.html
13+
# Does not require gawk
1214
$(AWK) -v outfile=$@ -f scripts/process-code-blocks.awk tmp.html
1315
@rm tmp.html
1416

assets/main.css

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ body {
33
color: #333333;
44
font-size: 16px;
55
background-color: #ffffff;
6+
tab-size: 4;
67
}
78

89
*, *::before, *::after {

content/reference/_index.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
+++
2+
title = "Reference"
3+
+++

0 commit comments

Comments
 (0)