[Python-modules-commits] r29964 - in packages/pyfiglet/trunk/debian (21 files)

stefanor at users.alioth.debian.org stefanor at users.alioth.debian.org
Sun Jul 27 19:01:56 UTC 2014


    Date: Sunday, July 27, 2014 @ 19:01:55
  Author: stefanor
Revision: 29964

* New upstream release.
* Refresh patches.
* Bump copyright years.
* Replace source tarball repacking logic with uscan's Files-Excluded
  support.
* Port to pybuild.
  - Build-Depend on dh-python.
  - Remove SOURCES.txt cleanup.
  - Build for Python 3. The Python 3 package has taken over the pyfiglet
    command line tool.
* Run upstream test suite. Build-Depends on toilet.
* Add upstream test suite as an ADT test.
* Bump Standards-Version to 3.9.5, no changes needed.

Added:
  packages/pyfiglet/trunk/debian/patches/no-entry-points.diff
  packages/pyfiglet/trunk/debian/python-pyfiglet.docs
    (from rev 29946, packages/pyfiglet/trunk/debian/docs)
  packages/pyfiglet/trunk/debian/python3-pyfiglet.docs
    (from rev 29946, packages/pyfiglet/trunk/debian/docs)
  packages/pyfiglet/trunk/debian/python3-pyfiglet.install
    (from rev 29946, packages/pyfiglet/trunk/debian/install)
  packages/pyfiglet/trunk/debian/python3-pyfiglet.manpages
    (from rev 29946, packages/pyfiglet/trunk/debian/manpages)
  packages/pyfiglet/trunk/debian/tests/smoketest3
    (from rev 29946, packages/pyfiglet/trunk/debian/tests/smoketest)
  packages/pyfiglet/trunk/debian/tests/suite
  packages/pyfiglet/trunk/debian/tests/suite3
Modified:
  packages/pyfiglet/trunk/debian/changelog
  packages/pyfiglet/trunk/debian/control
  packages/pyfiglet/trunk/debian/copyright
  packages/pyfiglet/trunk/debian/patches/debian-defaults.diff
  packages/pyfiglet/trunk/debian/patches/font-location.diff
  packages/pyfiglet/trunk/debian/patches/series
  packages/pyfiglet/trunk/debian/rules
  packages/pyfiglet/trunk/debian/tests/control
  packages/pyfiglet/trunk/debian/tests/smoketest
  packages/pyfiglet/trunk/debian/watch
Deleted:
  packages/pyfiglet/trunk/debian/docs
  packages/pyfiglet/trunk/debian/install
  packages/pyfiglet/trunk/debian/manpages

Modified: packages/pyfiglet/trunk/debian/changelog
===================================================================
--- packages/pyfiglet/trunk/debian/changelog	2014-07-27 18:46:51 UTC (rev 29963)
+++ packages/pyfiglet/trunk/debian/changelog	2014-07-27 19:01:55 UTC (rev 29964)
@@ -1,3 +1,21 @@
+pyfiglet (0.7.1+dfsg-1) UNRELEASED; urgency=medium
+
+  * New upstream release.
+  * Refresh patches.
+  * Bump copyright years.
+  * Replace source tarball repacking logic with uscan's Files-Excluded
+    support.
+  * Port to pybuild.
+    - Build-Depend on dh-python.
+    - Remove SOURCES.txt cleanup.
+    - Build for Python 3. The Python 3 package has taken over the pyfiglet
+      command line tool.
+  * Run upstream test suite. Build-Depends on toilet.
+  * Add upstream test suite as an ADT test.
+  * Bump Standards-Version to 3.9.5, no changes needed.
+
+ -- Stefano Rivera <stefanor at debian.org>  Sat, 26 Jul 2014 23:43:41 +0200
+
 pyfiglet (0.6.1+dfsg-1) unstable; urgency=low
 
   [ Stefano Rivera ]

