From c37eb0768635a42686ea986343ff95ae03f08c1d Mon Sep 17 00:00:00 2001 From: Ralph Amissah Date: Tue, 30 Oct 2018 11:46:44 -0400 Subject: 0.3.0 internal links, anchor tags & segment associations --- src/doc_reform/doc_reform.d | 68 ++++++++++++++++++++++++++++----------------- 1 file changed, 42 insertions(+), 26 deletions(-) (limited to 'src/doc_reform/doc_reform.d') diff --git a/src/doc_reform/doc_reform.d b/src/doc_reform/doc_reform.d index 4a0a9b5..1d39909 100755 --- a/src/doc_reform/doc_reform.d +++ b/src/doc_reform/doc_reform.d @@ -448,11 +448,15 @@ void main(string[] args) { } } if (!(_opt_action.skip_output)) { - debug(steps) { + if ((_opt_action.debug_do) + || (_opt_action.very_verbose) + ) { writeln("step0 commence → (without processing files)"); } outputHubOp!()(_env, _opt_action); - debug(steps) { + if ((_opt_action.debug_do) + || (_opt_action.very_verbose) + ) { writeln("- step0 complete"); } } @@ -464,9 +468,8 @@ void main(string[] args) { scope(success) { if (!(_opt_action.quiet)) { writefln( - "%s\n%s", - "~ document complete, ok ~", - "------------------------------------------------------------------", + "%s", + "-- ~ document complete, ok ~ ------------------------------------", ); } } @@ -485,7 +488,9 @@ void main(string[] args) { "not a sisu markup filename: «" ~ manifest.src.filename ~ "»" ); - debug(steps) { + if ((_opt_action.debug_do) + || (_opt_action.very_verbose) + ) { writeln("--->\nstepX commence → (document abstraction)"); } auto t = DocReformAbstraction!()(_env, _opt_action, manifest); @@ -493,7 +498,9 @@ void main(string[] args) { static assert(t.length==2); auto doc_abstraction = t[dAM.abstraction]; auto doc_matters = t[dAM.matters]; - debug(steps) { + if ((doc_matters.opt.action.debug_do) + || (doc_matters.opt.action.very_verbose) + ) { writeln("- stepX complete"); } /+ ↓ debugs +/ @@ -501,26 +508,29 @@ void main(string[] args) { DocReformAbstractionSummary!()(doc_abstraction, doc_matters); } /+ ↓ debugs +/ - if ((doc_matters.opt.action.debug_do) - || (doc_matters.opt.action.verbose) - ) { + if (doc_matters.opt.action.debug_do) { DocReformDebugs!()(doc_abstraction, doc_matters); } /+ ↓ output hub +/ if (!(doc_matters.opt.action.skip_output)) { - debug(steps) { + if ((_opt_action.debug_do) + || (_opt_action.very_verbose) + ) { writeln("step5 commence → (process outputs)"); } outputHub!()(doc_abstraction, doc_matters); - debug(steps) { + if ((_opt_action.debug_do) + || (_opt_action.very_verbose) + ) { writeln("- step5 complete"); } } scope(exit) { if (!(_opt_action.quiet)) { writefln( - "processed file: %s", - manifest.src.filename + "processed file: %s (%s)", + manifest.src.filename, + manifest.src.language ); } destroy(manifest); @@ -538,9 +548,8 @@ void main(string[] args) { scope(success) { if (!(_opt_action.quiet)) { writefln( - "%s\n%s", - "~ document complete, ok ~", - "------------------------------------------------------------------", + "%s", + "-- ~ document complete, ok ~ ------------------------------------", ); } } @@ -559,7 +568,9 @@ void main(string[] args) { "not a sisu markup filename: «" ~ manifest.src.filename ~ "»" ); - debug(steps) { + if ((_opt_action.debug_do) + || (_opt_action.very_verbose) + ) { writeln("--->\nstepX commence → (document abstraction)"); } auto t = DocReformAbstraction!()(_env, _opt_action, manifest); @@ -567,7 +578,9 @@ void main(string[] args) { static assert(t.length==2); auto doc_abstraction = t[dAM.abstraction]; auto doc_matters = t[dAM.matters]; - debug(steps) { + if ((doc_matters.opt.action.debug_do) + || (doc_matters.opt.action.very_verbose) + ) { writeln("- stepX complete"); } /+ ↓ debugs +/ @@ -575,26 +588,29 @@ void main(string[] args) { DocReformAbstractionSummary!()(doc_abstraction, doc_matters); } /+ ↓ debugs +/ - if ((doc_matters.opt.action.debug_do) - || (doc_matters.opt.action.verbose) - ) { + if (doc_matters.opt.action.debug_do) { DocReformDebugs!()(doc_abstraction, doc_matters); } /+ ↓ output hub +/ if (!(doc_matters.opt.action.skip_output)) { - debug(steps) { + if ((_opt_action.debug_do) + || (_opt_action.very_verbose) + ) { writeln("step5 commence → (process outputs)"); } outputHub!()(doc_abstraction, doc_matters); - debug(steps) { + if ((_opt_action.debug_do) + || (_opt_action.very_verbose) + ) { writeln("- step5 complete"); } } scope(exit) { if (!(_opt_action.quiet)) { writefln( - "processed file: %s", - manifest.src.filename + "processed file: %s (%s)", + manifest.src.filename, + manifest.src.language ); } destroy(manifest); -- cgit v1.2.3