File tree Expand file tree Collapse file tree 2 files changed +10
-4
lines changed Expand file tree Collapse file tree 2 files changed +10
-4
lines changed Original file line number Diff line number Diff line change 7
7
8
8
\input {layout/hp-intro }
9
9
10
- \renewenvironment {headlines}{}{}
11
- \renewenvironment {writtenNote}{}{}
12
- \renewenvironment {playdialog}{}{}
13
-
14
10
\newcommand {\writtenNoteA }[1]{\par\textcolor {writtenNote}{#1}}
15
11
\renewcommand {\parsel }[1]{\textcolor {parsel}{#1}}
16
12
\renewcommand {\McGonagallWhiteBoard }[1]{\textcolor {McGonagallWhiteBoard}{\par #1}}
Original file line number Diff line number Diff line change 25
25
date_str = dt .datetime .now (dt .UTC ).date ().strftime ("%d.%m.%Y" )
26
26
cont = cont .replace ("\\ today{}" , date_str )
27
27
28
+ # empty the newenvironments: headlines, writtenNote, playdialog
29
+ # to prevent implications on other cleanup scripts
30
+ cont = re .sub (
31
+ r"\\newenvironment\{(headlines|writtenNote|playdialog)\}.*?\n\n" ,
32
+ r"\\newenvironment{\1}{}{}\n\n" ,
33
+ cont ,
34
+ flags = re .DOTALL ,
35
+ count = 3 ,
36
+ )
37
+
28
38
# writtenNote env -> \writtenNoteA
29
39
cont = re .sub (
30
40
r"\s*\\begin\{writtenNote\}\s*(.*?)\s*\\end\{writtenNote\}" ,
You can’t perform that action at this time.
0 commit comments