aboutsummaryrefslogtreecommitdiffhomepage
path: root/org/sdp.org
diff options
context:
space:
mode:
Diffstat (limited to 'org/sdp.org')
-rw-r--r--org/sdp.org21
1 files changed, 15 insertions, 6 deletions
diff --git a/org/sdp.org b/org/sdp.org
index 4d221bb..2d4b7b9 100644
--- a/org/sdp.org
+++ b/org/sdp.org
@@ -28,7 +28,7 @@ struct Version {
int minor;
int patch;
}
-enum ver = Version(0, 5, 0);
+enum ver = Version(0, 5, 1);
#+END_SRC
** pre loop init
@@ -60,6 +60,7 @@ import
compile_time_info, // sdp/compile_time_info.d
ao_abstract_doc_source, // sdp/ao_abstract_doc_source.d
ao_defaults, // sdp/ao_defaults.d
+ ao_header_extract, // sdp/ao_header_extract.d
ao_read_config_files, // sdp/ao_read_config_files.d
ao_read_source_files, // sdp/ao_read_source_files.d
ao_output_debugs, // sdp/ao_output_debugs.d
@@ -174,6 +175,8 @@ mixin(import("version.txt"));
#+NAME: sdp_args
#+BEGIN_SRC d
mixin SiSUheaderSkel;
+mixin SiSUheaderExtractNative;
+mixin SiSUheaderExtractSDLang;
mixin SiSUbiblio;
mixin SiSUrgxInitFlags;
mixin SiSUconfiguration;
@@ -189,6 +192,7 @@ mixin ScreenTxtColors;
#+NAME: sdp_args
#+BEGIN_SRC d
auto raw = MarkupRaw();
+auto head_native = HeaderDocMetadataAndMakeNativeToJson();
auto headsdl = HeaderExtractSDL();
auto abs = Abstraction();
auto dbg = SDPoutputDebugs();
@@ -408,14 +412,19 @@ debug(header_and_content) {
**** [#A] read doc header: metadata & make :doc:header:metadata:make:
#+NAME: sdp_each_file_do
#+BEGIN_SRC d
-/+ ↓ headers metadata & make sdlang +/
-auto header_sdlang = headsdl.headerSDLang(header);
+// Tuple!(JSONValue[string], JSONValue[string]) header_make_and_meta_tuple;
+auto header_make_and_meta_tuple = (match(header, rgx.native_header_meta_title))
+? (head_native.headerContentJSON(header))
+: (headsdl.headerSDLangToJSON(header));
+static assert(!isTypeTuple!(header_make_and_meta_tuple));
+JSONValue[string] dochead_make_json = header_make_and_meta_tuple[0];
+JSONValue[string] dochead_meta_json = header_make_and_meta_tuple[1];
#+END_SRC
**** [#A] processing: document abstraction, tuple :processing:
#+NAME: sdp_each_file_do
#+BEGIN_SRC d
-/+ ↓ porcess document, return abstraction as tuple +/
+/+ ↓ process document, return abstraction as tuple +/
auto t = abs.abstract_doc_source(sourcefile_content);
static assert(!isTypeTuple!(t));
auto doc_ao_contents = t[0]; // contents ~ endnotes ~ bookindex;
@@ -443,7 +452,7 @@ debug(checkdoc) { // checkbook & dumpdoc
}
#+END_SRC
-**** TODO process outputs :outputs:
+**** TODO process outputs :outputs:
#+NAME: sdp_each_file_do
#+BEGIN_SRC d
@@ -490,7 +499,7 @@ break;
#+END_SRC
* tangles (code structure) :tangle:
-** sdp :sdp.d:
+** sdp :sdp.d:
*** TODO src/sdp.d
#+BEGIN_SRC d :tangle ../src/sdp.d :shebang #!/usr/bin/env rdmd