From ed71ef0ac032456c882bea44b04c02863cb90a46 Mon Sep 17 00:00:00 2001 From: Ralph Amissah Date: Sat, 25 Jan 2020 13:34:47 -0500 Subject: code ctRegex calls, tidying --- org/default_misc.org | 2 +- org/default_paths.org | 52 ++++++++++++++++++------------------- org/default_regex.org | 9 +++---- org/in_source_files.org | 18 ++++++------- org/meta_conf_make_meta.org | 16 ++++++------ org/meta_debugs.org | 4 +-- org/metaverse.org | 62 ++++++++++++++++++++++---------------------- org/out_harvest_metadata.org | 2 -- org/out_latex.org | 4 +-- org/out_odt.org | 10 +++---- org/out_sqlite.org | 6 ++--- org/out_src_pod.org | 4 +-- org/out_xmls.org | 26 +++++++++---------- org/output_hub.org | 8 +++--- org/spine.org | 8 +++--- 15 files changed, 114 insertions(+), 117 deletions(-) (limited to 'org') diff --git a/org/default_misc.org b/org/default_misc.org index d0328f9..88e724d 100644 --- a/org/default_misc.org +++ b/org/default_misc.org @@ -37,7 +37,7 @@ module doc_reform.meta.defaults; #+NAME: meta_defaults_template_init_flags #+BEGIN_SRC d -template spineRgxInitFlags() { +template spineRgxDocStructFlags() { /+ regex flags +/ @safe static int[string] flags_type_init() { int[string] flags_type_init = [ diff --git a/org/default_paths.org b/org/default_paths.org index 1ab7a0a..acfdebf 100644 --- a/org/default_paths.org +++ b/org/default_paths.org @@ -45,8 +45,8 @@ import #+NAME: template_paths_src #+BEGIN_SRC d template PodManifest() { - mixin spineRgxInit; - static auto rgx = Rgx(); + mixin spineRgxIn; + static auto rgx = RgxI(); @safe auto PodManifest(O)( O _opt_actions, string _pth="" @@ -120,9 +120,9 @@ pod #+NAME: template_paths_src #+BEGIN_SRC d template PathMatters() { - mixin spineRgxInit; + mixin spineRgxIn; mixin InternalMarkup; - static auto rgx = Rgx(); + static auto rgx = RgxI(); static auto mkup = InlineMarkup(); @safe auto PathMatters(O,E)( O _opt_actions, @@ -468,8 +468,8 @@ template PathMatters() { #+NAME: template_paths_src #+BEGIN_SRC d template ConfigFilePaths() { - mixin spineRgxInit; - static auto rgx = Rgx(); + mixin spineRgxIn; + static auto rgx = RgxI(); @safe auto ConfigFilePaths(M,E)( M _manifested, E _env, @@ -642,8 +642,8 @@ filelist for processing [things to ponder] #+NAME: template_paths_src #+BEGIN_SRC d template spinePathsSRC() { - mixin spineRgxInit; - static auto rgx = Rgx(); + mixin spineRgxIn; + static auto rgx = RgxI(); @safe auto spinePathsSRC(D,Fn)( D _pwd, Fn _fn_src_and_path, @@ -697,8 +697,8 @@ template spinePathsSRC() { #+NAME: template_paths_pods #+BEGIN_SRC d template spinePathsPods() { - mixin spineRgxInit; - static auto rgx = Rgx(); + mixin spineRgxIn; + static auto rgx = RgxI(); string _suffix = ".zip"; auto spinePathsPods(M)(M doc_matters) { string _base_dir_pod = (doc_matters.output_path.length > 0) @@ -1078,8 +1078,8 @@ template spineOutPathsFnPd() { #+NAME: template_paths_html #+BEGIN_SRC d template spineDocRootTreeHTML() { - mixin spineRgxInit; - static auto rgx = Rgx(); + mixin spineRgxIn; + static auto rgx = RgxI(); auto spineDocRootTreeHTML()(string lng) { auto lng_pth = spineOutPaths!()("", lng); string base_dir = "html"; @@ -1144,8 +1144,8 @@ template spineDocRootTreeHTML() { #+NAME: template_paths_html #+BEGIN_SRC d template spinePathsHTML() { - mixin spineRgxInit; - static auto rgx = Rgx(); + mixin spineRgxIn; + static auto rgx = RgxI(); auto spinePathsHTML()( string output_path_root, string lng, @@ -1211,8 +1211,8 @@ template spinePathsHTML() { #+BEGIN_SRC d template spineUrlsHTML() { import std.format; - mixin spineRgxInit; - static auto rgx = Rgx(); + mixin spineRgxIn; + static auto rgx = RgxI(); auto spineUrlsHTML()( string url_doc_root, string lng, @@ -1318,8 +1318,8 @@ template spineUrlsHTML() { #+NAME: template_paths_epub #+BEGIN_SRC d template spinePathsEPUB() { - mixin spineRgxInit; - static auto rgx = Rgx(); + mixin spineRgxIn; + static auto rgx = RgxI(); auto spinePathsEPUB()( string output_pth_root, string lng, @@ -1429,8 +1429,8 @@ template spinePathsEPUB() { #+NAME: template_paths_odf #+BEGIN_SRC d template spinePathsODT() { - mixin spineRgxInit; - static auto rgx = Rgx(); + mixin spineRgxIn; + static auto rgx = RgxI(); auto spinePathsODT(M)( M doc_matters, ) { @@ -1499,8 +1499,8 @@ template spinePathsODT() { #+NAME: template_paths_latex #+BEGIN_SRC d template spinePathsLaTeX() { - mixin spineRgxInit; - static auto rgx = Rgx(); + mixin spineRgxIn; + static auto rgx = RgxI(); auto spinePathsLaTeX(M)( M doc_matters, ) { @@ -1535,8 +1535,8 @@ template spinePathsLaTeX() { #+NAME: template_paths_sqlite #+BEGIN_SRC d template spinePathsSQLiteDiscrete() { - mixin spineRgxInit; - static auto rgx = Rgx(); + mixin spineRgxIn; + static auto rgx = RgxI(); auto spinePathsSQLiteDiscrete()( string output_pth_root, string lng, @@ -1567,8 +1567,8 @@ template spinePathsSQLiteDiscrete() { #+NAME: template_paths_sqlite #+BEGIN_SRC d template spinePathsSQLite() { - mixin spineRgxInit; - static auto rgx = Rgx(); + mixin spineRgxIn; + static auto rgx = RgxI(); auto spinePathsSQLite(DbN, Po)( DbN db_name, Po output_pth_root, diff --git a/org/default_regex.org b/org/default_regex.org index 02f3e3a..b406741 100644 --- a/org/default_regex.org +++ b/org/default_regex.org @@ -35,8 +35,8 @@ http://dlang.org/phobos/std_regex.html regex: regular expressions used in sisu document parser +/ module doc_reform.meta.rgx; -static template spineRgxInit() { - static struct Rgx { +static template spineRgxIn() { + static struct RgxI { <> <> } @@ -366,9 +366,8 @@ http://dlang.org/phobos/std_regex.html regex: regular expressions used in sisu document parser +/ module doc_reform.io_out.rgx; -static template spineOutputRgxInit() { - import doc_reform.io_out.defaults; - static struct Rgx { +static template spineRgxOut() { + static struct RgxO { <> <> } diff --git a/org/in_source_files.org b/org/in_source_files.org index 720a47e..5db71b3 100644 --- a/org/in_source_files.org +++ b/org/in_source_files.org @@ -57,8 +57,8 @@ import #+BEGIN_SRC d template readConfigSite() { @system final auto readConfigSite(C)(C _conf_file_details) { - mixin spineRgxInit; - static auto rgx = Rgx(); + mixin spineRgxIn; + static auto rgx = RgxI(); string conf_filename = "NONE"; string config_file_str; string default_config_file_str = format(q"┃ @@ -165,8 +165,8 @@ static template readConfigDoc() { <>, doc_reform.meta.rgx; @system final auto readConfigDoc(M,E)(M _manifested, E _env) { - mixin spineRgxInit; - static auto rgx = Rgx(); + mixin spineRgxIn; + static auto rgx = RgxI(); string config_file_str; string conf_filename = "NONE"; auto _conf_file_details = ConfigFilePaths!()(_manifested, _env); @@ -256,8 +256,8 @@ template spineRawMarkupContent() { <>, <>, doc_reform.meta.rgx; - mixin spineRgxInit; - static auto rgx = Rgx(); + mixin spineRgxIn; + static auto rgx = RgxI(); string[] _images=[]; @safe string[] _extract_images(S)(S content_block) { string[] images_; @@ -345,7 +345,7 @@ template spineRawMarkupContent() { char[][] markup_sourcefile_insert_content, string fn_src ) { - mixin spineRgxInitFlags; + mixin spineRgxDocStructFlags; <> foreach (line; markup_sourcefile_insert_content) { <> @@ -358,7 +358,7 @@ template spineRawMarkupContent() { string fn_src ) { import std.algorithm; - mixin spineRgxInitFlags; + mixin spineRgxDocStructFlags; <> foreach (line; sourcefile_body_content) { <> @@ -441,7 +441,7 @@ split is on first match of level A~ (which is required) #+NAME: meta_markup_source_raw_read_in_file #+BEGIN_SRC d @safe string markupSourceReadIn(in string fn_src) { - static auto rgx = Rgx(); + static auto rgx = RgxI(); enforce( fn_src.match(rgx.src_pth_sst_or_ssm), "not a dr markup filename: «" ~ diff --git a/org/meta_conf_make_meta.org b/org/meta_conf_make_meta.org index 9468614..ce43d84 100644 --- a/org/meta_conf_make_meta.org +++ b/org/meta_conf_make_meta.org @@ -65,8 +65,8 @@ import import doc_reform.meta.defaults, doc_reform.meta.rgx; -mixin spineRgxInit; -static auto rgx = Rgx(); +mixin spineRgxIn; +static auto rgx = RgxI(); mixin InternalMarkup; static auto mkup = InlineMarkup(); #+END_SRC @@ -362,8 +362,8 @@ template contentYAMLtoSpineStruct() { M _manifested, string _identifier ) { - mixin spineRgxInit; - static auto rgx = Rgx(); + mixin spineRgxIn; + static auto rgx = RgxI(); confCompositeMakeBuild _mk; <> <> @@ -1174,8 +1174,8 @@ static template contentJSONtoSpineStruct() { doc_reform.meta.rgx; ConfComposite _struct_composite; @safe auto contentJSONtoSpineStruct(C,J,M)(C _struct_composite, J _json, M _manifested, string _identifier) { - mixin spineRgxInit; - static auto rgx = Rgx(); + mixin spineRgxIn; + static auto rgx = RgxI(); debug (json) { writeln(">> --------------------------- >>"); foreach (tag0; _json.object.byKeyValue) { @@ -1862,9 +1862,9 @@ template docHeaderMakeAndMetaTupYamlExtractAndConvertToStruct() { doc_reform.meta.conf_make_meta_structs, doc_reform.meta.conf_make_meta_json, doc_reform.meta.rgx; - mixin spineRgxInit; + mixin spineRgxIn; mixin contentJSONtoSpineStruct; - static auto rgx = Rgx(); + static auto rgx = RgxI(); @system auto docHeaderMakeAndMetaTupYamlExtractAndConvertToStruct(CCm,Src,M)( Src header_src, CCm _make_and_meta_struct, diff --git a/org/meta_debugs.org b/org/meta_debugs.org index 71c3d55..b94d5b2 100644 --- a/org/meta_debugs.org +++ b/org/meta_debugs.org @@ -29,7 +29,7 @@ template spineDebugs() { const S contents, T doc_matters, ) { - mixin spineRgxInit; + mixin spineRgxIn; mixin InternalMarkup; <> <> @@ -71,7 +71,7 @@ import #+NAME: initialize #+BEGIN_SRC d -static auto rgx = Rgx(); +static auto rgx = RgxI(); auto markup = InlineMarkup(); string key; #+END_SRC diff --git a/org/metaverse.org b/org/metaverse.org index c1d4442..d6a21bd 100644 --- a/org/metaverse.org +++ b/org/metaverse.org @@ -44,7 +44,7 @@ template docAbstraction() { Mf manifested, bool _new_doc ) { - static auto rgx = Rgx(); + static auto rgx = RgxI(); /+ ↓ abstraction init +/ <> /+ abstraction init ↑ +/ @@ -162,7 +162,7 @@ import #+BEGIN_SRC d mixin ObjectSetter; mixin InternalMarkup; -mixin spineRgxInit; +mixin spineRgxIn; #+END_SRC *** initialize :initialize: @@ -429,7 +429,7 @@ enum DomTags { none, open, close, close_and_open, open_still, } return object_citation_number.ocn_emitter(ocn_status_flag); } @safe static auto inline_markup_faces(L)(L line) { - static auto rgx = Rgx(); + static auto rgx = RgxI(); static auto mkup = InlineMarkup(); line = replaceAll!(m => mkup.quote_o ~ m[1] ~ mkup.quote_c)(line, rgx.within_quotes); line = replaceAll!(m => mkup.mono ~ mkup.ff_o ~ m["text"] ~ mkup.ff_c ~ mkup.mono)(line, rgx.inline_mark_mono); @@ -440,7 +440,7 @@ enum DomTags { none, open, close, close_and_open, open_still, } return line; } @safe static string links_and_images()(string obj_txt) { - static auto rgx = Rgx(); + static auto rgx = RgxI(); static auto mkup = InlineMarkup(); if (obj_txt.match(rgx.smid_inline_url_generic)) { if ( @@ -497,7 +497,7 @@ enum sObj { content, anchor_tag, notes_reg, notes_star, links, image_no_dimensio string[string] tag_in_seg, string[string][string] tag_assoc ) { - static auto rgx = Rgx(); + static auto rgx = RgxI(); if (auto m = an_object["substantive"].match(rgx.inline_link_anchor)) { if (m.captures[1] !in tag_assoc) { tag_assoc[(m.captures[1])]["seg_lv4"] = tag_in_seg["seg_lv4"]; @@ -535,7 +535,7 @@ scope(exit) { #+NAME: abs_init_rest #+BEGIN_SRC d -mixin spineRgxInitFlags; +mixin spineRgxDocStructFlags; mixin spineNode; auto node_para_int_ = node_metadata_para_int; auto node_para_str_ = node_metadata_para_str; @@ -3146,7 +3146,7 @@ functions used in document abstraction char[] line, int[string] obj_type_status, ) { - static auto rgx = Rgx(); + static auto rgx = RgxI(); if (!(line.empty) && (obj_type_status["ocn_status_off_for_multiple_objects"] == OCN_off_block_status.off) ) { @@ -3274,7 +3274,7 @@ functions used in document abstraction #+NAME: abs_functions_block #+BEGIN_SRC d - static auto rgx = Rgx(); + static auto rgx = RgxI(); #+END_SRC ******* code @@ -3551,7 +3551,7 @@ functions used in document abstraction return ref string[string] an_object, return ref int[string] obj_type_status ) { - static auto rgx = Rgx(); + static auto rgx = RgxI(); if (obj_type_status["curly_code"] == TriState.on) { if (line.matchFirst(rgx.block_curly_code_close)) { debug(codecurly) { // code (curly) close @@ -3656,7 +3656,7 @@ final string biblio_tag_map_()(string abr) { ) { mixin spineBiblio; auto jsn = BibJsnStr(); - static auto rgx = Rgx(); + static auto rgx = RgxI(); if (line.matchFirst(rgx.heading_biblio) && obj_type_status["para"] != State.on && obj_type_status["group"] != State.on @@ -3787,7 +3787,7 @@ final string biblio_tag_map_()(string abr) { string[string] an_object, return ref int[string] obj_type_status ) { - static auto rgx = Rgx(); + static auto rgx = RgxI(); if (obj_type_status["curly_quote"] == TriState.on) { if (line.matchFirst(rgx.block_curly_quote_close)) { debug(quote) { // quote (curly) close @@ -3835,7 +3835,7 @@ final string biblio_tag_map_()(string abr) { string[string] an_object, return ref int[string] obj_type_status ) { - static auto rgx = Rgx(); + static auto rgx = RgxI(); if (obj_type_status["curly_group"] == State.on) { if (line.matchFirst(rgx.block_curly_group_close)) { debug(group) { @@ -3884,7 +3884,7 @@ final string biblio_tag_map_()(string abr) { string[string] an_object, return ref int[string] obj_type_status ) { - static auto rgx = Rgx(); + static auto rgx = RgxI(); if (obj_type_status["curly_block"] == TriState.on) { if (line.matchFirst(rgx.block_curly_block_close)) { debug(block) { // block (curly) close @@ -3935,7 +3935,7 @@ why extra object stuff only in poem/verse? CMM conf_make_meta, string[string] tag_in_seg, ) { - static auto rgx = Rgx(); + static auto rgx = RgxI(); if (obj_type_status["curly_poem"] == TriState.on) { if (line.matchFirst(rgx.block_curly_poem_close)) { if (an_object_key in an_object @@ -4196,7 +4196,7 @@ you need: return ref int[string] obj_type_status, return ref CMM conf_make_meta, ) { - static auto rgx = Rgx(); + static auto rgx = RgxI(); if (obj_type_status["curly_table"] == TriState.on) { if (line.matchFirst(rgx.block_curly_table_close)) { debug(table) { // table (curly) close @@ -4333,7 +4333,7 @@ process and use an_object["table_head"] (then empty it) "code block status: closed" ); assertions_flag_types_block_status_none_or_closed(obj_type_status); - static auto rgx = Rgx(); + static auto rgx = RgxI(); #+END_SRC ****** make: quote block @@ -4674,7 +4674,7 @@ process and use an_object["table_head"] (then empty it) return ref int[string] obj_type_status, B opt_action, ) { - static auto rgx = Rgx(); + static auto rgx = RgxI(); if (auto m = line.match(rgx.book_index)) { /+ match book_index +/ debug(bookindexmatch) { writefln( @@ -4731,7 +4731,7 @@ process and use an_object["table_head"] (then empty it) return ref Regex!(char)[string] heading_match_rgx, return ref int[string] obj_type_status ) { - static auto rgx = Rgx(); + static auto rgx = RgxI(); if ((_make_unmarked_headings.length > 2) && (obj_type_status["make_headings"] == State.off)) { /+ headings found +/ debug(headingsfound) { @@ -4883,7 +4883,7 @@ process and use an_object["table_head"] (then empty it) return ref int[string] obj_type_status, return ref CMM conf_make_meta, ) { - static auto rgx = Rgx(); + static auto rgx = RgxI(); if (auto m = line.match(rgx.heading)) { /+ heading match +/ ++line_occur["heading"]; obj_type_status["heading"] = State.on; @@ -5041,7 +5041,7 @@ process and use an_object["table_head"] (then empty it) return ref int[string] obj_type_status, return ref int[string] line_occur, ) { - static auto rgx = Rgx(); + static auto rgx = RgxI(); if (line_occur["para"] == State.off) { line = font_faces_line(line); /+ para matches +/ @@ -5094,7 +5094,7 @@ process and use an_object["table_head"] (then empty it) @safe char[] font_faces_line()( char[] textline, ) { - static auto rgx = Rgx(); + static auto rgx = RgxI(); static auto mkup = InlineMarkup(); if (textline.match(rgx.inline_faces_line)) { textline = textline @@ -5132,7 +5132,7 @@ process and use an_object["table_head"] (then empty it) return ref ObjGenericComposite table_object, H table_head, ) { - static auto rgx = Rgx(); + static auto rgx = RgxI(); table_object.metainfo.is_of_part = "body"; table_object.metainfo.is_of_section = "body"; table_object.metainfo.is_of_type = "block"; @@ -5163,7 +5163,7 @@ process and use an_object["table_head"] (then empty it) return ref ObjGenericComposite table_object, return ref T table_array, ) { - static auto rgx = Rgx(); + static auto rgx = RgxI(); static auto mng = InlineMarkup(); string _table_substantive; ulong col_num; @@ -5293,7 +5293,7 @@ process and use an_object["table_head"] (then empty it) return ref ObjGenericComposite table_object, return ref T table_substantive, ) { - static auto rgx = Rgx(); + static auto rgx = RgxI(); static auto munge = ObjInlineMarkupMunge(); string[] _table_rows = (table_substantive).split(rgx.table_row_delimiter); string[] _table_cols; @@ -5315,7 +5315,7 @@ process and use an_object["table_head"] (then empty it) return ref ObjGenericComposite table_object, return ref T table_substantive, ) { - static auto rgx = Rgx(); + static auto rgx = RgxI(); static auto munge = ObjInlineMarkupMunge(); string[] _table_rows = (table_substantive).split(rgx.table_row_delimiter_special); string[] _table_cols; @@ -5396,7 +5396,7 @@ process and use an_object["table_head"] (then empty it) int n_foot, n_foot_reg, n_foot_sp_asterisk, n_foot_sp_plus; string asterisks_, plus_; string obj_txt_out, tail, note; - static auto rgx = Rgx(); + static auto rgx = RgxI(); static auto mkup = InlineMarkup(); int stage_reset_note_numbers = true; private auto initialize_note_numbers() { @@ -5762,7 +5762,7 @@ process and use an_object["table_head"] (then empty it) #+NAME: meta_emitters_obj_inline_markup #+BEGIN_SRC d static struct ObjInlineMarkup { - static auto rgx = Rgx(); + static auto rgx = RgxI(); static auto munge = ObjInlineMarkupMunge(); string[string] obj_txt; static string anchor_tag = ""; @@ -6480,7 +6480,7 @@ struct BookIndexNuggetHash { ); } } - static auto rgx = Rgx(); + static auto rgx = RgxI(); if (!bookindex_section.empty) { auto bi_main_terms_split_arr = bookindex_section.split(rgx.bi_main_terms_split); @@ -6571,7 +6571,7 @@ struct BookIndexReportIndent { #+BEGIN_SRC d struct BookIndexReportSection { int mkn, skn; - static auto rgx = Rgx(); + static auto rgx = RgxI(); static auto munge = ObjInlineMarkupMunge(); #+END_SRC @@ -6788,7 +6788,7 @@ struct NotesSection { string[string] object_notes; int previous_count; int mkn; - static auto rgx = Rgx(); + static auto rgx = RgxI(); #+END_SRC ***** { gather notes for endnote section struct open @@ -7142,7 +7142,7 @@ struct NodeStructureMetadata { int lv, lv0, lv1, lv2, lv3, lv4, lv5, lv6, lv7; int obj_cite_digit; int[string] p_; // p_ parent_ - static auto rgx = Rgx(); + static auto rgx = RgxI(); #+END_SRC ****** node metadata emitter diff --git a/org/out_harvest_metadata.org b/org/out_harvest_metadata.org index ba62bd1..c130f9f 100644 --- a/org/out_harvest_metadata.org +++ b/org/out_harvest_metadata.org @@ -124,7 +124,6 @@ module doc_reform.meta.metadoc_harvests_topics; doc_reform.meta.rgx; mixin spineHarvest; mixin InternalMarkup; - mixin spineRgxInit; template spineMetaDocHarvestsTopics() { static auto mkup = InlineMarkup(); void spineMetaDocHarvestsTopics(H,M,O)( @@ -456,7 +455,6 @@ module doc_reform.meta.metadoc_harvests_authors; doc_reform.meta.rgx; mixin spineHarvest; mixin InternalMarkup; - mixin spineRgxInit; template spineMetaDocHarvestsAuthors() { static auto mkup = InlineMarkup(); void spineMetaDocHarvestsAuthors(H,M,O)( diff --git a/org/out_latex.org b/org/out_latex.org index 9424078..38defe1 100644 --- a/org/out_latex.org +++ b/org/out_latex.org @@ -25,8 +25,8 @@ module doc_reform.io_out.latex; template outputLaTeX() { <> mixin InternalMarkup; // watch - mixin spineOutputRgxInit; - static auto rgx = Rgx(); + mixin spineRgxOut; + static auto rgx = RgxO(); mixin spineLanguageCodes; auto lang = Lang(); <> diff --git a/org/out_odt.org b/org/out_odt.org index c2ec6e0..b4a8acd 100644 --- a/org/out_odt.org +++ b/org/out_odt.org @@ -49,17 +49,17 @@ module doc_reform.io_out.odt; template formatODT() { <> - mixin spineOutputRgxInit; + mixin spineRgxOut; struct formatODT { - static auto rgx = Rgx(); + static auto rgx = RgxO(); <> } } template outputODT() { <> mixin InternalMarkup; - mixin spineOutputRgxInit; - static auto rgx = Rgx(); + mixin spineRgxOut; + static auto rgx = RgxO(); // mixin outputXmlODT; <> <> @@ -149,7 +149,7 @@ template outputODT() { #+NAME: odt_format_objects #+BEGIN_SRC d @safe string _footnotes()(string _txt) { - static auto rgx = Rgx(); + static auto rgx = RgxO(); _txt = _txt.replaceAll( rgx.inline_notes_al_regular_number_note, format(q"┃ diff --git a/org/out_sqlite.org b/org/out_sqlite.org index 14e3ab0..3bd18e5 100644 --- a/org/out_sqlite.org +++ b/org/out_sqlite.org @@ -27,9 +27,9 @@ module doc_reform.io_out.sqlite; <> import d2sqlite3; import std.typecons : Nullable; -mixin spineOutputRgxInit; +mixin spineRgxOut; mixin InternalMarkup; -static auto rgx = Rgx(); +static auto rgx = RgxO(); static auto mkup = InlineMarkup(); long _metadata_tid_lastrowid; template SQLiteHubBuildTablesAndPopulate() { @@ -141,7 +141,7 @@ template SQLiteFormatAndLoadObject() { auto SQLiteFormatAndLoadObject(M)( M doc_matters, ) { - mixin spineOutputRgxInit; + mixin spineRgxOut; struct sqlite_format_and_load_objects { <> <> diff --git a/org/out_src_pod.org b/org/out_src_pod.org index 7727f36..a9f4d7b 100644 --- a/org/out_src_pod.org +++ b/org/out_src_pod.org @@ -62,14 +62,14 @@ import debug(asserts) { // static assert(is(typeof(doc_matters) == tuple)); } -mixin spineOutputRgxInit; +mixin spineRgxOut; string pwd = doc_matters.env.pwd; auto src_path_info = doc_matters.src_path_info; auto pth_dr_doc_src = doc_matters.src_path_info; auto pths_pod = spinePathsPods!()(doc_matters); mixin spineLanguageCodes; auto lang = Lang(); -static auto rgx = Rgx(); +static auto rgx = RgxO(); assert (doc_matters.src.filename.match(rgx.src_fn)); #+END_SRC diff --git a/org/out_xmls.org b/org/out_xmls.org index b5107f2..9f51e84 100644 --- a/org/out_xmls.org +++ b/org/out_xmls.org @@ -25,9 +25,9 @@ module doc_reform.io_out.xmls; template outputXHTMLs() { <> - mixin spineOutputRgxInit; + mixin spineRgxOut; struct outputXHTMLs { - static auto rgx = Rgx(); + static auto rgx = RgxO(); <> <> } @@ -1526,9 +1526,9 @@ template outputHTML() { const D doc_abstraction, M doc_matters, ) { - mixin spineOutputRgxInit; + mixin spineRgxOut; auto xhtml_format = outputXHTMLs(); - static auto rgx = Rgx(); + static auto rgx = RgxO(); string[] doc_html; string[] doc; string suffix = ".html"; @@ -1762,8 +1762,8 @@ template outputHTML() { const D doc_abstraction, M doc_matters, ) { - mixin spineOutputRgxInit; - static auto rgx = Rgx(); + mixin spineRgxOut; + static auto rgx = RgxO(); auto xhtml_format = outputXHTMLs(); string[][string] doc_html; string[][string] doc_html_endnotes; @@ -2067,8 +2067,8 @@ template outputHTML() { debug(asserts) { static assert(is(typeof(doc_html) == string[][string])); } - mixin spineOutputRgxInit; - static auto rgx = Rgx(); + mixin spineRgxOut; + static auto rgx = RgxO(); auto pth_html = spinePathsHTML!()(doc_matters.output_path, doc_matters.src.language); auto xhtml_format = outputXHTMLs(); auto m = doc_matters.src.filename.matchFirst(rgx.src_fn); @@ -2333,7 +2333,7 @@ xmlns="urn:oasis:names:tc:opendocument:xmlns:container"> @safe string epub3_oebps_toc_nav_xhtml(D,I)(D doc_abstraction, I doc_matters) { enum DomTags { none, open, close, close_and_open, open_still, } auto markup = InlineMarkup(); - static auto rgx = Rgx(); + static auto rgx = RgxO(); string toc =format(" @@ -2422,7 +2422,7 @@ xmlns="urn:oasis:names:tc:opendocument:xmlns:container"> int counter = 0; string _uuid = "18275d951861c77f78acd05672c9906924c59f18a2e0ba06dad95959693e9bd8"; // TODO shared elsewhere auto markup = InlineMarkup(); - static auto rgx = Rgx(); + static auto rgx = RgxO(); enum DomTags { none, open, close, close_and_open, open_still, } string toc = format(q"┃ @@ -2518,9 +2518,9 @@ xmlns="urn:oasis:names:tc:opendocument:xmlns:container"> const D doc_abstraction, I doc_matters, ) { - mixin spineOutputRgxInit; + mixin spineRgxOut; auto xhtml_format = outputXHTMLs(); - static auto rgx = Rgx(); + static auto rgx = RgxO(); string[] doc; string segment_filename; string[] top_level_headings = ["","","",""]; @@ -2883,7 +2883,7 @@ xmlns="urn:oasis:names:tc:opendocument:xmlns:container"> static assert(is(typeof(epub_write.oebps_toc_ncx) == string)); static assert(is(typeof(epub_write.oebps_content_opf) == string)); } - static auto rgx = Rgx(); + static auto rgx = RgxO(); auto pth_epub3 = spinePathsEPUB!()(doc_matters.output_path, doc_matters.src.language); auto xhtml_format = outputXHTMLs(); /+ zip file +/ diff --git a/org/output_hub.org b/org/output_hub.org index b2985be..c683742 100644 --- a/org/output_hub.org +++ b/org/output_hub.org @@ -32,10 +32,10 @@ template outputHub() { const D doc_abstraction, I doc_matters ) { - mixin spineOutputRgxInit; + mixin spineRgxOut; mixin Msg; auto msg = Msg!()(doc_matters); - static auto rgx = Rgx(); + static auto rgx = RgxO(); enum outTask { source_or_pod, sqlite, sqlite_multi, latex, odt, epub, html_scroll, html_seg, html_stuff } void Scheduled(D,I)(int sched, D doc_abstraction, I doc_matters) { auto msg = Msg!()(doc_matters); @@ -59,8 +59,8 @@ template outputHub() { template outputHubOp() { <> @system void outputHubOp(E,O)(E env, O opt_action) { - mixin spineOutputRgxInit; - static auto rgx = Rgx(); + mixin spineRgxOut; + static auto rgx = RgxO(); <> } } diff --git a/org/spine.org b/org/spine.org index 58d76ed..72d3b1d 100644 --- a/org/spine.org +++ b/org/spine.org @@ -281,10 +281,10 @@ mixin CompileTimeInfo; #+NAME: spine_mixin #+BEGIN_SRC d -mixin spineRgxInit; +mixin spineRgxIn; mixin contentJSONtoSpineStruct; mixin spineBiblio; -mixin spineRgxInitFlags; +mixin spineRgxDocStructFlags; mixin outputHub; #+END_SRC @@ -302,7 +302,7 @@ auto hvst = spineHarvest!(); string flag_action; string arg_unrecognized; enum dAM { abstraction, matters } -static auto rgx = Rgx(); +static auto rgx = RgxI(); #+END_SRC *** scope (run complete) :scope: @@ -1181,7 +1181,7 @@ template spineAbstraction() { enum headBody { header, body_content, insert_file_list, image_list } enum makeMeta { make, meta } enum docAbst { doc_abstract_obj, doc_has } - static auto rgx = Rgx(); + static auto rgx = RgxI(); @system auto spineAbstraction(E,P,O,M,S)( E _env, P program_info, -- cgit v1.2.3