release 0.4-10
This commit is contained in:
parent
c48e3ffb9c
commit
61f3759498
@ -1,26 +1,27 @@
|
||||
From 68843c1f3dd21a06aa2dc3637a4ffa40f6d572a8 Mon Sep 17 00:00:00 2001
|
||||
From b3d6ea5ed88b0e6cf9fdb411a14e725665ded92e Mon Sep 17 00:00:00 2001
|
||||
From: Tim Lauridsen <timlau@fedoraproject.org>
|
||||
Date: Sun, 9 Sep 2012 16:10:17 +0200
|
||||
Subject: [PATCH] fix for option begining with rem is removed (upstream issue
|
||||
#28)
|
||||
Date: Fri, 7 Mar 2014 19:06:40 +0100
|
||||
Subject: [PATCH] Fix handling of REM xxxxxxxx as a comment, but REMXXXX is not
|
||||
(upstream issue #28)
|
||||
|
||||
---
|
||||
iniparse/ini.py | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
tests/test_ini.py | 3 +--
|
||||
1 file changed, 1 insertion(+), 2 deletions(-)
|
||||
|
||||
diff --git a/iniparse/ini.py b/iniparse/ini.py
|
||||
index 408354d..68dd65c 100644
|
||||
--- a/iniparse/ini.py
|
||||
+++ b/iniparse/ini.py
|
||||
@@ -171,7 +171,7 @@ def change_comment_syntax(comment_chars='%;#', allow_rem=False):
|
||||
CommentLine.regex = re.compile(regex)
|
||||
|
||||
class CommentLine(LineType):
|
||||
- regex = re.compile(r'^(?P<csep>[;#]|[rR][eE][mM])'
|
||||
+ regex = re.compile(r'^(?P<csep>[;#]|[rR][eE][mM] +)'
|
||||
r'(?P<comment>.*)$')
|
||||
|
||||
def __init__(self, comment='', separator='#', line=None):
|
||||
diff --git a/tests/test_ini.py b/tests/test_ini.py
|
||||
index 07d4f4e..6d974f0 100644
|
||||
--- a/tests/test_ini.py
|
||||
+++ b/tests/test_ini.py
|
||||
@@ -144,8 +144,7 @@ class test_comment_line(unittest.TestCase):
|
||||
'#this is a comment',
|
||||
';; this is also a comment',
|
||||
'; so is this ',
|
||||
- 'Rem and this',
|
||||
- 'remthis too!'
|
||||
+ 'Rem and this'
|
||||
]
|
||||
def test_parsing(self):
|
||||
for l in self.lines:
|
||||
--
|
||||
1.7.11.4
|
||||
1.8.5.3
|
||||
|
||||
|
@ -5,7 +5,7 @@
|
||||
|
||||
Name: python-iniparse
|
||||
Version: 0.4
|
||||
Release: 9%{?dist}
|
||||
Release: 10%{?dist}
|
||||
Summary: Python Module for Accessing and Modifying Configuration Data in INI files
|
||||
Group: Development/Libraries
|
||||
License: MIT
|
||||
@ -90,6 +90,8 @@ mv $RPM_BUILD_ROOT/usr/share/doc/iniparse-%{version} $RPM_BUILD_ROOT%{_pkgdocdir
|
||||
%clean
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
|
||||
%check
|
||||
%{__python2} runtests.py
|
||||
|
||||
%files
|
||||
%defattr(-,root,root,-)
|
||||
@ -105,6 +107,10 @@ rm -rf $RPM_BUILD_ROOT
|
||||
|
||||
|
||||
%changelog
|
||||
* Fri Mar 07 2014 Tim Lauridsen <timlau@fedoraproject.org> - 0.4-10
|
||||
- added %%check to run unittests when build
|
||||
- updated fix-issue-28.patch, so test cases dont fail
|
||||
|
||||
* Fri Sep 20 2013 Bohuslav Kabrda <bkabrda@redhat.com> - 0.4-9
|
||||
- Introduce python3 subpackage.
|
||||
- Use %%__python2 instead of %%__python.
|
||||
|
Loading…
Reference in New Issue
Block a user