-
Notifications
You must be signed in to change notification settings - Fork 4
Description
Hello, thank you for maintaining this project!
Summary
Add an option to the build-book script to skip Katla syntax highlighting execution, allowing for faster setup and preview of mdBook documentation.
Background
I'm currently working on updating translation of this project from the original project (ref). During the translation process, both Pack compilation of the Idris project and Katla execution via the build-book script are performed. However, for translation work, I only need mdBook setup and execution to review the content.
Being able to skip Katla processing would significantly speed up the feedback loop when reviewing translation progress, as I can focus on the text content without waiting for syntax highlighting to complete.
Proposed Solution
Add support for skipping Katla execution through either:
- Environment variable (e.g.,
SKIP_KATLA=yes) - Command-line argument (e.g.,
--skip-katla)
This would allow users to quickly preview their work while still being able to enable full Katla processing for final builds.
Current Workaround
I'm currently using this temporary patch to skip Katla processing:
diff --git a/scripts/build-book b/scripts/build-book
index 965bb86..2e512f5 100755
--- a/scripts/build-book
+++ b/scripts/build-book
@@ -45,6 +45,11 @@ for paths("src").race(batch => 1, degree => Kernel.cpu-cores * 16) -> $path {
my $ttc-path = $ttc.add($path.IO.relative: "src").extension: "ttm";
given $path.IO.extension {
when "md" {
+ if %*ENV<SKIP_KATLA> {
+ say "Skip Katla for ", $rel-path;
+ copy-to-dest $rel-path;
+ next;
+ }
# Use the presense of a ttm file to detect if this markdown file was a regular
# markdown file or a literate idris document
if $ttc-path ~~ :e {