Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/cygwin-apps/calm.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/calm
diff options
context:
space:
mode:
Diffstat (limited to 'calm')
-rw-r--r--calm/untest.py2
-rw-r--r--calm/version.py2
2 files changed, 2 insertions, 2 deletions
diff --git a/calm/untest.py b/calm/untest.py
index 7d6d774..7744108 100644
--- a/calm/untest.py
+++ b/calm/untest.py
@@ -53,7 +53,7 @@ def untest(pvr):
content = fh.read()
if re.search(r'^test:', content, re.MULTILINE):
- content = re.sub(r'^test:\s*$', '', content, 0, re.MULTILINE)
+ content = re.sub(r'^test:\s*$', '', content, count=0, flags=re.MULTILINE)
with open(fn, 'w') as fh:
fh.write(content)
diff --git a/calm/version.py b/calm/version.py
index c61e8fc..5a4ce84 100644
--- a/calm/version.py
+++ b/calm/version.py
@@ -58,7 +58,7 @@ class SetupVersion:
setattr(self, i, split[j])
sequences = re.finditer(r'(\d+|[a-zA-Z]+|[^a-zA-Z\d]+)', split[j])
sequences = [m for m in sequences if not re.match(r'[^a-zA-Z\d]+', m.group(1))]
- sequences = [re.sub(r'^0+(\d)', r'\1', m.group(1), 1) for m in sequences]
+ sequences = [re.sub(r'^0+(\d)', r'\1', m.group(1), count=1) for m in sequences]
setattr(self, '_' + i, sequences)
def __str__(self):