From 3552c3e6cb666ac3f063652862e3b287cd30c904 Mon Sep 17 00:00:00 2001 From: Syndamia Date: Mon, 23 Oct 2023 15:34:14 +0300 Subject: [generate] Reworked to use csg, updated awk scripts with csg in mind and updated info in _header --- awk-edits/Presentation.awk | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'awk-edits/Presentation.awk') diff --git a/awk-edits/Presentation.awk b/awk-edits/Presentation.awk index 9fd64e3..4d3826a 100644 --- a/awk-edits/Presentation.awk +++ b/awk-edits/Presentation.awk @@ -1,3 +1,4 @@ +# .*(slides|teaching)/.*html # # == About == # @@ -87,8 +88,6 @@ # Refer to src/talks/demo/index.md BEGIN { - nopresentation=!(substr(ARGV[1], "slides") || substr(ARGV[1], "teaching")) # FILENAME isn't available yet - # names is name of ftag, meaning if `names[i] = "examp"` the ftag will be &&examp # ended specifies how the HTML tag is ended # `ended[i] = 0` means no closing ftag (so no &&/examp) @@ -218,15 +217,15 @@ function presentationSubstitute(ind) { gsub(cpat[ind], crep[ind]) } -nopresentation == 0 && // { +// { presInsideCode = 1 } -nopresentation == 0 && /<\/code>/ { +/<\/code>/ { presInsideCode = 0 } -nopresentation == 0 && presInsideCode == 0 && /^[ \t]*(

)?&&/ { +presInsideCode == 0 && /^[ \t]*(

)?&&/ { for (i = 1; i <= nameslength; i++) { if (index($0, names[i]) != 0) presentationSubstitute(i) -- cgit v1.3.1-26-gb76a