aboutsummaryrefslogtreecommitdiffhomepage
path: root/org
diff options
context:
space:
mode:
authorRalph Amissah <ralph@amissah.com>2016-10-01 14:12:13 -0400
committerRalph Amissah <ralph@amissah.com>2019-04-10 15:14:13 -0400
commitba1712e77b31704fd9ba16d14e15518e7a7dd104 (patch)
tree1a0d3233fb611b68dbf43e098a41a0d9378e9ace /org
parentupdate sdlang, start looking to using dub remote dependencies (diff)
0.7.0 using dub remote dependencies (local src related to sdlang removed)
Diffstat (limited to 'org')
-rw-r--r--org/ao_abstract_doc_source.org189
-rw-r--r--org/ao_conf_make_meta.org26
-rw-r--r--org/ao_defaults.org15
-rw-r--r--org/ao_output_debugs.org3
-rw-r--r--org/ao_read_source_files.org12
-rw-r--r--org/compile_time_info.org3
-rw-r--r--org/output.org6
-rw-r--r--org/sdp.org2
8 files changed, 173 insertions, 83 deletions
diff --git a/org/ao_abstract_doc_source.org b/org/ao_abstract_doc_source.org
index 958d2d1..5c78771 100644
--- a/org/ao_abstract_doc_source.org
+++ b/org/ao_abstract_doc_source.org
@@ -14,10 +14,10 @@
[[./sdp.org][sdp]] [[./][org/]]
-* document abstraction :abstract:process:
+* Document Abstraction :abstract:process:
Process markup document, create document abstraction.
-** 1. pre loop processing :pre:
+** _1. pre loop processing_ :pre:
*** imports :imports:
[[./ao_defaults.org][ao_defaults]]
@@ -36,10 +36,6 @@ import
#+BEGIN_SRC d
mixin ObjectSetter;
mixin InternalMarkup;
-// // mixin SiSUrgxInitFlags;
-// // mixin AssertionsOnBlocks;
-// mixin SiSUbiblio; // issue
-// mixin SiSUheader;
#+END_SRC
*** initialize :initialize:
@@ -133,9 +129,10 @@ string node_jstr_heading(
is_
);
}
-// mixin SiSUdocAbstractionFunctions;
#+END_SRC
+*** scope
+
#+name: abs_init_rest
#+BEGIN_SRC d
scope(success) {
@@ -148,12 +145,17 @@ scope(exit) {
destroy(processing);
destroy(biblio_arr_json);
}
+#+END_SRC
+
+*** init rest
+
+#+name: abs_init_rest
+#+BEGIN_SRC d
line_occur = [
"heading" : 0,
"para" : 0,
];
auto type = flags_type_init;
-mixin ScreenTxtColors;
void tell_lo(int obj_cite_number, in char[] line) {
writefln(
"* %s %s",
@@ -209,7 +211,7 @@ auto heading_match_rgx = [
];
#+END_SRC
-** 2. loop: process document body [+6] :loop:
+** _2. loop: process document body_ [+6] :loop:
*** loop scope :scope:
#+name: abs_in_loop_body_00
@@ -227,10 +229,9 @@ scope(failure) {
}
line = replaceAll(line, rgx.true_dollar, "$$$$");
// dollar represented as $$ needed to stop submatching on $
- // (substitutions using ${identifiers} must take into account (e.g. happen earlier))
+ // (substitutions using ${identifiers} must take into account (i.e. happen earlier))
debug(source) { // source lines
writeln(line);
- // writeln(scr_txt_marker["green"], line);
}
debug(srclines) {
if (!line.empty) { // source lines, not empty
@@ -252,8 +253,8 @@ if (!line.empty) {
#+END_SRC
*** [#A] separate regular markup text from code blocks [+5]
-
**** code blocks :block:code:
+
#+name: abs_in_loop_body_00_code_block
#+BEGIN_SRC d
if (type["code"] == TriState.on) {
@@ -686,8 +687,7 @@ if (contents_the_objects.length > 0) {
}
#+END_SRC
-** 3. post loop processing :post:
-
+** _3. post loop processing_ :post:
*** misc
#+name: abs_post
@@ -801,7 +801,7 @@ auto t = tuple(
return t;
#+END_SRC
-* functions :abstract:function:
+* Functions :abstract:function:
functions used in document abstraction
** set & resets :reset:
@@ -2315,16 +2315,13 @@ auto para_match(
#+name: ao_emitters
#+BEGIN_SRC d
struct OCNemitter {
-// class OCNemitter : AssertOCN {
int obj_cite_number, obj_cite_number_;
int obj_cite_number_emitter(int obj_cite_number_status_flag)
in { assert(obj_cite_number_status_flag <= 2); }
body {
- if (obj_cite_number_status_flag == 0) {
- obj_cite_number=++obj_cite_number_;
- } else {
- obj_cite_number=0;
- }
+ obj_cite_number=(obj_cite_number_status_flag == 0)
+ ? ++obj_cite_number_
+ : 0;
assert(obj_cite_number >= 0);
return obj_cite_number;
}
@@ -2338,7 +2335,6 @@ struct OCNemitter {
#+name: ao_emitters
#+BEGIN_SRC d
struct ObjAttributes {
-// class ObjAttributes : AssertObjAttributes {
string[string] obj_txt;
string para_and_blocks(string obj_txt_in)
in { }
@@ -2687,6 +2683,7 @@ struct ObjInlineMarkupMunge {
#+END_SRC
**** object inline markup :markup:inline:
+***** open
#+name: ao_emitters
#+BEGIN_SRC d
@@ -2694,6 +2691,12 @@ struct ObjInlineMarkup {
// struct ObjInlineMarkup : AssertObjInlineMarkup {
auto munge = ObjInlineMarkupMunge();
string[string] obj_txt;
+#+END_SRC
+
+***** object inline markup and anchor tags :markup:inline:
+
+#+name: ao_emitters
+#+BEGIN_SRC d
auto obj_inline_markup_and_anchor_tags(string[string] obj_, string[string][string] dochead_make_aa)
in { }
body {
@@ -2882,18 +2885,15 @@ struct ObjInlineMarkup {
#+END_SRC
**** object attrib :attributes:
-
+***** attributes structure open, public
#+name: ao_emitters
#+BEGIN_SRC d
struct ObjAttrib {
-// struct ObjAttrib : AssertObjAttrib {
-// auto sink = appender!(char[])();
auto attrib = ObjAttributes();
string[string] obj_attrib;
string obj_attributes(string obj_is_, string obj_raw, string node)
in { }
body {
- // string s = "{ \"language\": \"D\", \"rating\": 3.14, \"code\": \"42\" }";
scope(exit) {
// destroy(obj_is_);
destroy(obj_raw);
@@ -2957,9 +2957,7 @@ struct ObjAttrib {
obj_attrib["json"] = oa_j.toString();
debug(structattrib) {
if (oa_j["is"].str() == "heading") {
- // writeln(__LINE__);
writeln(obj_attrib["json"]);
- // writeln(node);
writeln(
"is: ", oa_j["is"].str(),
"; obj_cite_number: ", oa_j["obj_cite_number"].integer()
@@ -2971,6 +2969,11 @@ struct ObjAttrib {
}
invariant() {
}
+#+END_SRC
+
+***** close
+#+name: ao_emitters
+#+BEGIN_SRC d
}
#+END_SRC
@@ -2980,7 +2983,6 @@ struct ObjAttrib {
#+name: ao_emitters
#+BEGIN_SRC d
struct BookIndexNuggetHash {
-// class BookIndexNuggetHash : AssertBookIndexNuggetHash {
string main_term, sub_term, sub_term_bits;
int obj_cite_number_offset, obj_cite_number_endpoint;
string[] obj_cite_numbers;
@@ -3088,11 +3090,17 @@ struct BookIndexReportIndent {
**** book index (sort &) report section :report:section:
+***** book index struct open
#+name: ao_emitters
#+BEGIN_SRC d
struct BookIndexReportSection {
int mkn, skn;
auto rgx = Rgx();
+#+END_SRC
+
+***** bookindex write section
+#+name: ao_emitters
+#+BEGIN_SRC d
auto bookindex_write_section(
string[][string][string] bookindex_unordered_hashes
) {
@@ -3121,8 +3129,7 @@ struct BookIndexReportSection {
}
#+END_SRC
-**** book index (sort &) build section :report:section:
-
+***** book index (sort &) build section :report:section:
#+name: ao_emitters
#+BEGIN_SRC d
auto bookindex_build_section(
@@ -3223,8 +3230,7 @@ struct BookIndexReportSection {
}
#+END_SRC
-**** book index (sort &) build section :report:section:
-
+***** book index struct close
#+name: ao_emitters
#+BEGIN_SRC d
auto bookindex_build_section_(
@@ -3273,6 +3279,11 @@ struct NotesSection {
string object_notes;
long previous_count;
int mkn;
+#+END_SRC
+
+**** gather notes for endnote section struct open
+#+name: ao_emitters
+#+BEGIN_SRC d
auto rgx = Rgx();
private auto gather_notes_for_endnote_section(
ObjComposite[] contents_am,
@@ -3307,6 +3318,11 @@ struct NotesSection {
}
return object_notes;
}
+#+END_SRC
+
+**** gathered notes
+#+name: ao_emitters
+#+BEGIN_SRC d
private auto gathered_notes()
in {
}
@@ -3317,6 +3333,11 @@ struct NotesSection {
}
return endnotes_;
}
+#+END_SRC
+
+**** endnote objects
+#+name: ao_emitters
+#+BEGIN_SRC d
private auto endnote_objects(int obj_cite_number)
in {
}
@@ -3365,7 +3386,6 @@ struct NotesSection {
++mkn;
foreach (endnote; endnotes_) {
attrib="";
- attrib="";
// endnotes ~=
// set_abstract_object.contents_para(
// obj,
@@ -3382,14 +3402,25 @@ struct NotesSection {
auto t = tuple(endnotes_section, obj_cite_number);
return t;
}
+#+END_SRC
+
+**** gather notes for endnote section struct close
+#+name: ao_emitters
+#+BEGIN_SRC d
}
#+END_SRC
*** bibliography :bibliography:
+**** biblio struct open
#+name: ao_emitters
#+BEGIN_SRC d
struct Bibliography {
+#+END_SRC
+
+**** biblio
+#+name: ao_emitters
+#+BEGIN_SRC d
public JSONValue[] bibliography(ref string[] biblio_unsorted_incomplete, ref JSONValue[] bib_arr_json)
in { }
body {
@@ -3413,6 +3444,11 @@ struct Bibliography {
}
return biblio_sorted__;
}
+#+END_SRC
+
+**** biblio unsorted complete
+#+name: ao_emitters
+#+BEGIN_SRC d
final private JSONValue[] biblio_unsorted_complete(
string[] biblio_unordered,
ref JSONValue[] bib_arr_json
@@ -3442,6 +3478,11 @@ struct Bibliography {
bib_arr_json.dup;
return biblio_unsorted_array_of_json_objects;
}
+#+END_SRC
+
+**** biblio sort
+#+name: ao_emitters
+#+BEGIN_SRC d
final private JSONValue[] biblio_sort(JSONValue[] biblio_unordered) {
JSONValue[] biblio_sorted_;
biblio_sorted_ =
@@ -3458,6 +3499,11 @@ struct Bibliography {
}
return biblio_sorted_;
}
+#+END_SRC
+
+**** biblio debug
+#+name: ao_emitters
+#+BEGIN_SRC d
void biblio_debug(JSONValue[] biblio_sorted) {
debug(biblio0) {
foreach (j; biblio_sorted) {
@@ -3467,20 +3513,29 @@ struct Bibliography {
}
}
}
+#+END_SRC
+
+**** biblio struct close
+#+name: ao_emitters
+#+BEGIN_SRC d
}
#+END_SRC
*** node structure metadata :structure:metadata:node:
-**** metadata (check)
+**** metadata node struct open
#+name: ao_emitters
#+BEGIN_SRC d
struct NodeStructureMetadata {
-// class NodeStructureMetadata : AssertNodeJSON {
int lv, lv0, lv1, lv2, lv3, lv4, lv5, lv6, lv7;
int obj_cite_number;
int[string] p_; // p_ parent_
string node;
+#+END_SRC
+
+**** metadata node emitter
+#+name: ao_emitters
+#+BEGIN_SRC d
string node_emitter(
string lev_markup_number,
int obj_cite_number_,
@@ -3542,7 +3597,7 @@ struct NodeStructureMetadata {
}
#+END_SRC
-**** metadata (check)
+**** metadata emitter heading
#+name: ao_emitters
#+BEGIN_SRC d
@@ -3730,6 +3785,11 @@ struct NodeStructureMetadata {
}
invariant() {
}
+#+END_SRC
+
+**** metadata node struct close
+#+name: ao_emitters
+#+BEGIN_SRC d
}
#+END_SRC
@@ -3940,35 +4000,61 @@ auto assertions_flag_types_block_status_none_or_closed(int[string] type) {
}
#+END_SRC
-* object setter :abstract:object:
+* Object Setter :abstract:object:
set abstracted objects for downstream processing
-** structs :struct:
+** initialize structs :struct:
-#+name: ao_structs
+*** heading attribute
+#+name: ao_structs_init
#+BEGIN_SRC d
struct HeadingAttrib {
string lev = "9";
int lev_markup_number = 9;
int lev_collapsed_number = 9;
}
+#+END_SRC
+
+*** paragraph attribute
+#+name: ao_structs_init
+#+BEGIN_SRC d
struct ParaAttrib {
int indent_start = 0;
int indent_rest = 0;
bool bullet = false;
}
+#+END_SRC
+
+*** block attribute
+#+name: ao_structs_init
+#+BEGIN_SRC d
struct BlockAttrib {
string syntax = "";
}
+#+END_SRC
+
+*** comment attribute
+#+name: ao_structs_init
+#+BEGIN_SRC d
struct Comment {
// no .attrib and no .obj_cite_number
}
+#+END_SRC
+
+*** node
+#+name: ao_structs_init
+#+BEGIN_SRC d
struct Node {
int ocn = 0;
int parent_lev = 0;
int parent_ocn = 0;
string node = "";
}
+#+END_SRC
+
+*** composite object
+#+name: ao_structs_init
+#+BEGIN_SRC d
struct ObjComposite {
// size_t id;
string use = "";
@@ -3982,6 +4068,11 @@ struct ObjComposite {
BlockAttrib block_attrib;
Node node_structure;
}
+#+END_SRC
+
+*** object composite array
+#+name: ao_structs_init
+#+BEGIN_SRC d
struct ObjCompositeArr {
ObjComposite[] oca;
}
@@ -4143,12 +4234,13 @@ auto contents_block_obj_cite_number_string(
}
#+END_SRC
-* tangles (code structure) :tangle:io:file:
-** abstract doc source: :ao_abstract_doc_source.d:
+* Tangles (code structure) :tangle:io:file:
+** ao abstract doc source: :ao_abstract_doc_source.d:
#+BEGIN_SRC d :tangle ../src/sdp/ao_abstract_doc_source.d
-/+
- document abstraction
+/++
+ document abstraction:
+ abstraction of sisu markup for downstream processing
ao_abstract_doc_source.d
+/
template SiSUdocAbstraction() {
@@ -4200,16 +4292,17 @@ template SiSUdocAbstraction() {
} /+ ← closed: template SiSUdocAbstraction +/
#+END_SRC
-** ao_object_setter: :ao_object_setter.d:
+** ao object setter: :ao_object_setter.d:
#+BEGIN_SRC d :tangle ../src/sdp/ao_object_setter.d
-/+
- object setter
+/++
+ object setter:
+ setting of sisu objects for downstream processing
ao_object_setter.d
+/
template ObjectSetter() {
/+ structs +/
- <<ao_structs>>
+ <<ao_structs_init>>
/+ structs setter +/
struct ObjectAbstractSet {
import std.conv : to;
diff --git a/org/ao_conf_make_meta.org b/org/ao_conf_make_meta.org
index f8c1332..ae028f2 100644
--- a/org/ao_conf_make_meta.org
+++ b/org/ao_conf_make_meta.org
@@ -624,16 +624,16 @@ private auto headerSDLangToAA(char[] header_sdlang_src, string[string][string] c
* tangles (code structure) :tangle:
** 1. Header Hub :ao_markup_header_extract:
-the header is passed as text (lopped off top of a sisu markup file until the
-required first heading ^A~), determine whether is a native header or sdlang one
-with a regex check if whether it contains the "native header" required tag/field
-@title: then process accordingly as a "native header" or "sdlang header"
-converting the metadata and make instructions to a common json format used by
-program internally. Moved to associative array.
-
#+BEGIN_SRC d :tangle ../src/sdp/ao_conf_make_meta.d
-/+
- extract native/orig header return associative array
+/++
+ extract native/orig header return associative array<BR>
+
+ the header is passed as text (lopped off top of a sisu markup file until the
+ required first heading ^A~), determine whether is a native header or sdlang one
+ with a regex check if whether it contains the "native header" required tag/field
+ @title: then process accordingly as a "native header" or "sdlang header"
+ converting the metadata and make instructions to a common json format used by
+ program internally. Moved to associative array.
+/
template SiSUheaderExtractHub() {
private import
@@ -660,7 +660,8 @@ template SiSUheaderExtractHub() {
** 2a. Header Native :ao_markup_header_extract_native:
#+BEGIN_SRC d :tangle ../src/sdp/ao_conf_make_meta_native.d
-/+
+/++
+ native headers using<br>@title:<BR>:subtitle:<BR>type tags<BR>
extract native/orig header return associative array
+/
template SiSUheaderExtractNative() {
@@ -686,8 +687,9 @@ template SiSUheaderExtractNative() {
** 2b. Header SDLang :ao_markup_header_extract_sdlang:
#+BEGIN_SRC d :tangle ../src/sdp/ao_conf_make_meta_sdlang.d
-/+
- extract sdl header return sdl
+/++
+ sdlang headers<BR>
+ extract sdlang header return sdlang
+/
template SiSUheaderExtractSDLang() {
private import
diff --git a/org/ao_defaults.org b/org/ao_defaults.org
index b4ea917..c01ea41 100644
--- a/org/ao_defaults.org
+++ b/org/ao_defaults.org
@@ -893,9 +893,8 @@ string[string] scr_txt_marker = [
#+name: tangle_ao_defaults
#+BEGIN_SRC d :tangle ../src/sdp/ao_defaults.d
-/+
- defaults
- ao_defaults.d
+/++
+ default settings
+/
<<ao_defaults_templates>>
#+END_SRC
@@ -904,9 +903,8 @@ string[string] scr_txt_marker = [
#+name: tangle_ao_rgx
#+BEGIN_SRC d :tangle ../src/sdp/ao_rgx.d
-/+
- regex
- ao_rgx.d
+/++
+ regex: regular expressions used in sisu document parser
+/
template RgxInit() {
struct Rgx {
@@ -918,9 +916,8 @@ template RgxInit() {
** ansi_colors: :ao_ansi_colors.d:
#+BEGIN_SRC d :tangle ../src/sdp/ao_ansi_colors.d
-/+
- utils
- ao_util.d
+/++
+ ansi colors, depreciate use
+/
template ScreenTxtColors() {
<<ao_ansi_colors>>
diff --git a/org/ao_output_debugs.org b/org/ao_output_debugs.org
index 8eccb73..4f17969 100644
--- a/org/ao_output_debugs.org
+++ b/org/ao_output_debugs.org
@@ -616,9 +616,8 @@ debug(checkdoc) {
#+name: tangle_ao_output_debugs
#+BEGIN_SRC d :tangle ../src/sdp/ao_output_debugs.d
-/+
+/++
output debugs
- ao_output_debugs.d
+/
template SiSUoutputDebugs() {
<<book_index_sorted_report>>
diff --git a/org/ao_read_source_files.org b/org/ao_read_source_files.org
index 37929a7..11647fb 100644
--- a/org/ao_read_source_files.org
+++ b/org/ao_read_source_files.org
@@ -439,12 +439,11 @@ return contents;
** ao_markup_source_raw.d: :ao_markup_source_raw:
#+BEGIN_SRC d :tangle ../src/sdp/ao_read_source_files.d
-/+
- ao_read_source_files.d
- - open markup files
+/++
+ module ao_read_source_files;<BR>
+ - open markup files<BR>
- if master file scan for addional files to import/insert
+/
-// module ao_read_source_files;
template SiSUmarkupRaw() {
private import
std.exception,
@@ -520,9 +519,10 @@ WORK AREA
*** config files, read in
#+BEGIN_SRC d :tangle ../src/sdp/ao_read_config_files.d
-/+
+/++
+ read configuration files<BR>
+ - read config files<BR>
ao_config_files.d
- - read config files
+/
template SiSUconfigIn() {
private import
diff --git a/org/compile_time_info.org b/org/compile_time_info.org
index 9fb5830..2dc5eba 100644
--- a/org/compile_time_info.org
+++ b/org/compile_time_info.org
@@ -95,9 +95,8 @@ version(D_LP64) {
** compile_time_info: :compile_time_info.d:
#+begin_src d :tangle ../src/sdp/compile_time_info.d
-/+
+/++
compile_time_info
- compile_time_info.d
+/
template CompileTimeInfo() {
<<sdp_compile_time_info>>
diff --git a/org/output.org b/org/output.org
index 1e1a346..1dd19a8 100644
--- a/org/output.org
+++ b/org/output.org
@@ -1539,9 +1539,9 @@ auto css_write() {
**** hub
#+BEGIN_SRC d :tangle ../src/sdp/output_hub.d
-/+
- output_hub.d
- output_html.d
+/++
+ output hub<BR>
+ check & generate output types requested
+/
template SiSUoutputHub() {
struct SDPoutput {
diff --git a/org/sdp.org b/org/sdp.org
index 60b37c3..954a1ef 100644
--- a/org/sdp.org
+++ b/org/sdp.org
@@ -24,7 +24,7 @@ struct Version {
int minor;
int patch;
}
-enum ver = Version(0, 6, 8);
+enum ver = Version(0, 7, 0);
#+END_SRC
* sdp.d sisu document parser :sdp.d: