debian/0000755000000000000000000000000012302375673007176 5ustar debian/copyright0000644000000000000000000000372112150241507011121 0ustar Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: ConfigObj Upstream-Contact: Michael Foord Source: http://www.voidspace.org.uk/python/configobj.html Files: * Copyright: 2005-2010, Michael Foord, Mark Andrews, Nicola Larosa License: Voidspace-BSD Files: debian/* Copyright: 2006, Gustavo Noronha Silva 2008, Daniel Watkins 2010-2013, Stefano Rivera License: Voidspace-BSD License: Voidspace-BSD Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. * Neither the name of Michael Foord nor the name of Voidspace may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. debian/changelog0000644000000000000000000002021012302375673011043 0ustar configobj (4.7.2+ds-5build1) trusty; urgency=medium * Rebuild to drop files installed into /usr/share/pyshared. -- Matthias Klose Sun, 23 Feb 2014 13:46:35 +0000 configobj (4.7.2+ds-5) unstable; urgency=low [ Stefano Rivera ] * Replace Daniel Watkins as the Maintainer, with the Debian Python Modules Team, at the request of the MIA team (Closes: #705273) * Add autopkgtests. * Bump Standards-Version to 3.9.4. - Bump B-D on debhelper to 8.1, for build-{arch,indep} support. [ Jakub Wilk ] * Use canonical URIs for Vcs-* fields. -- Stefano Rivera Sun, 26 May 2013 01:04:56 +0200 configobj (4.7.2+ds-4) unstable; urgency=low * Clean correctly (Closes: #671312) - Remove .egg-info - Remove generated API documentation. * Update machine-readable copyright file format to 1.0. * Bump Standards-Version to 3.9.3, no changes needed. * Move "docs" contents to a subdirectory in /usr/share/doc/python-configobj. -- Stefano Rivera Thu, 03 May 2012 14:47:52 +0200 configobj (4.7.2+ds-3) unstable; urgency=low * Rebuild for Python transition. * Remove Breaks: ${python:Breaks}, no longer used by dh_python2. * Bump Standards-Version to 3.9.2 (no changes needed). -- Stefano Rivera Sat, 16 Apr 2011 09:28:21 +0200 configobj (4.7.2+ds-2) unstable; urgency=low [ Stefano Rivera ] * Don't leak uid and umask into source tarball and set -e. * Bumped Standards-Version to 3.9.1 (no changes needed). * Enable test suites. - Build Depend on python-all, python-unittest2. - New patch: report-doctest-failure.diff: Fail on failures. - New patch: py27-test.diff: Convert float-comparing doctests to unit tests. * Wrap long lines in debian/control. * Merge Build-Depends-Indep into Build-Depends (no arch-dependant packages). * Switch to dh_python2 - Use X-Python-Version (requires python-all >= 2.6.5-13~). - Use ${python:Breaks}. * Update my e-mail address. * Use DEP5 format in debian/copyright. [ Jelmer Vernooij ] * Properly handle triple quotes. Closes: #618349, LP: #710410 * Add myself to uploaders. -- Jelmer Vernooij Wed, 16 Mar 2011 11:17:14 +0100 configobj (4.7.2+ds-1) unstable; urgency=low * New upstream release. * +ds version, as release zip file contains root-level __MACOSX directory. * Added get-orig-source rule to debian/rules -- Stefano Rivera Fri, 05 Mar 2010 21:12:23 +0200 configobj (4.7.1-1) unstable; urgency=low * New upstream release. -- Stefano Rivera Tue, 16 Feb 2010 07:59:06 +0200 configobj (4.7.0-1) unstable; urgency=low [ Sandro Tosi ] * debian/control - switch Vcs-Browser field to viewsvn [ Stefano Rivera ] * New upstream release. (Closes: 555407) * Package under team maintenance. (Closes: 544448) * Bumped Standards-Version to 3.8.4 (no changes needed). * Converted to 3.0 (quilt) * debian/rules - Converted to debhelper 7 overrides - Don't compress epydoc.js * Patches: - 01_eggify.dpatch converted to eggify.diff (quilt+DEP3). - 02_doc_generation_fix.dpatch removed (fixed upstream) * debain/control - Unversioned python-setuptools dependency (oldstable has a suitable version) - Removed unecessary XB-Python-Version. - Minor changes to description. * debian/copyright - Updated years and added author Mark Andrews. - Included full license, as it isn't identical to the common-licenses one. * debian/watch - Switched from sf.net to author's homepage, as redirector can't see 4.7.0. -- Stefano Rivera Mon, 01 Feb 2010 01:34:21 +0200 configobj (4.5.3-1) experimental; urgency=low * New upstream release. * Adopting. (Closes: #493792) * Switched from using CDBS to debhelper 7. * Patches: + Converted 01_eggify.diff to 01_eggify.dpatch. + Added 02_doc_generation_fix.dpatch, which allows the documentation to build. * Bumped Standards-Version to 3.8.0. * Added python-docutils to Build-Depends-Indep. -- Daniel Watkins Sat, 20 Sep 2008 11:50:33 +0100 configobj (4.5.2-2) unstable; urgency=low * Orphaning. -- Gustavo Noronha Silva Sat, 10 May 2008 16:36:12 -0300 configobj (4.5.2-1) unstable; urgency=low [ Piotr Ożarowski ] * Homepage field added * Rename XS-Vcs-* fields to Vcs-* (dpkg supports them now) [ Sandro Tosi ] * debian/control - added Vcs-Browser [ Gustavo Noronha Silva ] * New upstream release * debian/rules: - configobj no longer provides an oddly-named changelog; * debian/rules, debian/python-configobj.install: - make sure to install all the useful stuff that now lives in doc/ * debian/python-configobj.doc-base.api: - fixed Section to conform to the doc-base manual specifications * debian/control: - updated standards version to 3.7.3 - no longer build-depend on a -1 revision for setuptools -- Gustavo Noronha Silva Sat, 10 May 2008 16:32:05 -0300 configobj (4.4.0-2) unstable; urgency=low [Gustavo Noronha Silva] * debian/control: - remove duplicated line from the description (Closes: #423188) * debian/rules: - use full-named arguments for epydoc; thanks to Cyril Brulebois for pointing out the fix; (Closes: #433744) [Piotr Ożarowski] * New python-support handles egg's directory name correctly * bump python-support required version * remove mv part from debian/rules -- Gustavo Noronha Silva Thu, 09 Aug 2007 21:37:04 -0300 configobj (4.4.0-1) unstable; urgency=low [ Piotr Ozarowski ] * Added XS-Vcs-Svn field [ Gustavo Noronha Silva ] * New upstream release * debian/control: - moved python-dev and python-support from build-deps-indep to build-deps, since they are needed to satisfy clean target - replaced python-dev with python-all-dev (>= 2.3.5-11), following the wiki NewPolicy documentation - updated python-support version requirement to 0.5.3, also according to the NewPolicy documentation * debian/pycompat: - removed, according to the NewPolicy on wiki * debian/patches/00_eggify.diff: - updated to the new version * debian/rules, debian/control: - use epydoc to generate the API documentation, since it is not included in this release's zip file; this adds epydoc as a build-dep-indep -- Gustavo Noronha Silva Sat, 21 Apr 2007 12:33:54 -0300 configobj (4.3.2-2) unstable; urgency=low * debian/rules: - rename the egg info directory so that easy_install and others will not ignore it because there is a python version number (Closes: #373935) * debian/pycompat: - added; track policy version * debian/control, debian/rules: - updated to python-support 0.3 -- Gustavo Noronha Silva Fri, 23 Jun 2006 15:47:24 -0300 configobj (4.3.2-1) unstable; urgency=low * New upstream version * Supports the New Policy -- see specific changes below (Closes: #373309) * debian/patches/00_eggify.diff: - updated; there's no need to include ez_update; all we need to do is use setuptool's setup function instead of distutil's * debian/control: - moved python and python-setuptools to Build-Depends, since they are needed in the clean target - increased Standards-Version to 3.7.2 with no changes - build-depend on the versions of cdbs, debhelper and python-support which implement the new Python Policy - add the python X-headers, and replaced the Dependencies with a substitution variable that will be filled by the packaging tools - added Provides to provide all the version specific virtual packages * debian/python-configobj.{postinst,prerm}: - removed; will be created automatically by dh_pysupport * debian/rules: - removed hack to avoid calling dh_python: it will now help instead of mess * debian/watch: - added to monitor new versions -- Gustavo Noronha Silva Thu, 15 Jun 2006 18:38:06 -0300 configobj (4.3.1-1) unstable; urgency=low * Initial Release (Closes: #366372) -- Gustavo Noronha Silva Sun, 7 May 2006 22:49:58 -0300 debian/clean0000644000000000000000000000003111750477215010176 0ustar *.egg-info/* *.pyc api/* debian/python-configobj.doc-base.api0000644000000000000000000000070511011373735014617 0ustar Document: configobj-api Title: ConfigObj API Reference Author: Ken Pizzini Abstract: ConfigObj is a simple but powerful config file reader and writer: an ini file round tripper. Its main feature is that it is very easy to use, with a straightforward programmer's interface and a simple syntax for config files. Section: Programming Format: HTML Index: /usr/share/doc/python-configobj/api/index.html Files: /usr/share/doc/python-configobj/api/*.html debian/compat0000644000000000000000000000000212150240065010357 0ustar 8 debian/patches/0000755000000000000000000000000012150241640010610 5ustar debian/patches/eggify.diff0000644000000000000000000000066011331400002012703 0ustar Description: Switch from using distutils to setuptools. Author: Daniel Watkins Forwarded: not-needed Last-Update: 2010-01-31 --- configobj_4.5.2.orig/setup.py +++ configob_4.5.2/setup.py @@ -9,7 +9,7 @@ # http://www.voidspace.org.uk/python/license.shtml import sys -from distutils.core import setup +from setuptools import setup from configobj import __version__ as VERSION NAME = 'configobj' debian/patches/py27-test.diff0000644000000000000000000000605711513423107013232 0ustar Description: Fix tests on Python 2.7 by making as_* tests proper unit tests Author: Stefan Parviainen Origin: http://code.google.com/r/pafcu-configobj/source/detail?r=ccd79e87be5cee5b8a00df75ede01c66ad9308a5 Last-Update: 2011-01-12 --- a/configobj.py +++ b/configobj.py @@ -1010,18 +1010,6 @@ If the value is an invalid literal for ``float``, a ``ValueError`` will be raised. - - >>> a = ConfigObj() - >>> a['a'] = 'fish' - >>> a.as_float('a') - Traceback (most recent call last): - ValueError: invalid literal for float(): fish - >>> a['b'] = '1' - >>> a.as_float('b') - 1.0 - >>> a['b'] = '3.2' - >>> a.as_float('b') - 3.2000000000000002 """ return float(self[key]) --- a/tests/functionaltests/test_configobj.py +++ b/tests/functionaltests/test_configobj.py @@ -99,3 +99,23 @@ # This raises a MissingInterpolationOption exception in 4.7.1 and earlier repr(c) + def test_as_functions(self): + a = ConfigObj() + a['a'] = 'fish' + self.assertRaises(ValueError, a.as_bool, 'a') + a['b'] = 'True' + self.assertEquals(a.as_bool('b'),True) + a['b'] = 'off' + self.assertEquals(a.as_bool('b'),False) + a['a'] = 'fish' + self.assertRaises(ValueError, a.as_int, 'a') + a['b'] = '1' + self.assertEquals(a.as_int('b'),1) + a['b'] = '3.2' + self.assertRaises(ValueError,a.as_int,'b') + a['a'] = 'fish' + self.assertRaises(ValueError,a.as_float, 'a') + a['b'] = '1' + self.assertEqual(a.as_float('b'),1.0) + a['b'] = '3.2' + self.assertEqual(a.as_float('b'),3.2) --- a/tests/test_configobj.py +++ b/tests/test_configobj.py @@ -576,50 +576,7 @@ >>> c = ConfigObj(a, unrepr=True) >>> type(c['k']) == dict 1 - - >>> a = ConfigObj() - >>> a['a'] = 'fish' - >>> a.as_bool('a') - Traceback (most recent call last): - ValueError: Value "fish" is neither True nor False - >>> a['b'] = 'True' - >>> a.as_bool('b') - 1 - >>> a['b'] = 'off' - >>> a.as_bool('b') - 0 - - >>> a = ConfigObj() - >>> a['a'] = 'fish' - >>> try: - ... a.as_int('a') #doctest: +ELLIPSIS - ... except ValueError, e: - ... err_mess = str(e) - >>> err_mess.startswith('invalid literal for int()') - 1 - >>> a['b'] = '1' - >>> a.as_int('b') - 1 - >>> a['b'] = '3.2' - >>> try: - ... a.as_int('b') #doctest: +ELLIPSIS - ... except ValueError, e: - ... err_mess = str(e) - >>> err_mess.startswith('invalid literal for int()') - 1 - - >>> a = ConfigObj() - >>> a['a'] = 'fish' - >>> a.as_float('a') - Traceback (most recent call last): - ValueError: invalid literal for float(): fish - >>> a['b'] = '1' - >>> a.as_float('b') - 1.0 - >>> a['b'] = '3.2' - >>> a.as_float('b') - 3.2000000000000002 - + Test # with unrepr >>> a = ''' ... key1 = (1, 2, 3) # comment debian/patches/triplequotes.diff0000644000000000000000000000506311540124150014204 0ustar Description: write out the right kind of triple quotes Author: Alexander Belchenko Origin: cherrypicked from Bazaar's trunk, commit:bialix@ukr.net-20110220150125-740pnd2s46ovhler Bug: http://code.google.com/p/configobj/issues?detail?id=31 Bug-Debian: http://bugs.debian.org/618349 diff -ur configobj-4.7.2/configobj.py configobj-4.7.2.new/configobj.py --- configobj-4.7.2/configobj.py 2011-03-14 17:09:10.000000000 +0100 +++ configobj-4.7.2.new/configobj.py 2011-03-14 17:09:53.000000000 +0100 @@ -1817,9 +1817,9 @@ if (value.find('"""') != -1) and (value.find("'''") != -1): raise ConfigObjError('Value "%s" cannot be safely quoted.' % value) if value.find('"""') == -1: - quot = tdquot + quot = tsquot else: - quot = tsquot + quot = tdquot return quot diff -ur configobj-4.7.2/tests/functionaltests/test_configobj.py configobj-4.7.2.new/tests/functionaltests/test_configobj.py --- configobj-4.7.2/tests/functionaltests/test_configobj.py 2011-03-14 17:09:10.000000000 +0100 +++ configobj-4.7.2.new/tests/functionaltests/test_configobj.py 2011-03-14 17:10:09.000000000 +0100 @@ -7,6 +7,7 @@ import unittest from configobj import ConfigObj +from StringIO import StringIO try: # Python 2.6 only @@ -99,6 +100,19 @@ # This raises a MissingInterpolationOption exception in 4.7.1 and earlier repr(c) + def test_triple_quotes(self): + triple_quotes_value = '''spam +""" that's my spam """ +eggs''' + co = ConfigObj() + co['test'] = triple_quotes_value + outfile = StringIO() + co.write(outfile=outfile) + lines = outfile.getvalue().splitlines() + # now we're trying to read it back + co2 = ConfigObj(lines) + self.assertEquals(triple_quotes_value, co2['test']) + def test_as_functions(self): a = ConfigObj() a['a'] = 'fish' --- configobj-4.7.2/tests/test_configobj.py 2011-03-14 17:09:19.000000000 +0100 +++ configobj-4.7.2.new/tests/test_configobj.py 2011-03-14 17:16:18.000000000 +0100 @@ -374,7 +374,6 @@ def _doctest(): >>> cfg.write() - ["key1 = '''Multiline\\nValue'''", 'key2 = "Value" with \\'quotes\\' !'] + ['key1 = \"\"\"Multiline\\nValue\"\"\"', 'key2 = "Value" with \\'quotes\\' !'] >>> cfg.list_values = True - >>> cfg.write() == ["key1 = '''Multiline\\nValue'''", - ... 'key2 = \\'\\'\\'"Value" with \\'quotes\\' !\\'\\'\\''] - 1 + >>> cfg.write() + ['key1 = \"\"\"Multiline\\nValue\"\"\"', 'key2 = \"\"\""Value" with \\'quotes\\' !\"\"\"'] debian/patches/series0000644000000000000000000000011111540124150012014 0ustar eggify.diff report-doctest-failure.diff py27-test.diff triplequotes.diff debian/patches/report-doctest-failure.diff0000644000000000000000000000117511523215262016055 0ustar Description: Return failure if doctests fail Author: Stefano Rivera Forwarded: http://code.google.com/p/configobj/issues/detail?id=30 Last-Update: 2011-02-05 --- a/tests/test_configobj.py +++ b/tests/test_configobj.py @@ -2215,7 +2215,10 @@ doctest.testmod(m, globs=globs) import configobj - doctest.testmod(configobj, globs=globs) + failures, tests = doctest.testmod(configobj, globs=globs) + print "Ran %i tests. Failures: %i" % (tests, failures) + if failures: + sys.exit(1) -# Man alive I prefer unittest ;-) \ No newline at end of file +# Man alive I prefer unittest ;-) debian/control0000644000000000000000000000302712150237765010603 0ustar Source: configobj Section: python Priority: optional Maintainer: Debian Python Modules Team Uploaders: Stefano Rivera , Jelmer Vernooij Build-Depends: debhelper (>= 8.1), python-all (>= 2.6.5-13~), python-docutils, python-epydoc, python-setuptools, python-unittest2 Standards-Version: 3.9.4 Homepage: http://www.voidspace.org.uk/python/configobj.html X-Python-Version: >= 2.3 Vcs-Svn: svn://anonscm.debian.org/python-modules/packages/configobj/trunk/ Vcs-Browser: http://anonscm.debian.org/viewvc/python-modules/packages/configobj/trunk/ XS-Testsuite: autopkgtest Package: python-configobj Architecture: all Depends: ${misc:Depends}, ${python:Depends} Description: simple but powerful config file reader and writer for Python ConfigObj is a simple but powerful config file reader and writer: an ini file round tripper. Its main feature is that it is very easy to use, with a straightforward programmer's interface and a simple syntax for config files. It has lots of other features, though: . * Nested sections (subsections), to any level * List values * Multiple line values * String interpolation (substitution) * Integrated with a powerful validation system + including automatic type checking/conversion + and allowing default values + repeated sections * All comments in the file are preserved * The order of keys/sections is preserved * Full Unicode support * Powerful unrepr mode for storing/retrieving Python data-types debian/python-configobj.docs0000644000000000000000000000001111750477215013320 0ustar docs api debian/tests/0000755000000000000000000000000012150241640010323 5ustar debian/tests/unittests0000755000000000000000000000056012150241427012317 0ustar #!/bin/sh set -efu pythons="$(pyversions -r 2> /dev/null)" cp -a tests "$ADTTMP" cd "$ADTTMP" for python in $pythons; do echo "=== $python ===" $python tests/test_configobj.py if [ "$python" = "python2.7" ]; then PYTHONWARNINGS=default $python -m unittest discover -s tests else PYTHONWARNINGS=default $python $(which unit2) discover -s tests fi done 2>&1 debian/tests/control0000644000000000000000000000007212150237351011731 0ustar Tests: unittests Depends: @, python-all, python-unittest2 debian/rules0000755000000000000000000000203711750477215010261 0ustar #!/usr/bin/make -f # -*- makefile -*- %: dh $@ --with python2 override_dh_auto_build: dh_auto_build env PYTHONPATH=`pwd` epydoc --name ConfigObj \ --url http://www.voidspace.org.uk/python/configobj.html \ -o api configobj override_dh_auto_test: ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS))) set -ex; \ export PYTHONPATH=.; \ export PYTHONWARNINGS=default; \ for py in $(shell pyversions -r); do \ $$py tests/test_configobj.py; \ if [ "$$py" = "python2.7" ]; then \ $$py -m unittest discover -s tests; \ else \ $$py $(shell which unit2) discover -s tests; \ fi; \ done endif override_dh_compress: dh_compress -X.js get-orig-source: set -e; \ VER=$(shell dpkg-parsechangelog | sed -rne 's,^Version: ([^+]+).*,\1,p'); \ uscan --noconf --force-download --download-version=$$VER --destdir=.; \ unzip configobj-$$VER.zip; \ rm configobj-$$VER.zip; \ rm -r __MACOSX; \ GZIP=--best tar -cz --owner root --group root --mode a+rX \ -f configobj_$$VER+ds.orig.tar.gz configobj-$$VER; \ rm -r configobj-$$VER debian/source/0000755000000000000000000000000012150241640010461 5ustar debian/source/format0000644000000000000000000000001411331400002011654 0ustar 3.0 (quilt) debian/watch0000644000000000000000000000014311344257721010223 0ustar version=3 opts=dversionmangle=s/\+ds// \ http://www.voidspace.org.uk/downloads/configobj-(.*)\.zip