aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul Duncan <pabs@pablotron.org>2023-03-02 23:07:45 -0500
committerPaul Duncan <pabs@pablotron.org>2023-03-02 23:07:45 -0500
commit4fe0d2bec815acae708234a1446e18ba4a16a964 (patch)
tree78b0aa3ae4586588b8108e12f352633c0b3c9e47
parent14419f066973d26192bea9b97707bd872af772c7 (diff)
downloadsection-parse-examples-4fe0d2bec815acae708234a1446e18ba4a16a964.tar.bz2
section-parse-examples-4fe0d2bec815acae708234a1446e18ba4a16a964.zip
simplify python importsHEADmain
-rw-r--r--section-parse-insane.py3
-rwxr-xr-xsection-parse.py3
2 files changed, 2 insertions, 4 deletions
diff --git a/section-parse-insane.py b/section-parse-insane.py
index e7c6d9e..6dc531e 100644
--- a/section-parse-insane.py
+++ b/section-parse-insane.py
@@ -28,8 +28,7 @@
#
# load libraries
-import re
-import sys
+import re, sys
# section and row matches
S = re.compile('(?m)^test-text "[^"]+/foo"\n((?:^[^\n]*bar\.\d+\n)+)^\s*\n')
diff --git a/section-parse.py b/section-parse.py
index f2633dc..f590254 100755
--- a/section-parse.py
+++ b/section-parse.py
@@ -31,8 +31,7 @@
#
# load libraries
-import re
-import sys
+import re, sys
# regex to match section header line
# (e.g. a line that looks like this: test-text "GARBAGE/foo"