diff options
author | Ralph Amissah <ralph.amissah@gmail.com> | 2021-08-01 05:48:15 -0400 |
---|---|---|
committer | Ralph Amissah <ralph.amissah@gmail.com> | 2021-08-06 13:09:08 -0400 |
commit | 9b72621135aad321c421e7464fc4339a2a52e245 (patch) | |
tree | de3696ebbe50b488e326db934da7951c0f60a87e /src/doc_reform/io_in/read_config_files.d | |
parent | spine_search (diff) |
config defaults: cfte, config-file & cle
Diffstat (limited to 'src/doc_reform/io_in/read_config_files.d')
-rw-r--r-- | src/doc_reform/io_in/read_config_files.d | 47 |
1 files changed, 31 insertions, 16 deletions
diff --git a/src/doc_reform/io_in/read_config_files.d b/src/doc_reform/io_in/read_config_files.d index 44f93ec..005a436 100644 --- a/src/doc_reform/io_in/read_config_files.d +++ b/src/doc_reform/io_in/read_config_files.d @@ -62,7 +62,7 @@ import doc_reform.meta.rgx; template readConfigSite() { - @system final auto readConfigSite(C,O)(C _conf_file_details, O _opt_action) { + @system final auto readConfigSite(Cf,O,Cfg)(Cf _conf_file_details, O _opt_action, Cfg _cfg) { mixin spineRgxIn; static auto rgx = RgxI(); string conf_filename = "NONE"; @@ -79,28 +79,43 @@ default: text_wrap: "80" digest: "sha256" webserv: - http: "http" - domain: "localhost" - data_http: "http" - data_domain: "localhost" - data_root_url: "http://localhost" - data_root_path: "/var/www/html" + http: "%s" + domain: "%s" + data_http: "%s" + data_domain: "%s" + data_root_url: "%s" + data_root_path: "%s" data_root_part: "" images_root_part: "image" - cgi_title: "≅ SiSU Spine search" - cgi_http: "http" - cgi_domain: "localhost" - cgi_bin_url: "http://localhost/cgi-bin" + cgi_title: "%s" + cgi_http: "%s" + cgi_domain: "%s" + cgi_bin_url: "%s" cgi_bin_part: "cgi-bin" - cgi_bin_path: "/usr/lib/cgi-bin" - cgi_search_script: "spine-search" + cgi_bin_path: "%s" + cgi_search_script: "%s" cgi_port: "" cgi_user: "" - cgi_action: "http://localhost/cgi-bin/spine-search" - db_sqlite: "spine.search.db" + cgi_action: "%s" + db_sqlite: "%s" db_pg_table: "" db_pg_user: "" -┃"); +┃", + _cfg.www_http, // http + _cfg.www_domain, // domain + _cfg.www_http, // data http + _cfg.www_domain, // data domain + _cfg.www_url_doc_root, // data root url + _cfg.www_doc_root, // data root path + _cfg.cgi_title, // cgi title + _cfg.www_http, // cgi http + _cfg.www_domain, // cgi domain + _cfg.cgi_url_root, // cgi bin url + _cfg.cgi_bin_root, // cgi bin path + _cfg.cgi_filename, // cgi filename + _cfg.cgi_url_action, // cgi action + _cfg.db_sqlite_filename, // db filename +); foreach(conf_fn; [_conf_file_details.config_filename_site]) { foreach(pth; _conf_file_details.possible_config_path_locations.config_local_site) { char[] conf_file; |