aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/doc_reform/source
diff options
context:
space:
mode:
authorRalph Amissah <ralph.amissah@gmail.com>2019-10-22 19:32:45 -0400
committerRalph Amissah <ralph.amissah@gmail.com>2019-11-18 14:59:47 -0500
commit02714184258c9be072857ddcc03bc114b2e843d1 (patch)
tree9818170940f4db2334c54059869819f07f57a10d /src/doc_reform/source
parentmultilingual pods, zipped source (diff)
cosmetic
Diffstat (limited to 'src/doc_reform/source')
-rw-r--r--src/doc_reform/source/paths_source.d42
-rw-r--r--src/doc_reform/source/read_config_files.d28
2 files changed, 35 insertions, 35 deletions
diff --git a/src/doc_reform/source/paths_source.d b/src/doc_reform/source/paths_source.d
index 86338af..838f114 100644
--- a/src/doc_reform/source/paths_source.d
+++ b/src/doc_reform/source/paths_source.d
@@ -72,7 +72,7 @@ template PathMatters() {
string _fns = "",
char[][] _manifest_fn_list = [[]],
) {
- auto _manifest = PodManifest!()(_pth);
+ auto _manifested = PodManifest!()(_pth);
struct ManifestMatters_ {
auto env() {
auto _env = _env;
@@ -89,35 +89,35 @@ template PathMatters() {
auto opt() {
auto _opt_actions = _opt_actions;
struct Opt_ {
- auto action() { // redundant
+ auto action() {
return _opt_actions;
}
}
return Opt_();
}
bool src_is_pod() {
- return (_manifest.pod_manifest_path.length > 0) ? true : false;
+ return (_manifested.pod_manifest_path.length > 0) ? true : false;
}
auto pod() {
struct Pod_ {
bool src_is_pod() {
- return (_manifest.pod_manifest_path.length > 0) ? true : false;
+ return (_manifested.pod_manifest_path.length > 0) ? true : false;
}
auto collection_root() {
- auto _collection_root = ((chainPath(_manifest.pod_manifest_path, "..")).asNormalizedPath).array;
+ auto _collection_root = ((chainPath(_manifested.pod_manifest_path, "..")).asNormalizedPath).array;
return _collection_root;
}
string manifest_filename() {
- return _manifest.pod_manifest_filename;
+ return _manifested.pod_manifest_filename;
}
string manifest_path() {
- return _manifest.pod_manifest_path;
+ return _manifested.pod_manifest_path;
}
string pod_name_with_path() {
- return _manifest.pod_manifest_path.baseName;
+ return _manifested.pod_manifest_path.baseName;
}
string manifest_file_with_path() {
- return _manifest.pod_manifest_file_with_path;
+ return _manifested.pod_manifest_file_with_path;
}
string[] config_dr_document_make_dirs() {
string[] _config_dirs;
@@ -154,13 +154,13 @@ template PathMatters() {
auto _env = _env;
struct SRC_ {
bool is_pod() {
- return (_manifest.pod_manifest_path.length > 0) ? true : false;
+ return (_manifested.pod_manifest_path.length > 0) ? true : false;
}
string path_and_fn() {
return _fns;
}
string pod_name_with_path() {
- return (is_pod) ? _manifest.pod_manifest_path : "";
+ return (is_pod) ? _manifested.pod_manifest_path : "";
}
string pod_name() {
return pod_name_with_path.baseName;
@@ -392,7 +392,7 @@ template ConfigFilePaths() {
mixin DocReformRgxInit;
static auto rgx = Rgx();
auto ConfigFilePaths(M,E)(
- M _manifest,
+ M _manifested,
E _env,
) {
struct ConfFilePaths {
@@ -409,17 +409,17 @@ template ConfigFilePaths() {
/+ config local site (file system only, not in pod) +/
/+ return paths +/
string[] _possible_config_path_locations;
- if (_manifest.src.is_pod) {
+ if (_manifested.src.is_pod) {
/+ config document in pod +/
string _dr_doc_conf_pod;
string _dr_doc_conf_pod_text;
_dr_doc_conf_pod = asNormalizedPath(chainPath(
to!string(_env["pwd"]),
- _manifest.pod.manifest_path ~ "/conf"
+ _manifested.pod.manifest_path ~ "/conf"
)).array;
_dr_doc_conf_pod_text = asNormalizedPath(chainPath(
to!string(_env["pwd"]),
- _manifest.pod.manifest_path ~ "/media/text/" ~ _manifest.src.lng ~ "/conf"
+ _manifested.pod.manifest_path ~ "/media/text/" ~ _manifested.src.lng ~ "/conf"
)).array;
/+ return paths +/
_possible_config_path_locations = [
@@ -455,9 +455,9 @@ template ConfigFilePaths() {
string _dot_home = ((chainPath(to!string(_env["home"]), ".dr")).asNormalizedPath).array;
/+ return paths +/
string[] _possible_config_path_locations;
- if (_manifest.src.is_pod) {
- string _collection_root_a = ((chainPath(to!string(_manifest.pod.collection_root.to!string), ".dr")).asNormalizedPath).array;
- string _collection_root_b = ((chainPath(to!string(_manifest.pod.collection_root.to!string), "_dr")).asNormalizedPath).array;
+ if (_manifested.src.is_pod) {
+ string _collection_root_a = ((chainPath(to!string(_manifested.pod.collection_root.to!string), ".dr")).asNormalizedPath).array;
+ string _collection_root_b = ((chainPath(to!string(_manifested.pod.collection_root.to!string), "_dr")).asNormalizedPath).array;
_possible_config_path_locations = [
_dot_pwd,
_underscore_pwd,
@@ -762,9 +762,9 @@ template DocReformPathsPods() {
}
auto fn_pod_filelist(string fn_src) {
auto pod_root_ = pod_root(fn_src);
- auto _manifest = PodManifest!()(fn_src).pod_manifest_filename;
- auto pth_1_ = _manifest;
- auto pth_2_ = ((pod_root(fn_src).filesystem_open_zpod.chainPath(_manifest)).asNormalizedPath).array;
+ auto _manifested = PodManifest!()(fn_src).pod_manifest_filename;
+ auto pth_1_ = _manifested;
+ auto pth_2_ = ((pod_root(fn_src).filesystem_open_zpod.chainPath(_manifested)).asNormalizedPath).array;
struct _pods {
auto zpod() {
return pth_1_;
diff --git a/src/doc_reform/source/read_config_files.d b/src/doc_reform/source/read_config_files.d
index 6c652fb..4827fff 100644
--- a/src/doc_reform/source/read_config_files.d
+++ b/src/doc_reform/source/read_config_files.d
@@ -14,11 +14,11 @@ static template readConfigSite() {
std.file,
std.path;
mixin DocReformRgxInit;
- final auto readConfigSite(M,E)(M _manifest, E _env) {
+ final auto readConfigSite(M,E)(M _manifested, E _env) {
static auto rgx = Rgx();
string config_file_str;
string conf_filename = "NONE";
- auto _conf_file_details = ConfigFilePaths!()(_manifest, _env);
+ auto _conf_file_details = ConfigFilePaths!()(_manifested, _env);
string[] possible_config_path_locations = _conf_file_details.possible_config_path_locations.config_local_site;
foreach(conf_fn; [_conf_file_details.config_filename_site]) {
foreach(pth; possible_config_path_locations) {
@@ -69,11 +69,11 @@ static template readConfigDoc() {
std.file,
std.path;
mixin DocReformRgxInit;
- final auto readConfigDoc(M,E)(M _manifest, E _env) {
+ final auto readConfigDoc(M,E)(M _manifested, E _env) {
static auto rgx = Rgx();
string config_file_str;
string conf_filename = "NONE";
- auto _conf_file_details = ConfigFilePaths!()(_manifest, _env);
+ auto _conf_file_details = ConfigFilePaths!()(_manifested, _env);
string[] possible_config_path_locations = _conf_file_details.possible_config_path_locations.dr_document_make;
foreach(conf_fn; [_conf_file_details.config_filename_document]) {
foreach(pth; possible_config_path_locations) {
@@ -122,11 +122,11 @@ static template configReadSiteYAML() {
std.file,
std.path;
import dyaml;
- final YAMLDocument configReadSiteYAML(M,E)(M _manifest, E _env) {
- string _configuration = configReadInSiteYAML!()(_manifest, _env);
- auto _conf_file_details = ConfigFilePaths!()(_manifest, _env);
- string _conf_yaml = _conf_file_details.config_filename_site;
- YAMLDocument _yaml_conf = configYAML!()(_configuration, _conf_yaml);
+ final YAMLDocument configReadSiteYAML(M,E)(M _manifested, E _env) {
+ string _configuration = configReadInSiteYAML!()(_manifested, _env);
+ auto _conf_file_details = ConfigFilePaths!()(_manifested, _env);
+ string _conf_yaml_fn = _conf_file_details.config_filename_site;
+ YAMLDocument _yaml_conf = configYAML!()(_configuration, _conf_yaml_fn);
return _yaml_conf;
}
}
@@ -136,11 +136,11 @@ static template configReadDocYAML() {
doc_reform.source.paths_source,
std.file,
std.path;
- final YAMLDocument configReadDocYAML(M,E)(M _manifest, E _env) {
- string _configuration = configReadInDocYAML!()(_manifest, _env);
- auto _conf_file_details = ConfigFilePaths!()(_manifest, _env);
- string _conf_yaml = _conf_file_details.config_filename_document;
- YAMLDocument _yaml_conf = configYAML!()(_configuration, _conf_yaml);
+ final YAMLDocument configReadDocYAML(M,E)(M _manifested, E _env) {
+ string _configuration = configReadInDocYAML!()(_manifested, _env);
+ auto _conf_file_details = ConfigFilePaths!()(_manifested, _env);
+ string _conf_yaml_fn = _conf_file_details.config_filename_document;
+ YAMLDocument _yaml_conf = configYAML!()(_configuration, _conf_yaml_fn);
return _yaml_conf;
}
}