Skip to content

Commit b455b0c

Browse files
committed
Simplify and docuemnt implementation
1 parent bcbaf31 commit b455b0c

3 files changed

Lines changed: 116 additions & 425 deletions

File tree

better-code/book.toml

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,6 @@ description = "A principled and rigorous approach to software development"
88
[build]
99
build-dir = "book"
1010

11-
# Preprocessor to hide `# ` lines in Swift code blocks (like mdbook does for Rust)
12-
# Only strips lines for HTML output; swift-test backend sees the full code
13-
[preprocessor.swift-hidden]
14-
command = "python3 scripts/mdbook-swift-hidden.py"
15-
1611
[output.html]
1712
git-repository-url = "https://github.com/stlab/better-code"
1813
edit-url-template = "https://github.com/stlab/better-code/edit/main/better-code/src/{path}"
@@ -25,6 +20,9 @@ enable = true
2520
[output.html.print]
2621
enable = true
2722

23+
[output.html.code.hidelines]
24+
swift = "#"
25+
2826
# Swift code example testing backend
2927
# Tests all Swift code blocks during `mdbook build`
3028
# See scripts/mdbook-swift-test.py for implementation

scripts/mdbook-swift-hidden.py

Lines changed: 0 additions & 131 deletions
This file was deleted.

0 commit comments

Comments
 (0)