Modified: packages/pyfiglet/trunk/debian/control
===================================================================
--- packages/pyfiglet/trunk/debian/control	2014-07-27 18:46:51 UTC (rev 29963)
+++ packages/pyfiglet/trunk/debian/control	2014-07-27 19:01:55 UTC (rev 29964)
@@ -5,11 +5,16 @@
 Uploaders: Stefano Rivera <stefanor at debian.org>
 Build-Depends:
  debhelper (>= 8.1),
- python-all (>= 2.6.5-13~),
- python-setuptools
-X-Python-Version: >= 2.5
+ dh-python,
+ python-all (>= 2.6),
+ python-setuptools,
+ python3-all,
+ python3-setuptools,
+ toilet
+X-Python-Version: >= 2.6
+X-Python3-Version: >= 3.1
 XS-Testsuite: autopkgtest
-Standards-Version: 3.9.4
+Standards-Version: 3.9.5
 Homepage: https://github.com/pwaller/pyfiglet
 Vcs-Svn: svn://anonscm.debian.org/python-modules/packages/pyfiglet/trunk/
 Vcs-Browser: http://anonscm.debian.org/viewvc/python-modules/packages/pyfiglet/trunk/
@@ -25,3 +30,17 @@
  .
  This is a Python port of the original C figlet.  It can be used on the
  commandline or as an Object Oriented driver library in your own programs.
+
+Package: python3-pyfiglet
+Architecture: all
+Depends: ${misc:Depends}, ${python3:Depends}
+Recommends: toilet-fonts
+Suggests: figlet
+Breaks: python-pyfiglet (<< 0.7.1)
+Replaces: python-pyfiglet (<< 0.7.1)
+Description: Python 3 port of the FIGlet specification
+ FIGLet is a program that creates large characters out of ordinary screen
+ characters. It takes ASCII text and renders it in ASCII art fonts.
+ .
+ This is a Python 3 port of the original C figlet.  It can be used on the
+ commandline or as an Object Oriented driver library in your own programs.

Modified: packages/pyfiglet/trunk/debian/copyright
===================================================================
--- packages/pyfiglet/trunk/debian/copyright	2014-07-27 18:46:51 UTC (rev 29963)
+++ packages/pyfiglet/trunk/debian/copyright	2014-07-27 19:01:55 UTC (rev 29964)
@@ -2,6 +2,9 @@
 Upstream-Name: pyfiglet
 Upstream-Contact: Peter Waller <peter.waller at gmail.com>
 Source: https://github.com/pwaller/pyfiglet
+Files-Excluded:
+ pyfiglet/fonts
+ doc/figfont.txt
 Comment:
  The upstream for this package includes non-distributable items is the release
  tarball:
@@ -16,12 +19,12 @@
 
 Files: *
 Copyright: 2007, Christopher Jones <cjones at gmail.com>,
