diff options
Diffstat (limited to 'src/doc_reform/meta')
| -rw-r--r-- | src/doc_reform/meta/defaults.d | 16 | ||||
| -rw-r--r-- | src/doc_reform/meta/metadoc_curate.d (renamed from src/doc_reform/meta/metadoc_harvest.d) | 38 | ||||
| -rw-r--r-- | src/doc_reform/meta/metadoc_curate_authors.d (renamed from src/doc_reform/meta/metadoc_harvests_authors.d) | 82 | ||||
| -rw-r--r-- | src/doc_reform/meta/metadoc_curate_topics.d (renamed from src/doc_reform/meta/metadoc_harvests_topics.d) | 48 | 
4 files changed, 92 insertions, 92 deletions
diff --git a/src/doc_reform/meta/defaults.d b/src/doc_reform/meta/defaults.d index 4429f80..ec6ba49 100644 --- a/src/doc_reform/meta/defaults.d +++ b/src/doc_reform/meta/defaults.d @@ -95,10 +95,10 @@ template spineNode() {      return _node;    }  } -template spineHarvest() { -  @safe auto spineHarvest() { -    struct _Harvest { -      struct Harvest { +template spineCurateMetadata() { +  @safe auto spineCurateMetadata() { +    struct _Curate { +      struct Curate {          string   title                = "";          string[] author_arr           = [];          string   author               = ""; @@ -120,11 +120,11 @@ template spineHarvest() {          string   url_html_scroll      = "";          string   url_epub             = "";        } -      Harvest harvest; -      Harvest[] harvests; -      Harvest[][string][string][string][string] subject_trees; +      Curate curate; +      Curate[] curates; +      Curate[][string][string][string][string] subject_trees;      } -    return _Harvest(); +    return _Curate();    }  }  template spineBiblio() { diff --git a/src/doc_reform/meta/metadoc_harvest.d b/src/doc_reform/meta/metadoc_curate.d index 3135323..8190a9d 100644 --- a/src/doc_reform/meta/metadoc_harvest.d +++ b/src/doc_reform/meta/metadoc_curate.d @@ -48,9 +48,9 @@      [https://git.sisudoc.org/projects/?p=software/spine.git;a=summary]  +/ -module doc_reform.meta.metadoc_harvest; -template spineMetaDocHarvest() { -  @safe auto spineMetaDocHarvest(T,H)( +module doc_reform.meta.metadoc_curate; +template spineMetaDocCurate() { +  @safe auto spineMetaDocCurate(T,H)(      T  doc_matters,      H  hvst,    ) { @@ -72,21 +72,21 @@ template spineMetaDocHarvest() {      import doc_reform.io_out.paths_output;      auto pth_html_abs                  = spinePathsHTML!()(doc_matters.output_path, doc_matters.src.language);      auto pth_html_rel                  = spineDocRootTreeHTML!()(doc_matters.src.language); -    hvst.harvest.title                 = doc_matters.conf_make_meta.meta.title_full; -    hvst.harvest.author                = doc_matters.conf_make_meta.meta.creator_author; -    hvst.harvest.author_surname        = doc_matters.conf_make_meta.meta.creator_author_surname; -    hvst.harvest.author_surname_fn     = doc_matters.conf_make_meta.meta.creator_author_surname_fn; -    hvst.harvest.author_arr            = doc_matters.conf_make_meta.meta.creator_author_arr; -    hvst.harvest.language_original     = doc_matters.conf_make_meta.meta.original_language; -    hvst.harvest.language              = doc_matters.src.language; -    hvst.harvest.uid                   = doc_matters.src.doc_uid; -    hvst.harvest.date_published        = doc_matters.conf_make_meta.meta.date_published; -    hvst.harvest.topic_register_arr    = doc_matters.conf_make_meta.meta.classify_topic_register_arr; -    hvst.harvest.path_html_metadata    = pth_html_rel.fn_metadata(doc_matters.src.filename); -    hvst.harvest.path_html_scroll      = pth_html_rel.fn_scroll(doc_matters.src.filename); -    hvst.harvest.path_html_segtoc      = pth_html_rel.fn_seg(doc_matters.src.filename, "toc"); -    hvst.harvest.path_abs_html_scroll  = pth_html_abs.fn_scroll(doc_matters.src.filename); -    hvst.harvest.path_abs_html_segtoc  = pth_html_abs.fn_seg(doc_matters.src.filename, "toc"); -    return hvst.harvest; +    hvst.curate.title                 = doc_matters.conf_make_meta.meta.title_full; +    hvst.curate.author                = doc_matters.conf_make_meta.meta.creator_author; +    hvst.curate.author_surname        = doc_matters.conf_make_meta.meta.creator_author_surname; +    hvst.curate.author_surname_fn     = doc_matters.conf_make_meta.meta.creator_author_surname_fn; +    hvst.curate.author_arr            = doc_matters.conf_make_meta.meta.creator_author_arr; +    hvst.curate.language_original     = doc_matters.conf_make_meta.meta.original_language; +    hvst.curate.language              = doc_matters.src.language; +    hvst.curate.uid                   = doc_matters.src.doc_uid; +    hvst.curate.date_published        = doc_matters.conf_make_meta.meta.date_published; +    hvst.curate.topic_register_arr    = doc_matters.conf_make_meta.meta.classify_topic_register_arr; +    hvst.curate.path_html_metadata    = pth_html_rel.fn_metadata(doc_matters.src.filename); +    hvst.curate.path_html_scroll      = pth_html_rel.fn_scroll(doc_matters.src.filename); +    hvst.curate.path_html_segtoc      = pth_html_rel.fn_seg(doc_matters.src.filename, "toc"); +    hvst.curate.path_abs_html_scroll  = pth_html_abs.fn_scroll(doc_matters.src.filename); +    hvst.curate.path_abs_html_segtoc  = pth_html_abs.fn_seg(doc_matters.src.filename, "toc"); +    return hvst.curate;    }  } diff --git a/src/doc_reform/meta/metadoc_harvests_authors.d b/src/doc_reform/meta/metadoc_curate_authors.d index 182b1cd..8c64f0c 100644 --- a/src/doc_reform/meta/metadoc_harvests_authors.d +++ b/src/doc_reform/meta/metadoc_curate_authors.d @@ -48,7 +48,7 @@      [https://git.sisudoc.org/projects/?p=software/spine.git;a=summary]  +/ -module doc_reform.meta.metadoc_harvests_authors; +module doc_reform.meta.metadoc_curate_authors;    import      std.algorithm,      std.array, @@ -60,12 +60,12 @@ module doc_reform.meta.metadoc_harvests_authors;    import      doc_reform.meta.defaults,      doc_reform.meta.rgx; -  mixin spineHarvest; +  mixin spineCurateMetadata;    mixin InternalMarkup; -template spineMetaDocHarvestsAuthors() { +template spineMetaDocCuratesAuthors() {    static auto mkup = InlineMarkup(); -  void spineMetaDocHarvestsAuthors(H,M,O)( -    H  harvests, +  void spineMetaDocCuratesAuthors(H,M,O)( +    H  curates,      M  _make_and_meta_struct,      O  _opt_action,    ) { @@ -222,11 +222,11 @@ string theme_dark_1 = format(q"┃  string theme_light_1 = format(q"┃    h1 {      color                    : #FFFFFF; -    background               : #000088; +    background               : #1A3A7A;    }    p.letter {      color                    : #FFFFFF; -    background               : #880000; +    background               : #1A3A7A;    }    p.lev0 {      color                    : #FFFFFF; @@ -254,15 +254,15 @@ string theme_light_1 = format(q"┃  <html>  <head>  <meta charset="utf-8"> -<title>Metadata Harvest - Authors</title> +<title>Curated metadata - Authors</title>  <meta http-equiv="Content-Type" content="text/html;charset=utf-8" /> -<meta name="dc.title" content= "metadata harvest, Authors & Topics - information Structuring Universe, Structured information Serialised Units" /> +<meta name="dc.title" content= "metadata curate, Authors & Topics - information Structuring Universe, Structured information Serialised Units" />  <meta name="dc.subject" content= "document structuring, ebook, publishing, PDF, LaTeX, XML, ODF, SQL, postgresql, sqlite, electronic book, electronic publishing, electronic document, electronic citation, data structure, citation systems, granular search, digital library" />  <meta name="generator" content="spine" />  <link rel="generator" href="https://sisudoc.org" /> -<link href="./css/harvest.css" rel="stylesheet"> +<link href="./css/curate.css" rel="stylesheet">  <style TYPE="text/css"> -/* spine harvest css default stylesheet */%s +/* spine curate css default stylesheet */%s    .norm, .bold {      line-height              : 150%%;      margin-left              : 1em; @@ -386,11 +386,11 @@ string theme_light_1 = format(q"┃  <a name="top" id="top"></a>  <a name="up" id="up"></a>  <a name="start" id="start"></a> -<h1>Metadata Harvest - Authors (output organised by language & filetype)</h1> +<h1>Curated metadata - Authors (output organised by language & filetype)</h1>  <div class="flex-menu-bar">  <div class="flex-menu-option">  <p>[<a href="../../index.html"> HOME </a>] - [<a href="topics.html"> Metadata Harvest - Topics </a>] + [<a href="topics.html"> Curated metadata - Topics </a>]  </p>  </div>  %s @@ -408,8 +408,8 @@ string theme_light_1 = format(q"┃        string[] _author_date_title;        string _prev_auth = "";        char _prev_k = "_".to!char; -      foreach(doc_harvest; -        harvests +      foreach(doc_curate; +        curates          .multiSort!(            "toUpper(a.author_surname_fn) < toUpper(b.author_surname_fn)",            "a.date_published < b.date_published", @@ -417,38 +417,38 @@ string theme_light_1 = format(q"┃            SwapStrategy.unstable          )        ) { -        if (doc_harvest.author_surname_fn != _prev_auth) { -          _au[doc_harvest.author_surname_fn] +        if (doc_curate.author_surname_fn != _prev_auth) { +          _au[doc_curate.author_surname_fn]            = format(q"┃<p class="author"><a name="%s" class="lev0">%s</a></p> <p class="publication">%s "<a href="%s">%s</a>" [<a href="%s"> %s </a>]</p>┃", -            doc_harvest.author_surname.translate([' ' : "_"]), -            doc_harvest.author_surname_fn, -            (doc_harvest.date_published.length > 0) -              ? doc_harvest.date_published : "", -            doc_harvest.path_html_segtoc, -            doc_harvest.title, -            doc_harvest.path_html_metadata, -            doc_harvest.language, +            doc_curate.author_surname.translate([' ' : "_"]), +            doc_curate.author_surname_fn, +            (doc_curate.date_published.length > 0) +              ? doc_curate.date_published : "", +            doc_curate.path_html_segtoc, +            doc_curate.title, +            doc_curate.path_html_metadata, +            doc_curate.language,            ); -          _prev_auth = doc_harvest.author_surname_fn; +          _prev_auth = doc_curate.author_surname_fn;          } else { -          _au[doc_harvest.author_surname_fn] +          _au[doc_curate.author_surname_fn]            ~= format(q"┃<p class="publication">%s "<a href="%s">%s</a>" [<a href="%s"> %s </a>]</p>┃", -            (doc_harvest.date_published.length > 0) -              ? doc_harvest.date_published : "", -            doc_harvest.path_html_segtoc, -            doc_harvest.title, -            doc_harvest.path_html_metadata, -            doc_harvest.language, +            (doc_curate.date_published.length > 0) +              ? doc_curate.date_published : "", +            doc_curate.path_html_segtoc, +            doc_curate.title, +            doc_curate.path_html_metadata, +            doc_curate.language,            );          }          _author_date_title ~= format(q"┃%s %s "%s" [<a href="%s"> %s </a>]%s┃", -          doc_harvest.author_surname_fn, -          (doc_harvest.date_published.length > 0) -            ? "(" ~ doc_harvest.date_published ~ ")" : "", -          doc_harvest.title, -          doc_harvest.path_html_metadata, -          doc_harvest.language, -          (_opt_action.very_verbose) ? "\n  " ~ doc_harvest.path_abs_html_scroll : "", +          doc_curate.author_surname_fn, +          (doc_curate.date_published.length > 0) +            ? "(" ~ doc_curate.date_published ~ ")" : "", +          doc_curate.title, +          doc_curate.path_html_metadata, +          doc_curate.language, +          (_opt_action.very_verbose) ? "\n  " ~ doc_curate.path_abs_html_scroll : "",          );        }        foreach (k; _au.keys.sort) { @@ -476,7 +476,7 @@ string theme_light_1 = format(q"┃      import doc_reform.io_out.paths_output;      auto out_pth = spinePathsHTML!()(_make_and_meta_struct.conf.output_path, "");      try { -      auto f       = File(out_pth.harvest("authors.html"), "w"); +      auto f       = File(out_pth.curate("authors.html"), "w");        foreach (o; authors) {          f.writeln(o);        } diff --git a/src/doc_reform/meta/metadoc_harvests_topics.d b/src/doc_reform/meta/metadoc_curate_topics.d index 5848723..1fdc760 100644 --- a/src/doc_reform/meta/metadoc_harvests_topics.d +++ b/src/doc_reform/meta/metadoc_curate_topics.d @@ -48,7 +48,7 @@      [https://git.sisudoc.org/projects/?p=software/spine.git;a=summary]  +/ -module doc_reform.meta.metadoc_harvests_topics; +module doc_reform.meta.metadoc_curate_topics;    import      std.algorithm,      std.array, @@ -60,11 +60,11 @@ module doc_reform.meta.metadoc_harvests_topics;    import      doc_reform.meta.defaults,      doc_reform.meta.rgx; -  mixin spineHarvest; +  mixin spineCurateMetadata;    mixin InternalMarkup; -template spineMetaDocHarvestsTopics() { +template spineMetaDocCuratesTopics() {    static auto mkup = InlineMarkup(); -  void spineMetaDocHarvestsTopics(H,M,O)( +  void spineMetaDocCuratesTopics(H,M,O)(      H  hvst,      M  _make_and_meta_struct,      O  _opt_action, @@ -106,40 +106,40 @@ template spineMetaDocHarvestsTopics() {        string[] _sub_topic_register;        string[] topics = [];        string _auth = ""; -      foreach(k, doc_harvest; hvst.harvests) { +      foreach(k, doc_curate; hvst.curates) {          _topic_register = []; -        foreach(topic; doc_harvest.topic_register_arr.sort) { +        foreach(topic; doc_curate.topic_register_arr.sort) {            _sub_topic_register = [];            string _spaces;            string[] subject_tree = topic.split(mkup.sep);            switch (subject_tree.length) {            case 1: -            hvst.subject_trees[subject_tree[0]]["_a"]["_a"]["_a"] ~= doc_harvest; +            hvst.subject_trees[subject_tree[0]]["_a"]["_a"]["_a"] ~= doc_curate;              break;            case 2: -            hvst.subject_trees[subject_tree[0]][subject_tree[1]]["_a"]["_a"] ~= doc_harvest; +            hvst.subject_trees[subject_tree[0]][subject_tree[1]]["_a"]["_a"] ~= doc_curate;              break;            case 3: -            hvst.subject_trees[subject_tree[0]][subject_tree[1]][subject_tree[2]]["_a"] ~= doc_harvest; +            hvst.subject_trees[subject_tree[0]][subject_tree[1]][subject_tree[2]]["_a"] ~= doc_curate;              break;            case 4: -            hvst.subject_trees[subject_tree[0]][subject_tree[1]][subject_tree[2]][subject_tree[3]] ~= doc_harvest; +            hvst.subject_trees[subject_tree[0]][subject_tree[1]][subject_tree[2]][subject_tree[3]] ~= doc_curate;              break;            default:              break;            }            _topic_register ~= _sub_topic_register.join("\n");          } -        auto char_repeat_number = (doc_harvest.title.length -          + doc_harvest.author.length + 16); +        auto char_repeat_number = (doc_curate.title.length +          + doc_curate.author.length + 16);          char_repeat_number = (char_repeat_number > min_repeat_number)          ? char_repeat_number          : min_repeat_number;          _document_topic_register ~= format(            "\"%s\", %s%s\n%s", -          doc_harvest.title, -          doc_harvest.author, -          (doc_harvest.date_published.length > 0) ? " (" ~ doc_harvest.date_published ~ ")" : "", +          doc_curate.title, +          doc_curate.author, +          (doc_curate.date_published.length > 0) ? " (" ~ doc_curate.date_published ~ ")" : "",            _topic_register.sort!("toUpper(a) < toUpper(b)", SwapStrategy.unstable).release.join("\n"),          );        } @@ -265,11 +265,11 @@ string theme_dark_1 = format(q"┃  string theme_light_1 = format(q"┃    h1 {      color                    : #FFFFFF; -    background               : #000088; +    background               : #1A3A7A;    }    p.letter {      color                    : #FFFFFF; -    background               : #880000; +    background               : #1A3A7A;    }    p.lev0 {      color                    : #FFFFFF; @@ -295,15 +295,15 @@ string theme_light_1 = format(q"┃  <html>  <head>  <meta charset="utf-8"> -<title>Metadata Harvest - Topics</title> +<title>Curated metadata - Topics</title>  <meta http-equiv="Content-Type" content="text/html;charset=utf-8" /> -<meta name="dc.title" content= "metadata harvest, Authors & Topics - information Structuring Universe, Structured information Serialised Units" /> +<meta name="dc.title" content= "metadata curate, Authors & Topics - information Structuring Universe, Structured information Serialised Units" />  <meta name="dc.subject" content= "document structuring, ebook, publishing, PDF, LaTeX, XML, ODF, SQL, postgresql, sqlite, electronic book, electronic publishing, electronic document, electronic citation, data structure, citation systems, granular search, digital library" />  <meta name="generator" content="spine" />  <link rel="generator" href="https://sisudoc.org" /> -<link href="./css/harvest.css" rel="stylesheet"> +<link href="./css/curate.css" rel="stylesheet">  <style TYPE="text/css"> -/* spine harvest css default stylesheet */%s +/* spine curate css default stylesheet */%s    .norm, .bold {      line-height              : 150%%;      margin-left              : 1em; @@ -427,11 +427,11 @@ string theme_light_1 = format(q"┃  <a name="top" id="top"></a>  <a name="up" id="up"></a>  <a name="start" id="start"></a> -<h1>Metadata Harvest - Topics (output organised by language & filetype)</h1> +<h1>Curated metadata - Topics (output organised by language & filetype)</h1>  <div class="flex-menu-bar">  <div class="flex-menu-option">  <p>[<a href="../../index.html"> HOME </a>] - [<a href="authors.html"> Metadata Harvest - Authors </a>] + [<a href="authors.html"> Curated metadata - Authors </a>]  </p>  </div>   %s @@ -643,7 +643,7 @@ string theme_light_1 = format(q"┃      import doc_reform.io_out.paths_output;      auto out_pth = spinePathsHTML!()(_make_and_meta_struct.conf.output_path, "");      try { -      auto f       = File(out_pth.harvest("topics.html"), "w"); +      auto f       = File(out_pth.curate("topics.html"), "w");        foreach (o; topics) {          f.writeln(o);        }  | 
