aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/sdp/output/html.d
diff options
context:
space:
mode:
authorRalph Amissah <ralph@amissah.com>2017-12-04 01:54:58 -0500
committerRalph Amissah <ralph@amissah.com>2019-04-10 15:14:14 -0400
commit1dbbdec89acdb2ef12cdfc0572997c4c4652466b (patch)
treef32d09a066f641bba66c48a93a9cf9042de8cb54 /src/sdp/output/html.d
parent0.23.0 make image list available early for sisupod (diff)
0.23.1 use output path specified if any
Diffstat (limited to 'src/sdp/output/html.d')
-rw-r--r--src/sdp/output/html.d17
1 files changed, 6 insertions, 11 deletions
diff --git a/src/sdp/output/html.d b/src/sdp/output/html.d
index a422a81..6767e11 100644
--- a/src/sdp/output/html.d
+++ b/src/sdp/output/html.d
@@ -165,15 +165,12 @@ template outputHTML() {
debug(asserts) {
static assert(is(typeof(doc) == string[]));
}
- string fn_src = doc_matters.source_filename;
- auto src_path_info = doc_matters.src_path_info;
- string lng = doc_matters.language;
- auto pth_html = SiSUpathsHTML!()(src_path_info, lng);
+ auto pth_html = SiSUpathsHTML!()(doc_matters.output_path, doc_matters.language);
try {
if (!exists(pth_html.base)) {
pth_html.base.mkdirRecurse;
}
- auto f = File(pth_html.fn_scroll(fn_src), "w");
+ auto f = File(pth_html.fn_scroll(doc_matters.source_filename), "w");
foreach (o; doc) {
f.writeln(o);
}
@@ -181,7 +178,7 @@ template outputHTML() {
catch (ErrnoException ex) {
// Handle error
}
- writeln(" ", doc_matters.environment.pwd, "/", pth_html.fn_scroll(fn_src));
+ writeln(" ", pth_html.fn_scroll(doc_matters.source_filename));
}
void seg(D,I)(
auto return ref const D doc_abstraction,
@@ -417,9 +414,7 @@ template outputHTML() {
}
mixin SiSUoutputRgxInit;
auto rgx = Rgx();
- auto src_path_info = doc_matters.src_path_info;
- string lng = doc_matters.language;
- auto pth_html = SiSUpathsHTML!()(src_path_info, lng);
+ auto pth_html = SiSUpathsHTML!()(doc_matters.output_path, doc_matters.language);
auto xhtml_format = outputXHTMLs();
auto m = doc_matters.source_filename.matchFirst(rgx.src_fn);
try {
@@ -440,13 +435,13 @@ template outputHTML() {
catch (ErrnoException ex) {
// handle error
}
- writeln(" ", doc_matters.environment.pwd, "/", pth_html.fn_seg(doc_matters.source_filename, "toc"));
+ writeln(" ", pth_html.fn_seg(doc_matters.source_filename, "toc"));
}
void css(M)(
auto return ref M doc_matters,
) {
auto css = SiSUcss();
- auto pth_html = SiSUpathsHTML!()(doc_matters.src_path_info, doc_matters.language);
+ auto pth_html = SiSUpathsHTML!()(doc_matters.output_path, doc_matters.language);
try {
if (!exists(pth_html.css)) {
(pth_html.css).mkdirRecurse;