-           2011-2013, Peter Waller <peter.waller at gmail.com>,
-           2011-2013, Stefano Rivera <stefanor at debian.org>
+           2011-2014, Peter Waller <peter.waller at gmail.com>,
+           2011-2014, Stefano Rivera <stefanor at debian.org>
 License: GPL-2+
 
 Files: debian/*
-Copyright: 2010-2013, Stefano Rivera <stefanor at debian.org>
+Copyright: 2010-2014, Stefano Rivera <stefanor at debian.org>
 License: GPL-2+
 
 License: GPL-2+

Deleted: packages/pyfiglet/trunk/debian/docs
===================================================================
--- packages/pyfiglet/trunk/debian/docs	2014-07-27 18:46:51 UTC (rev 29963)
+++ packages/pyfiglet/trunk/debian/docs	2014-07-27 19:01:55 UTC (rev 29964)
@@ -1 +0,0 @@
-README

Deleted: packages/pyfiglet/trunk/debian/install
===================================================================
--- packages/pyfiglet/trunk/debian/install	2014-07-27 18:46:51 UTC (rev 29963)
+++ packages/pyfiglet/trunk/debian/install	2014-07-27 19:01:55 UTC (rev 29964)
@@ -1 +0,0 @@
-debian/pyfiglet /usr/bin

Deleted: packages/pyfiglet/trunk/debian/manpages
===================================================================
--- packages/pyfiglet/trunk/debian/manpages	2014-07-27 18:46:51 UTC (rev 29963)
+++ packages/pyfiglet/trunk/debian/manpages	2014-07-27 19:01:55 UTC (rev 29964)
@@ -1 +0,0 @@
-doc/pyfiglet.1

Modified: packages/pyfiglet/trunk/debian/patches/debian-defaults.diff
===================================================================
--- packages/pyfiglet/trunk/debian/patches/debian-defaults.diff	2014-07-27 18:46:51 UTC (rev 29963)
+++ packages/pyfiglet/trunk/debian/patches/debian-defaults.diff	2014-07-27 19:01:55 UTC (rev 29964)
@@ -6,12 +6,12 @@
 
 --- a/pyfiglet/__init__.py
 +++ b/pyfiglet/__init__.py
-@@ -32,7 +32,7 @@
- Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
+@@ -34,7 +34,7 @@
  """
  
--DEFAULT_FONT='standard'
-+DEFAULT_FONT='future'
  
+-DEFAULT_FONT = 'standard'
++DEFAULT_FONT = 'future'
  
+ 
  def figlet_format(text, font=DEFAULT_FONT, **kwargs):

Modified: packages/pyfiglet/trunk/debian/patches/font-location.diff
===================================================================
--- packages/pyfiglet/trunk/debian/patches/font-location.diff	2014-07-27 18:46:51 UTC (rev 29963)
+++ packages/pyfiglet/trunk/debian/patches/font-location.diff	2014-07-27 19:01:55 UTC (rev 29964)
@@ -2,52 +2,73 @@
  Look in /usr/share/figlet rather than using pkg_resources to find fonts.
 Author: Stefano Rivera <stefanor at debian.org>
 Forwarded: not-needed
-Last-Update: 2011-05-29
+Last-Update: 2014-07-26
 
 --- a/pyfiglet/__init__.py
 +++ b/pyfiglet/__init__.py
 @@ -5,7 +5,7 @@
  """
  
- import os
+ from __future__ import print_function
 -import pkg_resources
 +import os.path
  import re
  import sys
  from optparse import OptionParser
-@@ -82,8 +82,8 @@
- 
+@@ -91,8 +91,8 @@
+         """
          for extension in ('tlf', 'flf'):
              fn = '%s.%s' % (font, extension)
 -            if pkg_resources.resource_exists('pyfiglet.fonts', fn):
--                self.data = pkg_resources.resource_string('pyfiglet.fonts', fn)
+-                data = pkg_resources.resource_string('pyfiglet.fonts', fn)
 +            if os.path.isfile(os.path.join('/usr/share/figlet', fn)):
-+                self.data = open(os.path.join('/usr/share/figlet', fn)).read()
-                 break
++                data = open(os.path.join('/usr/share/figlet', fn), 'rb').read()
+                 data = data.decode('UTF-8', 'replace')
+                 return data
          else:
-             raise FontNotFound(font)
-@@ -93,10 +93,10 @@
+@@ -102,14 +102,14 @@
+     def isValidFont(cls, font):
+         if not font.endswith(('.flf', '.tlf')):
+             return False
+-        f = pkg_resources.resource_stream('pyfiglet.fonts', font)
++        f = open(os.path.join('/usr/share/figlet', font), 'rb')
+         header = f.readline().decode('UTF-8', 'replace')
+         return cls.reMagicNumber.search(header)
+ 
      @classmethod
-     def getFonts(self):
+     def getFonts(cls):
          return [font.rsplit('.', 2)[0] for font
 -                in pkg_resources.resource_listdir('pyfiglet', 'fonts')
 +                in os.listdir('/usr/share/figlet')
-                 if font.endswith(('.flf', '.tlf'))
--                   and self.reMagicNumber.search(pkg_resources.resource_stream(
--                        'pyfiglet.fonts', font).readline())]
-+                   and self.reMagicNumber.search(open(os.path.join(
-+                        '/usr/share/figlet', font)).readline())]
+                 if cls.isValidFont(font)]
  
-     def loadFont(self):
-         """
+     @classmethod
 --- a/setup.py
 +++ b/setup.py
-@@ -8,7 +8,6 @@
-       author='Peter Waller (Thanks to Christopher Jones and Stefano Rivera)',
-       author_email='peter.waller at gmail.com',
-       url='https://github.com/pwaller/pyfiglet',
--      packages=['pyfiglet', 'pyfiglet.fonts'],
--      package_data={'pyfiglet.fonts' : ['*.flf']},
-+      packages=['pyfiglet'],
- )
+@@ -46,8 +46,7 @@
+     author='Peter Waller (Thanks to Christopher Jones and Stefano Rivera)',
+     author_email='peter.waller at gmail.com',
+     url='https://github.com/pwaller/pyfiglet',
+-    packages=['pyfiglet', 'pyfiglet.fonts'],
+-    package_data={'pyfiglet.fonts': ['*.flf']},
++    packages=['pyfiglet'],
+     entry_points={
+         'console_scripts': [
+             'pyfiglet = pyfiglet:main',
+--- a/pyfiglet/test.py
++++ b/pyfiglet/test.py
+@@ -39,11 +39,11 @@
  
+         outputPyfiglet = f.renderText('foo')
+ 
+-        fontpath = os.path.join('pyfiglet', 'fonts', font)
++        fontpath = os.path.join('/usr/share/figlet', font)
+         if os.path.isfile(fontpath + '.flf'):
+-            cmd = ('figlet', '-d', 'pyfiglet/fonts', '-f', font, 'foo')
++            cmd = ('figlet', '-d', '/usr/share/figlet', '-f', font, 'foo')
+         elif os.path.isfile(fontpath + '.tlf'):
+-            cmd = ('toilet', '-d', 'pyfiglet/fonts', '-f', font, 'foo')
++            cmd = ('toilet', '-d', '/usr/share/figlet', '-f', font, 'foo')
+         else:
+             raise Exception('Missing font file: '+fontpath)
+ 

Added: packages/pyfiglet/trunk/debian/patches/no-entry-points.diff
===================================================================
--- packages/pyfiglet/trunk/debian/patches/no-entry-points.diff	                        (rev 0)
+++ packages/pyfiglet/trunk/debian/patches/no-entry-points.diff	2014-07-27 19:01:55 UTC (rev 29964)
@@ -0,0 +1,18 @@
+Description: Don't install setuptools entry point scripts.
+ We have our own command line wrapper.
+Author: Stefano Rivera <stefanor at debian.org>
+Forwarded: not-needed
+Last-Update: 2014-07-27
+
+--- a/setup.py
++++ b/setup.py
+@@ -47,9 +47,4 @@
+     author_email='peter.waller at gmail.com',
+     url='https://github.com/pwaller/pyfiglet',
+     packages=['pyfiglet'],
+-    entry_points={
+-        'console_scripts': [
+-            'pyfiglet = pyfiglet:main',
+-        ],
+-    }
+ )

Modified: packages/pyfiglet/trunk/debian/patches/series
===================================================================
--- packages/pyfiglet/trunk/debian/patches/series	2014-07-27 18:46:51 UTC (rev 29963)
+++ packages/pyfiglet/trunk/debian/patches/series	2014-07-27 19:01:55 UTC (rev 29964)
@@ -1,2 +1,3 @@
 debian-defaults.diff
 font-location.diff
+no-entry-points.diff

Copied: packages/pyfiglet/trunk/debian/python-pyfiglet.docs (from rev 29946, packages/pyfiglet/trunk/debian/docs)
===================================================================
--- packages/pyfiglet/trunk/debian/python-pyfiglet.docs	                        (rev 0)
+++ packages/pyfiglet/trunk/debian/python-pyfiglet.docs	2014-07-27 19:01:55 UTC (rev 29964)
@@ -0,0 +1 @@
+README

Copied: packages/pyfiglet/trunk/debian/python3-pyfiglet.docs (from rev 29946, packages/pyfiglet/trunk/debian/docs)
===================================================================
--- packages/pyfiglet/trunk/debian/python3-pyfiglet.docs	                        (rev 0)
+++ packages/pyfiglet/trunk/debian/python3-pyfiglet.docs	2014-07-27 19:01:55 UTC (rev 29964)
@@ -0,0 +1 @@
+README

Copied: packages/pyfiglet/trunk/debian/python3-pyfiglet.install (from rev 29946, packages/pyfiglet/trunk/debian/install)
===================================================================
--- packages/pyfiglet/trunk/debian/python3-pyfiglet.install	                        (rev 0)
+++ packages/pyfiglet/trunk/debian/python3-pyfiglet.install	2014-07-27 19:01:55 UTC (rev 29964)
@@ -0,0 +1 @@
+debian/pyfiglet /usr/bin

Copied: packages/pyfiglet/trunk/debian/python3-pyfiglet.manpages (from rev 29946, packages/pyfiglet/trunk/debian/manpages)
===================================================================
--- packages/pyfiglet/trunk/debian/python3-pyfiglet.manpages	                        (rev 0)
+++ packages/pyfiglet/trunk/debian/python3-pyfiglet.manpages	2014-07-27 19:01:55 UTC (rev 29964)
@@ -0,0 +1 @@
+doc/pyfiglet.1

Modified: packages/pyfiglet/trunk/debian/rules
===================================================================
--- packages/pyfiglet/trunk/debian/rules	2014-07-27 18:46:51 UTC (rev 29963)
+++ packages/pyfiglet/trunk/debian/rules	2014-07-27 19:01:55 UTC (rev 29964)
@@ -1,20 +1,13 @@
 #!/usr/bin/make -f
 
+export PYBUILD_NAME=pyfiglet
+
 %:
-	dh $@ --with python2
+	dh $@ --with python2,python3 --buildsystem pybuild
 
-override_dh_auto_install:
-	dh_auto_install
-	find debian/python-pyfiglet -name SOURCES.txt -delete
+override_dh_auto_test:
+	PYBUILD_SYSTEM=custom \
+		PYBUILD_TEST_ARGS="{interpreter} -m pyfiglet.test" dh_auto_test
 
 get-packaged-orig-source:
-	set -ex; \
-	VER=$(shell dpkg-parsechangelog | sed -rne 's,^Version: ([^+]+).*,\1,p'); \
-	uscan --noconf --download-current-version --destdir=. --rename; \
-	mkdir pyfiglet-$$VER+dfsg.orig; \
-	tar -x --exclude=pyfiglet/fonts --exclude=doc/figfont.txt --exclude=.gitignore \
-		--strip-component=1 -C pyfiglet-$$VER+dfsg.orig -f pyfiglet_$$VER.orig.tar.gz; \
-	rm pyfiglet_$$VER.orig.tar.gz; \
-	GZIP=--best tar -cz --owner root --group root --mode a+rX \
-		-f "pyfiglet_$$VER+dfsg.orig.tar.gz" "pyfiglet-$$VER+dfsg.orig"; \
-	rm -rf "pyfiglet-$$VER+dfsg.orig"
+	uscan --noconf --download-current-version --destdir=. --rename --repack

Modified: packages/pyfiglet/trunk/debian/tests/control
===================================================================
--- packages/pyfiglet/trunk/debian/tests/control	2014-07-27 18:46:51 UTC (rev 29963)
+++ packages/pyfiglet/trunk/debian/tests/control	2014-07-27 19:01:55 UTC (rev 29964)
@@ -1,2 +1,11 @@
 Tests: smoketest
-Depends: @, toilet-fonts
+Depends: python-pyfiglet, toilet-fonts
+
+Tests: smoketest3
+Depends: python3-pyfiglet, toilet-fonts
+
+Tests: suite
+Depends: python-all, python-pyfiglet, toilet
+
+Tests: suite3
+Depends: python3-all, python3-pyfiglet, toilet

Modified: packages/pyfiglet/trunk/debian/tests/smoketest
===================================================================
--- packages/pyfiglet/trunk/debian/tests/smoketest	2014-07-27 18:46:51 UTC (rev 29963)
+++ packages/pyfiglet/trunk/debian/tests/smoketest	2014-07-27 19:01:55 UTC (rev 29964)
@@ -3,6 +3,6 @@
 
 cd "$ADTTMP"
 
-pyfiglet --help
-pyfiglet hello there
-pyfiglet -f letter haai
+python -m pyfiglet --help
+python -m pyfiglet hello there
+python -m pyfiglet -f letter haai

Copied: packages/pyfiglet/trunk/debian/tests/smoketest3 (from rev 29946, packages/pyfiglet/trunk/debian/tests/smoketest)
===================================================================
--- packages/pyfiglet/trunk/debian/tests/smoketest3	                        (rev 0)
+++ packages/pyfiglet/trunk/debian/tests/smoketest3	2014-07-27 19:01:55 UTC (rev 29964)
@@ -0,0 +1,8 @@
+#!/bin/sh
+set -efu
+
+cd "$ADTTMP"
+
+pyfiglet --help
+pyfiglet hello there
+pyfiglet -f letter haai

Added: packages/pyfiglet/trunk/debian/tests/suite
===================================================================
--- packages/pyfiglet/trunk/debian/tests/suite	                        (rev 0)
+++ packages/pyfiglet/trunk/debian/tests/suite	2014-07-27 19:01:55 UTC (rev 29964)
@@ -0,0 +1,8 @@
+#!/bin/sh
+set -efu
+
+cd "$ADTTMP"
+
+for py in $(pyversions --supported); do
+	$py -m pyfiglet.test
+done


Property changes on: packages/pyfiglet/trunk/debian/tests/suite
___________________________________________________________________
Added: svn:executable
   + *

Added: packages/pyfiglet/trunk/debian/tests/suite3
===================================================================
--- packages/pyfiglet/trunk/debian/tests/suite3	                        (rev 0)
+++ packages/pyfiglet/trunk/debian/tests/suite3	2014-07-27 19:01:55 UTC (rev 29964)
@@ -0,0 +1,8 @@
+#!/bin/sh
+set -efu
+
+cd "$ADTTMP"
+
+for py in $(py3versions --supported); do
+	$py -m pyfiglet.test
+done


Property changes on: packages/pyfiglet/trunk/debian/tests/suite3
___________________________________________________________________
Added: svn:executable
   + *

Modified: packages/pyfiglet/trunk/debian/watch
===================================================================
--- packages/pyfiglet/trunk/debian/watch	2014-07-27 18:46:51 UTC (rev 29963)
+++ packages/pyfiglet/trunk/debian/watch	2014-07-27 19:01:55 UTC (rev 29964)
@@ -1,5 +1,4 @@
 version=3
 
-opts=dversionmangle=s/\+dfsg// \
-http://githubredir.debian.net/github/pwaller/pyfiglet/(.*).tar.gz \
-debian
+opts=uversionmangle=s/$/\+dfsg/ \
+http://githubredir.debian.net/github/pwaller/pyfiglet/(.*).tar.gz




More information about the Python-modules-commits mailing list