debian/0000755000000000000000000000000012313522167007170 5ustar debian/compat0000644000000000000000000000000212310044463010361 0ustar 9 debian/python3-coverage.install0000644000000000000000000000012212310044463013743 0ustar usr/bin/python3*-coverage resources/* usr/share/python3-coverage usr/lib/python3/ debian/rules0000755000000000000000000001734112310044463010251 0ustar #! /usr/bin/make -f # # debian/rules # Part of Debian ‘python-coverage’ package. # # Copyright © 2010–2014 Ben Finney # This is free software; you may copy, modify and/or distribute this work # under the terms of the BSD 2-clause license. # No warranty expressed or implied. # See the file ‘coverage/__init__.py’ for details. SOURCE_PACKAGE_NAME = python-coverage PYTHON2_PACKAGE_NAME = python-coverage PYTHON3_PACKAGE_NAME = python3-coverage python2_debug_package_name = ${PYTHON2_PACKAGE_NAME}-dbg python3_debug_package_name = ${PYTHON3_PACKAGE_NAME}-dbg package_working_root = debian package_install_root = ${package_working_root}/tmp package_install_bin_dir = ${package_install_root}/usr/bin PYTHON2_VERSIONS = $(shell pyversions -vr) PYTHON3_VERSIONS = $(shell py3versions -vr) PYTHON_VERSIONS = ${PYTHON2_VERSIONS} ${PYTHON3_VERSIONS} # For some ‘/usr/bin/*-coverage’ programs (and not others), we need the # default, not current, Python interpreter in the shebang. The ‘dh-python’ # helpers can re-write shebangs, but they are too eager, converting every # program's shebang without allowing us to specify different interpreters # per program. We resort to ‘sed’. python3_program = ${package_install_bin_dir}/python3-coverage shebang_line_regex = ^\#!.*$$ python3_shebang_interpreter = /usr/bin/python3 debug_object_exclude += _d.so # Unfortunately, ‘dh_install --exclude’ requires a substring, and a glob # wildcard will *not* work. So we need to specify the exact substring for # the Python 3 debug module filenames. python3_objcode_versions = $(shell \ printf "%s\n" ${PYTHON3_VERSIONS} | sed -e 's/\.//g') DEB_HOST_MULTIARCH = $(shell dpkg-architecture -qDEB_HOST_MULTIARCH) debug_object_exclude += $(foreach ver,${python3_objcode_versions}, \ .cpython-${ver}dm-${DEB_HOST_MULTIARCH}.so) DISTRIBUTION_NAME = coverage egg_info_dir = ${DISTRIBUTION_NAME}.egg-info GENERATED_FILES += ${egg_info_dir}/PKG-INFO ${egg_info_dir}/SOURCES.txt HTMLFILES_DIR = ${DISTRIBUTION_NAME}/htmlfiles htmlfiles_dirname = $(notdir ${HTMLFILES_DIR}) bundled_libraries += $(addprefix ${HTMLFILES_DIR}/, \ jquery.hotkeys.js \ jquery.isonscreen.js \ ) RESOURCES_DIR = resources package_install_resources_root = ${package_install_root}/${RESOURCES_DIR} DOCUMENTATION_DIR = doc MANPAGE_SUFFIX = .1 manpage_tempfile_suffix = ${MANPAGE_SUFFIX}.tmp default_manpage_name = python-coverage${MANPAGE_SUFFIX} python2_manpage_names = $(addsuffix ${MANPAGE_SUFFIX}, \ $(notdir $(wildcard ${package_install_bin_dir}/python2*-coverage))) python3_manpage_names = $(addsuffix ${MANPAGE_SUFFIX}, \ $(notdir $(wildcard ${package_install_bin_dir}/python3*-coverage))) versioned_manpage_names = ${python2_manpage_names} ${python3_manpage_names} versioned_manpage_paths = $(addprefix ${DOCUMENTATION_DIR}/, \ ${versioned_manpage_names}) GENERATED_FILES += ${DOCUMENTATION_DIR}/*${MANPAGE_SUFFIX} GENERATED_FILES += ${DOCUMENTATION_DIR}/*${manpage_tempfile_suffix} INSTALL = install # Send HTTP traffic to the “discard” service during packaging actions. export http_proxy = http://127.0.1.1:9/ export https_proxy = ${http_proxy} RST_SUFFIX = .txt RST2MAN = rst2man ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS))) .PHONY: test-python% test-python%: python$* setup.py test -vv .PHONY: override_dh_auto_test override_dh_auto_test: $(foreach pyversion,${PYTHON_VERSIONS},$(pyversion:%=test-python%)) endif .PHONY: build build: build-arch build-indep build: remove-bundled-libraries build: ${MANPAGES} manpage-symlinks dh $@ --with python2,python3 .PHONY: build-arch build-arch: build-stamp dh $@ --with python2,python3 .PHONY: build-indep build-indep: build-stamp dh $@ --with python2,python3 build-stamp: touch $@ .PHONY: build-python% build-python%: python$*-dbg setup.py build python$* setup.py build .PHONY: remove-bundled-libraries remove-bundled-libraries: $(RM) ${bundled_libraries} .PHONY: manpage-symlinks manpage-symlinks: ${versioned_manpage_paths} ${DOCUMENTATION_DIR}/${default_manpage_name}: ${package_working_root}/${default_manpage_name} $(INSTALL) --mode=u=rw,go=r "$<" "$@" ${DOCUMENTATION_DIR}/%${MANPAGE_SUFFIX}: ${DOCUMENTATION_DIR}/${default_manpage_name} ln -s ${default_manpage_name} "$@" %.1: %.1${RST_SUFFIX} $(RST2MAN) $< > "$@".tmp cat debian/manpage_encoding_declaration.UTF-8 "$@".tmp > "$@" .PHONY: clean clean: dh $@ --with python2,python3 $(RM) -r ${GENERATED_FILES} .PHONY: override_dh_auto_clean override_dh_auto_clean: dh_auto_clean $(RM) -r build $(RM) -r ${egg_info_dir} # Policy §4.9 strongly recommends the ‘get-orig-source’ target: # “This target is optional, but providing it if possible is a good idea.” .PHONY: get-orig-source get-orig-source: http_proxy = get-orig-source: makefile_dir = $(abspath $(dir $(firstword ${MAKEFILE_LIST}))) get-orig-source: package_dir = $(abspath $(dir ${makefile_dir})) get-orig-source: uscan --noconf --verbose \ --force-download --download-current-version \ --rename \ --destdir=$(CURDIR) \ --check-dirname-level=0 ${package_dir} .PHONY: install install: build dh $@ --with python2,python3 \ --package ${python2_debug_package_name} \ --package ${python3_debug_package_name} dh $@ --with python2,python3 \ $(foreach exclude_part,${debug_object_exclude}, \ --exclude ${exclude_part}) ${package_install_resources_root}: $(INSTALL) -d "$@" ${package_install_resources_root}/${htmlfiles_dirname}: ${HTMLFILES_DIR} ${package_install_resources_root} $(INSTALL) -d "$@" $(INSTALL) --mode=u=rw,go=r "$<"/* "$@" .PHONY: install-resource-files install-resource-files: ${package_install_resources_root} install-resource-files: ${package_install_resources_root}/${htmlfiles_dirname} .PHONY: install-python% install-python%: python_version_major = $(firstword $(subst ., ,$*)) install-python%: python$*-dbg setup.py install --install-layout=deb \ --root=$(CURDIR)/${package_install_root} python$* setup.py install --install-layout=deb \ --root=$(CURDIR)/${package_install_root} if [ "${python_version_major}" = "3" ] ; then \ sed -i -e '1 s,${shebang_line_regex},#! ${python3_shebang_interpreter},' \ "${python3_program}" ; \ fi .PHONY: binary-indep binary-indep: build install .PHONY: binary-arch binary-arch: build install dh $@ --with python2,python3 .PHONY: binary binary: build binary-indep binary-arch .PHONY: override_dh_strip override_dh_strip: dh_strip --package=${PYTHON2_PACKAGE_NAME} --dbg-package=${python2_debug_package_name} dh_strip --package=${PYTHON3_PACKAGE_NAME} --dbg-package=${python3_debug_package_name} .PHONY: override_dh_auto_build override_dh_auto_build: $(foreach pyversion,${PYTHON_VERSIONS},$(pyversion:%=build-python%)) override_dh_auto_build: dh_auto_build .PHONY: override_dh_auto_install override_dh_auto_install: $(foreach pyversion,${PYTHON_VERSIONS},$(pyversion:%=install-python%)) override_dh_auto_install: install-resource-files dh_auto_install .PHONY: override_dh_link override_dh_link: dh_link for pyversion in ${PYTHON2_VERSIONS} ; do \ dh_link \ --package=${PYTHON2_PACKAGE_NAME} \ usr/share/${PYTHON2_PACKAGE_NAME}/${htmlfiles_dirname} \ usr/lib/python$${pyversion}/dist-packages/${HTMLFILES_DIR} ; \ done .PHONY: override_dh_installchangelogs override_dh_installchangelogs: dh_installchangelogs CHANGES.txt .PHONY: override_dh_installdocs override_dh_installdocs: dh_installdocs \ --package=${PYTHON2_PACKAGE_NAME} \ --package=${python2_debug_package_name} \ --link-doc=${PYTHON2_PACKAGE_NAME} dh_installdocs \ --package=${PYTHON3_PACKAGE_NAME} \ --package=${python3_debug_package_name} \ --link-doc=${PYTHON3_PACKAGE_NAME} # Local variables: # mode: makefile # coding: utf-8 # End: # vim: filetype=make fileencoding=utf-8 : debian/copyright0000644000000000000000000000404712310044463011123 0ustar Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: coverage Upstream-Contact: Ned Batchelder Source: http://pypi.python.org/pypi/coverage The pristine upstream source contains obfuscated files, that are thereby not appropriate for use as source files. This violates DFSG §2. . The ‘debian/repack’ program removes those files to create the Debian upstream source tarball. Files: * Copyright: © 2004–2013 Ned Batchelder © 2001 Gareth Rees License: BSD-2-clause Files: debian/* Copyright: © 2008–2014 Ben Finney © 2007–2008 Lars Wirzenius License: BSD-2-clause License: BSD-2-clause Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: . 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. . 2. 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. . 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 HOLDERS AND 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/python3-coverage.preinst0000644000000000000000000000177412310044463013777 0ustar #! /bin/sh # Pre-install script for ‘python3-coverage’. # # Manpage: ‘dh_installdeb(1)’ set -e # Summary of ways this script can be called: # * install # * install # * upgrade # * abort-upgrade # For details, see the Debian Policy §6.5 in the ‘debian-policy’ package # or on the web at . action="$1" case "$action" in upgrade) htmlfiles_dir="/usr/lib/python3/dist-packages/coverage/htmlfiles" if [ -d "$htmlfiles_dir" ] && [ ! -L "$htmlfiles_dir" ] ; then # The ‘htmlfiles’ location should be platform-independent. # The new package will replace the directory with a symlink. rm -rf "$htmlfiles_dir" fi ;; install|abort-upgrade) ;; *) printf "preinst called with unknown action ‘%s’\n" "$action" >&2 exit 1 ;; esac #DEBHELPER# debian/source/0000755000000000000000000000000012310044647010467 5ustar debian/source/format0000644000000000000000000000001412310044463011671 0ustar 3.0 (quilt) debian/python-coverage-dbg.install0000644000000000000000000000006412310044463014417 0ustar usr/lib/python2.[1-7]/dist-packages/coverage/*_d.so debian/python3-coverage.links0000644000000000000000000000012612310044463013421 0ustar usr/share/python3-coverage/htmlfiles usr/lib/python3/dist-packages/coverage/htmlfiles debian/python-coverage.manpages0000644000000000000000000000005612310044463014013 0ustar doc/python-coverage.1 doc/python2*-coverage.1 debian/python-coverage.install0000644000000000000000000000015712310044463013670 0ustar usr/bin/python-coverage usr/bin/python2*-coverage resources/* usr/share/python-coverage usr/lib/python2.[1-7]/ debian/python3-coverage-dbg.postinst0000644000000000000000000000310212310044463014713 0ustar #! /bin/sh # Post-install script for ‘python3-coverage-dbg’. # # Manpage: ‘dh_installdeb(1)’ set -e # Summary of ways this script can be called: # * configure # * abort-upgrade # * abort-remove in-favour # # * abort-remove # * abort-deconfigure in-favour # # [removing ] # For details, see the Debian Policy §6.5 in the ‘debian-policy’ package # or on the web at . action="$1" main_package_name=python3-coverage debug_package_name=${main_package_name}-dbg doc_root_dir="/usr/share/doc" main_doc_dir="${doc_root_dir}/${main_package_name}" debug_doc_dir="${doc_root_dir}/${debug_package_name}" case "$action" in configure) most_recent_version="$2" if dpkg --compare-versions "$most_recent_version" lt-nl "3.6-1"; then # Replace debug package doc directory with symlink to # main doc directory. if [ ! -L "$debug_doc_dir" ] && [ -d "$debug_doc_dir" ]; then if rmdir "$debug_doc_dir" 2>/dev/null; then ln -sf $main_package_name "$debug_doc_dir" fi fi fi ;; abort-upgrade|abort-remove|abort-deconfigure) ;; *) printf "postinst called with unknown action ‘%s’\n" "$action" >&2 exit 1 ;; esac #DEBHELPER# exit 0 debian/watch0000644000000000000000000000056412310044463010221 0ustar # debian/watch # Debian uscan file for ‘python-coverage’ package. # Manpage: ‘uscan(1)’ # Compulsory line, this is a version 3 file. version=3 # Current version from Cheese Shop. opts="uversionmangle=s/(\d)([a-z]\d+)$/$1~$2/,dversionmangle=s/\+dfsg\.\d+$//" \ http://pypi.python.org/packages/source/c/coverage/coverage-(.+).tar.gz \ debian debian/repack debian/patches/0000755000000000000000000000000012310044647010616 5ustar debian/patches/series0000644000000000000000000000012212310044463012022 0ustar 01.omit-resource-files-from-distutils-setup.patch 02.rename-public-programs.patch debian/patches/02.rename-public-programs.patch0000644000000000000000000000315612310044463016433 0ustar Description: Rename public programs to be clear what they're for. . The upstream choice of ‘coverage’ is too broad a command name for a Python-specific programmer tool. . Created to work with “entry points” feature of Python's Distribute. Bug: https://bitbucket.org/ned/coveragepy/issue/272/ Author: Ben Finney Last-Update: 2013-10-16 --- old/setup.py 2013-10-07 07:40:00.000000000 +1100 +++ new/setup.py 2013-10-08 10:21:00.000000000 +1100 @@ -1,3 +1,4 @@ +# coding: utf-8 # setup.py for coverage.py """Code coverage measurement for Python @@ -71,13 +72,15 @@ devstat = "5 - Production/Stable" classifier_list.append("Development Status :: " + devstat) -# Install a script as "coverage", and as "coverage[23]", and as -# "coverage-2.7" (or whatever). +# Install a default ‘python-coverage’ program, and versioned as +# ‘python2.7-coverage’, ‘python3-coverage’, etc. scripts = [ - 'coverage = coverage:main', - 'coverage%d = coverage:main' % sys.version_info[:1], - 'coverage-%d.%d = coverage:main' % sys.version_info[:2], - ] + "python-coverage = coverage:main", + "python{version[0]}-coverage = coverage:main".format( + version=sys.version_info), + "python{version[0]}.{version[1]}-coverage = coverage:main".format( + version=sys.version_info), + ] # Create the keyword arguments for setup() Local variables: coding: utf-8 mode: diff time-stamp-format: "%:y-%02m-%02d" time-stamp-start: "^Last-Update:[ ]+" time-stamp-end: "$" time-stamp-line-limit: 20 End: vim: fileencoding=utf-8 filetype=diff : debian/patches/01.omit-resource-files-from-distutils-setup.patch0000644000000000000000000000244312310044463022073 0ustar Description: Omit the resource data files from Python packaging config. . Created to avoid Python's Distutils insistence on install of arch-independent ‘package_data’ files in ‘/usr/lib/…’. This is a violation of FHS, and these files should instead go to ‘/usr/share/…’. Bug-Debian: http://bugs.debian.org/721676 Author: Ben Finney Last-Update: 2013-09-08 diff -ruN old/MANIFEST.in new/MANIFEST.in --- old/MANIFEST.in 2012-11-18 15:32:29.000000000 +1100 +++ new/MANIFEST.in 2013-09-08 17:09:54.683655749 +1000 @@ -1,5 +1,4 @@ # MANIFEST.in file for coverage.py -recursive-include coverage/htmlfiles * recursive-include coverage/fullcoverage * include coverage.egg-info/*.* diff -ruN old/setup.py new/setup.py --- old/setup.py 2013-01-06 10:00:22.000000000 +1100 +++ new/setup.py 2013-09-08 18:09:04.506127384 +1000 @@ -88,12 +88,6 @@ packages = [ 'coverage', ], - - package_data = { - 'coverage': [ - 'htmlfiles/*.*', - ] - }, entry_points = {'console_scripts': scripts}, Local variables: coding: utf-8 mode: diff time-stamp-format: "%:y-%02m-%02d" time-stamp-start: "^Last-Update:[ ]+" time-stamp-end: "$" time-stamp-line-limit: 20 End: vim: fileencoding=utf-8 filetype=diff : debian/python3-coverage.manpages0000644000000000000000000000003012310044463014066 0ustar doc/python3*-coverage.1 debian/control0000644000000000000000000000641212310044463010571 0ustar Source: python-coverage Maintainer: Ubuntu Developers XSBC-Original-Maintainer: Ben Finney Section: python Priority: optional Standards-Version: 3.9.5 Build-Depends: debhelper (>= 9~), python-docutils, python-setuptools, python-all-dev (>= 2.6.6-3~), python-all-dbg, python (>= 2.6.6-3~), python3-setuptools, python3-all-dev, python3-all-dbg, python3 Homepage: http://nedbatchelder.com/code/coverage/ VCS-bzr: http://anonscm.debian.org/bzr/collab-maint/python-coverage/python-coverage.debian/ VCS-Browser: http://anonscm.debian.org/loggerhead/collab-maint/python-coverage/python-coverage.debian/ X-Python-Version: >= 2.6 X-Python3-Version: >= 3.2 Package: python-coverage Architecture: any Depends: python-pkg-resources, ${python:Depends}, ${shlibs:Depends}, ${misc:Depends} Recommends: libjs-jquery-hotkeys, libjs-jquery-isonscreen, libjs-jquery-tablesorter, libjs-jquery Description: code coverage tool for Python 2 The ‘coverage’ library measures which parts (statements) of a Python program are executed while it is run. This is useful for testing: those parts of a program that are not executed by the tests have not been tested. . This package contains the Python version 2 ‘coverage’ library, and the ‘python-coverage’ program to perform and report coverage tests. Package: python3-coverage Architecture: any Depends: python3-pkg-resources, ${python3:Depends}, ${shlibs:Depends}, ${misc:Depends} Recommends: libjs-jquery-hotkeys, libjs-jquery-isonscreen, libjs-jquery-tablesorter, libjs-jquery Description: code coverage tool for Python 3 The ‘coverage’ library measures which parts (statements) of a Python program are executed while it is run. This is useful for testing: those parts of a program that are not executed by the tests have not been tested. . This package contains the Python version 3 ‘coverage’ library, and the ‘python3-coverage’ program to perform and report coverage tests. Package: python-coverage-dbg Architecture: any Section: debug Priority: extra Depends: python-coverage (= ${binary:Version}), ${shlibs:Depends}, ${misc:Depends} Recommends: python-dbg Description: code coverage tool for Python 2 – debug library The ‘coverage’ library measures which parts (statements) of a Python program are executed while it is run. This is useful for testing: those parts of a program that are not executed by the tests have not been tested. . This package contains the debugging symbols and debug build for the C extension libraries in ‘python-coverage’. Package: python3-coverage-dbg Architecture: any Section: debug Priority: extra Depends: python3-coverage (= ${binary:Version}), ${shlibs:Depends}, ${misc:Depends} Recommends: python3-dbg Description: code coverage tool for Python 3 – debug library The ‘coverage’ library measures which parts (statements) of a Python program are executed while it is run. This is useful for testing: those parts of a program that are not executed by the tests have not been tested. . This package contains the debugging symbols and debug build for the C extension libraries in ‘python3-coverage’. debian/bzr-builddeb.conf0000644000000000000000000000015612310044463012401 0ustar [builddeb] # Build source package by merging this working tree with upstream source. merge = True [BUILDDEB] debian/python3-coverage.docs0000644000000000000000000000002512310044463013227 0ustar debian/README.Debian debian/README.Debian0000644000000000000000000000216112310044463011224 0ustar =================================== Python “coverage” library in Debian =================================== :Author: Ben Finney Packages ======== The Python `“coverage” library`_ is packaged in Debian separately for each Python version in Debian: * `python-coverage` for Python 2. * `python3-coverage` for Python 3. .. _“coverage” library: https://pypi.python.org/pypi/coverage/ Command-line programs ===================== The Debian “python-coverage” source package provides the command-line program by the following names: * For Debian's default Python version, the program `/usr/bin/python-coverage`. * For Debian's default Python 2 and Python 3, the programs `/usr/bin/python2-coverage` and `/usr/bin/python3-coverage`. * For other Python versions, the program `/usr/bin/pythonN.M-coverage` (where “N.M” is the major and minor Python version, e.g. `/usr/bin/python3.2-coverage`). Man pages are in section 1 under the corresponding names. .. Local variables: coding: utf-8 mode: text mode: rst End: vim: fileencoding=utf-8 fileformat=rst : debian/python-coverage.1.txt0000644000000000000000000001270712310044463013204 0ustar ================= python-coverage ================= ------------------------------------------------- measure code coverage of Python program execution ------------------------------------------------- :Author: |author| :Date: 2013-10-07 :Copyright: BSD license, attribution and disclaimer required. :Manual section: 1 :Manual group: Coverage .. |command| replace:: **python-coverage** SYNOPSIS ======== | |command| `command` [ `option` ... ] | |command| **help** [ `command` ] | |command| **help** **classic** DESCRIPTION =========== |command| executes a Python program, measures which of its statements are executed and which are not, and reports these coverage measurements. COMMAND OVERVIEW ================ |command| **annotate** Annotate source files with execution information. |command| **combine** Combine a number of data files. |command| **erase** Erase previously collected coverage data. |command| **help** Get help on using coverage.py. |command| **html** Create an HTML report. |command| **report** Report coverage stats on modules. |command| **run** Run a Python program and measure code execution. |command| **xml** Create an XML report of coverage results. GLOBAL OPTIONS ============== **--help**, **-h** Describe how to use Coverage, in general or a command. **--rcfile** `RCFILE` Specify configuration file `RCFILE`. Defaults to ``.coveragerc``. **--omit** `PATTERN` ... Omit files when their filename matches one of these PATTERNs. Usually needs quoting on the command line. **--include** `PATTERN` ... Include files only when their filename path matches one of these PATTERNs. Usually needs quoting on the command line. COMMAND REFERENCE ================= **annotate** Options: \-d `DIR`, --directory `DIR` Write the output files to DIR. \-i, --ignore-errors Ignore errors while reading source files. **combine** Combine data from multiple coverage files collected with ``run -p``. The combined results are written to a single file representing the union of the data. **erase** Erase previously collected coverage data. **help** [ `command` ] Describe how to use Coverage. **help** **classic** Describe help on older command syntax. **html** [ `option` ... ] [ `MODULE` ... ] Create an HTML report of the coverage of each `MODULE` file. Each file gets its own page, with the source decorated to show executed, excluded, and missed lines. Options: \-d `DIR`, --directory `DIR` Write the output files to `DIR`. \--title `TITLE` Use the text string `TITLE` as the title on the HTML. \--fail-under `MIN` Exit with a status of 2 if the total coverage is less than `MIN`. \-i, --ignore-errors Ignore errors while reading source files. **report** [ `option` ... ] [ `MODULE` ... ] Report coverage statistics on each `MODULE`. Options: \--fail-under `MIN` Exit with a status of 2 if the total coverage is less than `MIN`. \-i, --ignore-errors Ignore errors while reading source files. \-m, --show-missing Show line numbers of statements in each module that weren't executed. **run** [ `options` ... ] `PROGRAMFILE` [ `program_options` ] Run a Python program `PROGRAMFILE`, measuring code execution. Options: \-a, --append Append coverage data to .coverage, otherwise it is started clean with each run. \--branch Measure branch coverage in addition to statement coverage. \--debug `DEBUGOPT`,... Debug options `DEBUGOPT`, separated by commas \-L, --pylib Measure coverage even inside the Python installed library, which isn't done by default. \-p, --parallel-mode Append the machine name, process id and random number to the ``.coverage`` data file name to simplify collecting data from many processes. \--timid Use a simpler but slower trace method. Try this if you get seemingly impossible results! \--source `SOURCE` ... A list of packages or directories of code to be measured. **xml** [ `options` ... ] [ `MODULES` ... ] Generate an XML report of coverage results on each `MODULE`. Options: \--fail-under `MIN` Exit with a status of 2 if the total coverage is less than `MIN`. \-i, --ignore-errors Ignore errors while reading source files. \-o `OUTFILE` Write the XML report to `OUTFILE`. Defaults to ``coverage.xml``. ENVIRONMENT VARIABLES ===================== COVERAGE_FILE Path to the file where coverage measurements are collected to and reported from. Default: ``.coverage`` in the current working directory. COVERAGE_OPTIONS Space-separated series of command-line options to |command|. Default: empty. HISTORY ======= The |command| command is a Python program which calls the ``coverage`` Python library to do all the work. The library was originally developed by Gareth Rees, and is now developed by Ned Batchelder. This manual page was written by |author|. .. |author| replace:: |authorname| |authoremail| .. |authorname| replace:: Ben Finney .. |authoremail| replace:: .. Local variables: mode: rst coding: utf-8 time-stamp-format: "%:y-%02m-%02d" time-stamp-start: "^:Date:[ ]+" time-stamp-end: "$" time-stamp-line-limit: 20 End: vim: filetype=rst fileencoding=utf-8 : debian/python-coverage-dbg.postinst0000644000000000000000000000310012310044463014626 0ustar #! /bin/sh # Post-install script for ‘python-coverage-dbg’. # # Manpage: ‘dh_installdeb(1)’ set -e # Summary of ways this script can be called: # * configure # * abort-upgrade # * abort-remove in-favour # # * abort-remove # * abort-deconfigure in-favour # # [removing ] # For details, see the Debian Policy §6.5 in the ‘debian-policy’ package # or on the web at . action="$1" main_package_name=python-coverage debug_package_name=${main_package_name}-dbg doc_root_dir="/usr/share/doc" main_doc_dir="${doc_root_dir}/${main_package_name}" debug_doc_dir="${doc_root_dir}/${debug_package_name}" case "$action" in configure) most_recent_version="$2" if dpkg --compare-versions "$most_recent_version" lt-nl "3.6-1"; then # Replace debug package doc directory with symlink to # main doc directory. if [ ! -L "$debug_doc_dir" ] && [ -d "$debug_doc_dir" ]; then if rmdir "$debug_doc_dir" 2>/dev/null; then ln -sf $main_package_name "$debug_doc_dir" fi fi fi ;; abort-upgrade|abort-remove|abort-deconfigure) ;; *) printf "postinst called with unknown action ‘%s’\n" "$action" >&2 exit 1 ;; esac #DEBHELPER# exit 0 debian/changelog0000644000000000000000000003367312313521702011050 0ustar python-coverage (3.7.1+dfsg.1-1ubuntu2) trusty; urgency=medium * No-change rebuild to drop support for Python 3.3. -- Matthias Klose Sun, 23 Mar 2014 10:04:23 +0100 python-coverage (3.7.1+dfsg.1-1ubuntu1) trusty; urgency=medium * Merge with Debian unstable, remaining change: - Add python3-coverage.preinst to correctly handle upgrades from previous releases. -- Dmitry Shachnev Fri, 07 Mar 2014 09:26:38 +0400 python-coverage (3.7.1+dfsg.1-1) unstable; urgency=medium * The “Ziauddin Yousafzai” release. * Urgency “medium” because we fix a bug of severity “serious”. * New upstream version. (Closes: bug#735359) * debian/patches/: + Patches incorporated upstream: * 02.use-system-ecmascript-libraries.patch Remaining patch files re-sequenced contiguously. + Add editor hints to patch files. * debian/repack: + Correct quoting of parameters (quote parameters used as filesystem entry names, don't quote parameters used as numbers). * debian/rules: + Explicitly replace shebang for programs needing default Python interpreter (Closes: bug#736121). + Correct generation of Python version strings for object code filenames (Closes: bug#740053). Thanks to Dmitry Shachnev for the bug report and patch. -- Ben Finney Wed, 05 Mar 2014 13:14:27 +1100 python-coverage (3.7+dfsg.1-4ubuntu2) trusty; urgency=medium * Build for python 3.4. -- Matthias Klose Wed, 19 Feb 2014 20:37:07 +0100 python-coverage (3.7+dfsg.1-4ubuntu1) trusty; urgency=medium * Add python3-coverage.preinst (based on existing python-coverage.preinst) to correctly handle upgrades from previous releases. Previously /usr/lib/python3/dist-packages/coverage/htmlfiles was a directory, now it is a symbolic link (see Debian #734850). -- Dmitry Shachnev Mon, 20 Jan 2014 19:08:47 +0400 python-coverage (3.7+dfsg.1-4) unstable; urgency=medium * The “Thorpekai Yousafzai” release. * Urgency “medium” because we fix a bug of severity “serious”. * debian/python3-coverage-dbg.install, debian/rules: + Correct file glob for excluding Python 3 debug symbols files. (Closes: bug#734853, thanks to Dmitry Shachnev for help) * debian/control: + Conform to “Standards-Version: 3.9.5”. No additional changes required. * debian/rules, debian/source.lintian-overrides: + Add ‘get-orig-source’ target (as recommended by Policy §4.9). + Remove Lintian override, now satisfied. * debian/repack: + Pack the tarball according to recommendations in Developer's Reference §6.7.8.2. * debian/bzr-builddeb.conf: + Add this package's configuration for ‘bzr builddeb’. -- Ben Finney Mon, 13 Jan 2014 14:51:52 +1100 python-coverage (3.7+dfsg.1-3) unstable; urgency=low * The “Gul Makai” release. * debian/rules, debian/*-dbg.install: + Build and install Python debug build of extension module. (Closes: bug#728548) * debian/control: + Update description for debug packages. -- Ben Finney Sun, 10 Nov 2013 17:25:29 +1100 python-coverage (3.7+dfsg.1-2) unstable; urgency=medium * The “Malala Yousafzai” release. * debian/rules: + Correct creation of version-specific resource directory symlink. (Closes: bug#727711) * debian/*.{pre,post}inst: + Make parameter handling more explicit. -- Ben Finney Tue, 29 Oct 2013 09:13:11 +1100 python-coverage (3.7+dfsg.1-1) unstable; urgency=low [ Piotr Ożarowski ] * debian/*.install: + Install files separately for Python 2 and Python 3 packages. [ Ben Finney ] * New upstream version (Closes: bug#635476). * debian/control: + Conform to ‘Standards-Version: 3.9.4’. * Remove obsolete field ‘DM-Upload-Allowed’. * debian/rules, debian/control: + Build binary packages for both Python 2 and Python 3. (Closes: bug#690575) + Remove more bundled ECMAScript libraries, declare dependencies on their Debian packages instead. + Demote ECMAScript dependencies (for HTML reports) to “Recommends”. * debian/rules, debian/*-dbg.postinst, debian/*.install: + Use main package doc directory (via symlink) for debug package. * debian/rules, debian/*.install, debian/*.links, debian/*.manpages: + Separate programs and manpages for Python 2 and Python 3. + Generate manpage from reStructuredText source. + Update the manpage document with current Coverage behaviour. (Closes: bug#496002) + Use main manpage for each versioned command. * debian/rules, debian/*.install, debian/*.links, debian/*.preinst: + Remove an existing platform-specific ‘htmlfiles’ directory; this package will create it as a symlink to the platform-independent location. + Install resource data files as platform-independent files. (Closes: bug#721676) * debian/control, debian/compat: + Use Debhelper >= 9 to get Debian compilation build flags. * debian/rules: + Send HTTP traffic to the “discard” service during packaging actions. * debian/watch, debian/repack: + Configure ‘uscan’ to re-pack upstream source tarball, removing non-DFSG-free obfuscated files. Thanks to Thomas Goirand and Stuart Prescott for advice on how to address this bug. (Closes: bug#726005) * debian/README.source, debian/source.lintian-overrides: + Explain how ‘uscan’ will get our upstream source. * debian/copyright: + Update copyright years. * debian/README.Debian: + Explain separate versioned packaging and program names. * debian/patches/: + 01.remove-resource-files-from-distutils-setup.patch: Don't treat resource data files as Python package data. (Closes: bug#723788) + 03.rename-public-programs.patch: Rename public programs to be clear what they're for. + Patches incorporated upstream: * 01.refactor-handling-static-files.patch + Updated patches: * 02.use-system-ecmascript-libraries.patch -- Ben Finney Tue, 15 Oct 2013 13:16:36 +1100 python-coverage (3.4-3) unstable; urgency=medium * debian/rules: Revert mistaken method of consolidating doc directories, which doesn't work because it asks ‘dpkg’ to violate Policy (Closes: bug#672224). -- Ben Finney Thu, 10 May 2012 10:21:16 +1000 python-coverage (3.4-2) unstable; urgency=low * debian/control: + Conform to ‘Standards-Version: 3.9.3’. No additional changes required. + Update VCS fields following changes at Alioth. + Ensure shlibs dependencies for each arch-dependent package. * debian/compat, debian/control: + Increase minimum ‘debhelper’ dependency to one which supports the rules targets we're now using. (Closes: bug#659643) * debian/copyright: + Conform to copyright format version 1.0. * debian/rules: + Use main package doc directory (via symlink) for debug package. * debian/rules, debian/*.install: + More fiddling with installation of files for debug package. -- Ben Finney Mon, 26 Mar 2012 23:35:13 +1100 python-coverage (3.4-1) unstable; urgency=low * The “Mravaljamier” release. * New upstream version (Closes: bug#600672). Primary user-visible changes: + Settings are now read from a .coveragerc file. + Enable coverage measurement when Python starts. + Support for Python 2.7 and 3.2 opcodes. + Finer control over what gets recorded or reported. * debian/preinst: + Remove: Squeeze is released, so we no longer need to maintain the special cleanup of ‘python-central’ mess. * debian/copyright: + Conform to current DEP-5 format. + Update with current copyright information. * debian/control: + Conform to ‘Standards-Version: 3.9.2’. No additional changes required. * debian/control, debian/rules: + Switch to ‘dh_python2’ packaging helper. + Depend on ECMAScript libraries needed for HTML reports. + Remove duplicate ECMAScript libraries. * debian/patches/01.refactor-handling-static-files.patch, debian/patches/02.use-system-js-libraries.patch: + Use the Debian system ECMAScript libraries (Closes: bug#596212). -- Ben Finney Wed, 27 Jul 2011 16:23:25 +1000 python-coverage (3.2-1) unstable; urgency=low * The “Artificial Conscience” release. * New upstream version. Primary user-visible changes: + Command-line interface re-worked with sub-commands. + Inspection now traverses egg packages. + Branch coverage recording and reporting. + New XML format for generated reports. * debian/control: + Remove Lars Wirzenius from all roles at his request. + Conform to ‘Standards-Version: 3.8.4’. No changes required. * debian/python-coverage.install, debian/python-coverage.manpages: + Use ‘dh_installman(1)’ to install man pages. * debian/control, debian/rules: + Add ‘python-coverage-dbg’ package for debugging symbols. + Use newer ‘debhelper’ to ensure automated build for all supported versions and for debug packages. * debian/copyright: + Update copyright information for latest upstream source. * debian/source/format: + Convert packaging to source format “3.0 (quilt)”. * debian/python-coverage.dirs: + Removed, the ‘/usr/bin/’ directory is created by ‘setup.py’. * debian/rules: + Remove, during ‘clean’ target, files that clobber upstream source. + Specify installation of Python package to ‘/usr/’ hierarchy (not default). -- Ben Finney Wed, 03 Feb 2010 15:03:59 +1100 python-coverage (3.0.1-1) unstable; urgency=low * The “Rods and Cones” release. * New upstream version. Primary user-visible changes: + Remove tracer recursion limit. + Skip coverage of ‘coverage’ library code. + Run Python source files in “universal newline mode”. * debian/control: + Update email address for Lars Wirzenius. + Comply with ‘Standards-Version: 3.8.3’. No changes required. + Update ‘Homepage’ field. + Add ‘VCS-bzr’ and ‘VCS-Browser’ fields. + Build for all supported Python versions. * debian/README.source: + Remove, no longer applicable. * debian/pyversions: + Specify Python versions supported. -- Ben Finney Fri, 02 Oct 2009 14:16:46 +1000 python-coverage (3.0-1) unstable; urgency=low * The “ladny” release. [ Ben Finney ] * New upstream version. Primary user-visible changes: + Major overhaul: refactored into a Python package, with some functionality implemented in C for speed. + Defaults to skipping measurement of standard library coverage. + HTML output now available, via ‘-b’ option. (Closes: bug#535764) * debian/watch: + Primary upstream source distribution channel is now the Cheese Shop. + Deal with crazy-arse version comparison semantics. * debian/control, debian/rules, debian/compat: + Comply with ‘Standards-Version: 3.8.2’. No changes required. + Migrate from CDBS to debhelper 7. * debian/control, debian/rules, debian/preinst: + Migrate from python-central to python-support. * debian/rules: + Install upstream changelog. * debian/control, debian/rules: + Package is arch-dependent now that it uses C extension. * debian/control: + Set myself as Maintainer, demote Lars Wirzenius to Uploader at his request. Thanks, Lars! -- Ben Finney Sun, 05 Jul 2009 09:06:58 +1000 python-coverage (2.85-1) unstable; urgency=low [ Lars Wirzenius ] * debian/control: Added missing DM-Upload-Allowed field. [ Ben Finney ] * New upstream version: + Use os.realpath as part of the fixing of filenames so that symlinks won't confuse things. Thanks, Patrick Mezard. Closes: bug#495963. * debian/rules: + Fix bogus executable permission for non-program files from upstream tarball. * debian/copyright: + Re-work to proposed machine-parseable format. * debian/control: + Comply with ‘Standards-Version: 3.8.1’. + Add ‘Depends: ${misc:Depends}’ for debhelper. -- Ben Finney Thu, 19 Mar 2009 23:25:23 +1100 python-coverage (2.80-2) unstable; urgency=medium [ Ben Finney ] * debian/control + Fix missing Depends: python-pkg-resources. Thanks to Sami Liedes for the bug report. (Closes: bug#496001) -- Ben Finney Fri, 22 Aug 2008 10:02:53 +1000 python-coverage (2.80-1) unstable; urgency=low [ Ben Finney ] * New upstream release. * debian/control + Added Ben Finney to Uploaders. + Set Standards-Version to 3.8.0 (no changes required). + Add Build-Depends-Indep: python-setuptools, as now used by upstream packaging. + Upgrade Build-Depends-Indep: python-central to version that doesn't require 'debian/pycompat'. * debian/pycompat + Remove obsolete file. * debian/watch + Added, pointing to upstream author's site. * debian/rules + Upstream packaging installs program to '/usr/bin/coverage', move to '/usr/bin/python-coverage' to conform with existing versions. -- Ben Finney Mon, 30 Jun 2008 23:44:57 +1000 python-coverage (2.78-1) unstable; urgency=low * New upstream release. Thank you to Ben Finney for helping with the packaging. (Closes: #454982) * Homepage should be among control fields now (Closes: #456498) * Standards-Version upgraded to 3.7.3. No changes required. * Changed section to python. * Added python (>= 2.3) to Build-Depends, because of 'debian/rules clean' needing it. -- Lars Wirzenius Sun, 11 May 2008 14:37:15 +0300 python-coverage (2.6-1) unstable; urgency=low * Initial version. Closes: #405230. -- Lars Wirzenius Sun, 19 Aug 2007 22:53:59 +0300 debian/python3-coverage-dbg.install0000644000000000000000000000007212310044463014501 0ustar usr/lib/python3/dist-packages/coverage/*.cpython-*dm-*.so debian/repack0000755000000000000000000000443612310044463010365 0ustar #! /bin/bash # debian/repack # Re-build the pristine upstream source to serve as the Debian upstream source. set -o errexit set -o errtrace set -o nounset function usage() { progname="$(basename "$0")" printf "$progname --upstream-version VERSION FILENAME\n" } if [ $# -ne 3 ] ; then usage exit 1 fi upstream_version="$2" downloaded_file="$3" working_dir="$(mktemp -d -t)" function cleanup_exit() { exit_status=$? trap - ERR EXIT SIGTERM SIGHUP SIGINT SIGQUIT rm -rf "${working_dir}" exit $exit_status } trap "cleanup_exit" ERR EXIT SIGTERM SIGHUP SIGINT SIGQUIT package_name=$(dpkg-parsechangelog | sed -n -e 's/^Source: //p') release_version=$(dpkg-parsechangelog | sed -n -e 's/^Version: //p') upstream_version=$(printf "${release_version}" \ | sed -e 's/^[[:digit:]]\+://' -e 's/[-][^-]\+$//') upstream_dirname="${package_name}-${upstream_version}.orig" target_filename="${package_name}_${upstream_version}.orig.tar.gz" target_working_file="${working_dir}/${target_filename}" target_file="$(dirname "${downloaded_file}")/${target_filename}" repack_dir="${working_dir}/${upstream_dirname}" printf "Unpacking pristine upstream source ‘${downloaded_file}’:\n" tar -xzf "${downloaded_file}" --directory "${working_dir}" upstream_source_dirname=$(ls -1 "${working_dir}") upstream_source_dir="${working_dir}/${upstream_source_dirname}" printf "Repackaging upstream source from ‘${upstream_source_dir}’ to ‘${repack_dir}’:\n" mv "${upstream_source_dir}" "${repack_dir}" printf "Removing non-DFSG-free files:\n" nonfree_files=( coverage/htmlfiles/jquery.min.js coverage/htmlfiles/jquery.tablesorter.min.js tests/farm/html/src/htmlcov/jquery-1.4.3.min.js tests/farm/html/src/htmlcov/jquery.tablesorter.min.js tests/qunit/jquery.tmpl.min.js ) for f in "${nonfree_files[@]}" ; do rm -v "${repack_dir}/$f" done printf "Rebuilding DFSG-free upstream source tarball:\n" GZIP="--best" tar --directory "${working_dir}" -czf "${target_working_file}" "${upstream_dirname}" printf "Moving completed upstream tarball to ‘${target_file}’:\n" rm -v "${downloaded_file}" mv "${target_working_file}" "${target_file}" printf "Done.\n" # Local variables: # coding: utf-8 # mode: sh # End: # vim: fileencoding=utf-8 filetype=sh : debian/manpage_encoding_declaration.UTF-80000644000000000000000000000003212310044463015526 0ustar '\" -*- coding: utf-8 -*- debian/README.source0000644000000000000000000000125712310044463011347 0ustar Building the Debian source package for python-coverage ====================================================== Pristine upstream source contains non-DFSG-free files ----------------------------------------------------- The pristine upstream source contains obfuscated files, that are thereby not appropriate for use as source files. This violates DFSG §2. The ‘debian/repack’ program removes those files to create the Debian upstream source tarball. The ‘debian/watch’ configuration specifies that ‘uscan --download’ will re-pack the pristine upstream tarball by running ‘debian/repack’. -- Ben Finney , Fri, 11 Oct 2013 23:12:21 +1100 debian/python-coverage.preinst0000644000000000000000000000216012310044463013702 0ustar #! /bin/sh # Pre-install script for ‘python-coverage’. # # Manpage: ‘dh_installdeb(1)’ set -e # Summary of ways this script can be called: # * install # * install # * upgrade # * abort-upgrade # For details, see the Debian Policy §6.5 in the ‘debian-policy’ package # or on the web at . action="$1" case "$action" in upgrade) old_version="$2" for python in $(pyversions --supported) ; do htmlfiles_dir="/usr/lib/${python}/dist-packages/coverage/htmlfiles" if [ -d "$htmlfiles_dir" ] && [ ! -L "$htmlfiles_dir" ] ; then # The ‘htmlfiles’ location should be platform-independent. # The new package will replace the directory with a symlink. rm -rf "$htmlfiles_dir" fi done ;; install|abort-upgrade) ;; *) printf "preinst called with unknown action ‘%s’\n" "$action" >&2 exit 1 ;; esac #DEBHELPER# debian/python-coverage.docs0000644000000000000000000000002512310044463013144 0ustar debian/README.Debian