check-mir: Use optparse to display --help

This commit is contained in:
Stefano Rivera 2012-05-05 19:37:41 +02:00
parent 083d44f676
commit b26dbaee68
3 changed files with 10 additions and 3 deletions

View File

@ -21,10 +21,13 @@
# this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
import apt
import sys
import optparse
import os.path
import apt
def check_support(apt_cache, pkgname, alt=False):
'''Check if pkgname is in main or restricted.
@ -118,6 +121,11 @@ def check_binary_dependencies(apt_cache, control):
return any_unsupported
def main():
parser = optparse.OptionParser(
description="Check if any of a package's build or binary "
"dependencies are in universe or multiverse. "
"Run this inside an unpacked source package")
parser.parse_args()
apt_cache = apt.Cache()
if not os.path.exists('debian/control'):

2
debian/changelog vendored
View File

@ -3,7 +3,7 @@ ubuntu-dev-tools (0.142) UNRELEASED; urgency=low
* mk-sbuild: Support kmod, when checking for overlayfs availability.
* pbuilder-dist: improve bash_completion for *.dsc files. Thanks Maarten
Bezemer. (Closes: #670924, LP: #770529)
* submittodebian: Use optparse to display --help (LP: #988009)
* submittodebian, check-mir: Use optparse to display --help (LP: #988009)
-- Stefano Rivera <stefanor@debian.org> Wed, 25 Apr 2012 17:38:58 +0200

View File

@ -25,7 +25,6 @@ from ubuntutools import subprocess
from ubuntutools.test import unittest
BLACKLIST = {
'check-mir': 'No Help',
'check-symbols': 'No Help',
'grep-merges': 'No Help',
'pbuilder-dist-simple': 'No Help',