mirror of
https://git.launchpad.net/ubuntu-dev-tools
synced 2025-08-17 00:44:03 +00:00
Compare commits
No commits in common. "main" and "0.30" have entirely different histories.
1
.bzrignore
Normal file
1
.bzrignore
Normal file
@ -0,0 +1 @@
|
||||
debian/pycompat
|
2
.gitignore
vendored
2
.gitignore
vendored
@ -1,2 +0,0 @@
|
||||
__pycache__
|
||||
*.egg-info
|
65
.pylintrc
65
.pylintrc
@ -1,65 +0,0 @@
|
||||
[MASTER]
|
||||
|
||||
# A comma-separated list of package or module names from where C extensions may
|
||||
# be loaded. Extensions are loading into the active Python interpreter and may
|
||||
# run arbitrary code.
|
||||
extension-pkg-allow-list=apt_pkg
|
||||
|
||||
# Pickle collected data for later comparisons.
|
||||
persistent=no
|
||||
|
||||
# Use all cpus, to speed up testing
|
||||
jobs=0
|
||||
|
||||
|
||||
[MESSAGES CONTROL]
|
||||
|
||||
# Disable the message, report, category or checker with the given id(s). You
|
||||
# can either give multiple identifiers separated by comma (,) or put this
|
||||
# option multiple times (only on the command line, not in the configuration
|
||||
# file where it should appear only once).You can also use "--disable=all" to
|
||||
# disable everything first and then reenable specific checks. For example, if
|
||||
# you want to run only the similarities checker, you can use "--disable=all
|
||||
# --enable=similarities". If you want to run only the classes checker, but have
|
||||
# no Warning level messages displayed, use"--disable=all --enable=classes
|
||||
# --disable=W"
|
||||
disable=fixme,locally-disabled,missing-docstring,useless-option-value,
|
||||
# TODO: Fix all following disabled checks!
|
||||
invalid-name,
|
||||
consider-using-with,
|
||||
too-many-arguments,
|
||||
too-many-branches,
|
||||
too-many-statements,
|
||||
too-many-locals,
|
||||
duplicate-code,
|
||||
too-many-instance-attributes,
|
||||
too-many-nested-blocks,
|
||||
too-many-lines,
|
||||
|
||||
|
||||
[REPORTS]
|
||||
|
||||
# Tells whether to display a full report or only the messages
|
||||
reports=no
|
||||
|
||||
|
||||
[FORMAT]
|
||||
|
||||
# Maximum number of characters on a single line.
|
||||
max-line-length=99
|
||||
|
||||
# String used as indentation unit. This is usually " " (4 spaces) or "\t" (1
|
||||
# tab).
|
||||
indent-string=' '
|
||||
|
||||
|
||||
[BASIC]
|
||||
|
||||
# Allow variables called e, f, lp
|
||||
good-names=i,j,k,ex,Run,_,e,f,lp,me,to
|
||||
|
||||
|
||||
[IMPORTS]
|
||||
|
||||
# Force import order to recognize a module as part of a third party library.
|
||||
known-third-party=debian
|
110
404main
Executable file
110
404main
Executable file
@ -0,0 +1,110 @@
|
||||
#!/usr/bin/python
|
||||
# -*- coding: utf-8 -*-
|
||||
#
|
||||
# Copyright 2006-2007 (C) Pete Savage <petesavage@ubuntu.com>
|
||||
# Copyright 2007 (C) Siegfried-A. Gevatter <rainct@ubuntu.com>
|
||||
# License: GPLv2 or later
|
||||
#
|
||||
# This script is used to check if a package and all its build
|
||||
# dependencies are in main or not.
|
||||
|
||||
import subprocess
|
||||
import sys
|
||||
|
||||
def process_deps(deps):
|
||||
"""Takes a list of (build) dependencies and processes it."""
|
||||
|
||||
for package in [ package.split('|')[0] for package in deps ]:
|
||||
|
||||
# Cut package name (from something like "name ( >= version)")
|
||||
name = package.split(' ')[0]
|
||||
|
||||
if not packages.has_key(name) and name != '':
|
||||
# Check the (build) dependencies recursively
|
||||
find_main(name)
|
||||
|
||||
|
||||
def find_main(pack):
|
||||
"""Searches the dependencies and build dependencies of a package recursively
|
||||
to determine if they are all in the 'main' component or not."""
|
||||
|
||||
global packages
|
||||
|
||||
# Retrieve information about the package
|
||||
out = subprocess.Popen('apt-cache madison ' + pack + ' | grep ' + distro + ' | grep -m 1 Packages', shell=True, stdout=subprocess.PIPE).stdout.read()
|
||||
|
||||
if out.find("/main") != -1:
|
||||
packages[pack] = True
|
||||
return 1
|
||||
else:
|
||||
if not packages.has_key(pack):
|
||||
packages[pack] = False
|
||||
|
||||
# Retrive package dependencies
|
||||
deps = subprocess.Popen('apt-cache show ' + pack + ' | grep -m 1 ^Depends', shell=True, stdout=subprocess.PIPE).stdout.read().split('\n')[0].replace('Depends: ', '').split(', ')
|
||||
|
||||
process_deps(deps)
|
||||
|
||||
# Retrieve package build dependencies
|
||||
deps1 = subprocess.Popen('apt-cache showsrc ' + pack + ' | grep -m 1 ^Build-Depends', shell=True, stdout=subprocess.PIPE).stdout.readlines()
|
||||
deps = []
|
||||
|
||||
for builddep in deps1:
|
||||
if builddep.startswith('Build-Depends'):
|
||||
deps += builddep.strip('\n').replace('Build-Depends: ', '').replace('Build-Depends-Indep: ', '').split(', ')
|
||||
|
||||
process_deps(deps)
|
||||
|
||||
|
||||
def main():
|
||||
|
||||
global packages, distro
|
||||
|
||||
# Check if the amount of arguments is correct
|
||||
if len(sys.argv) < 2 or len(sys.argv) > 3 or sys.argv[1] in ('help', '-h', '--help'):
|
||||
print 'Usage: %s <package name> [<distribution>]' % sys.argv[0]
|
||||
sys.exit(1)
|
||||
|
||||
if len(sys.argv) == 3 and sys.argv[2]:
|
||||
distro = sys.argv[2]
|
||||
if not subprocess.Popen('apt-cache madison bash | grep ' + distro, shell=True, stdout=subprocess.PIPE).stdout.read():
|
||||
print '«%s» is not a valid distribution.' % distro
|
||||
print 'Remember that for 404main to work with a certain distribution it must be in your /etc/apt/sources.list file.'
|
||||
sys.exit(1)
|
||||
else:
|
||||
distro = subprocess.Popen('lsb_release -cs', shell=True, stdout=subprocess.PIPE).stdout.read().strip('\n')
|
||||
|
||||
if not subprocess.Popen('apt-cache madison ' + sys.argv[1] + ' | grep ' + distro, shell=True, stdout=subprocess.PIPE).stdout.read():
|
||||
print 'Can\'t find package «%s» in distribution «%s».' % (sys.argv[1], distro)
|
||||
sys.exit(1)
|
||||
|
||||
print 'Checking package «%s» in distribution «%s»...' % (sys.argv[1], distro)
|
||||
|
||||
find_main(sys.argv[1])
|
||||
|
||||
# True if everything checked until the point is in main
|
||||
all_in_main = True
|
||||
|
||||
for package in packages:
|
||||
if not packages[package]:
|
||||
if all_in_main:
|
||||
print 'The following packages aren\'t in main:'
|
||||
all_in_main = False
|
||||
print ' ', package
|
||||
|
||||
if all_in_main:
|
||||
print 'Package «%s» and all its dependencies and build dependencies are in main.' % sys.argv[1]
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
||||
# Global variable to hold the status of all packages
|
||||
packages = {}
|
||||
|
||||
# Global variable to hold the target distribution
|
||||
distro = ''
|
||||
|
||||
try:
|
||||
main()
|
||||
except KeyboardInterrupt:
|
||||
print 'Aborted.'
|
||||
sys.exit(1)
|
14
AUTHORS
Normal file
14
AUTHORS
Normal file
@ -0,0 +1,14 @@
|
||||
Albert Damen <albrt@gmx.net>
|
||||
Albin Tonnerre <lut1n.tne@gmail.com>
|
||||
Daniel Holbach <daniel.holbach@ubuntu.com>
|
||||
Jamin W. Collins <jcollins@asgardsrealm.net>
|
||||
Jordan Mantha <mantha@ubuntu.com>
|
||||
Luke Yelavich <themuso@ubuntu.com>
|
||||
Martin Pitt <martin.pitt@ubuntu.com>
|
||||
Michael Bienia <geser@ubuntu.com>
|
||||
Pete Savage <petesavage@ubuntu.com>
|
||||
Kees Cook <kees@ubuntu.com>
|
||||
Siegfried-A. Gevatter <rainct@ubuntu.com>
|
||||
Soren Hansen <soren@ubuntu.com>
|
||||
Steve Kowalik <stevenk@ubuntu.com>
|
||||
Terence Simpson <stdin@stdin.me.uk>
|
78
README
Normal file
78
README
Normal file
@ -0,0 +1,78 @@
|
||||
================================
|
||||
== Ubuntu Development Tools ==
|
||||
================================
|
||||
|
||||
404main <package>
|
||||
... will check if <package> and all it's build dependencies are
|
||||
are in the "main" component or not.
|
||||
|
||||
check-symbols <package> [<directory>]
|
||||
... will compare and give you a diff of the exported symbols of all
|
||||
.so files in all binary packages of <package>. <directory> is not
|
||||
mandatory and set to /var/cache/pbuilder/result by default.
|
||||
|
||||
dch-repeat [--help]
|
||||
... will repeat a change log into an older release.
|
||||
|
||||
dgetlp <URL>
|
||||
... will simulate «dget»'s behaviour for files hosted at
|
||||
launchpadlibrarian.net.
|
||||
|
||||
get-branches <directory> <team> [checkout|branch]
|
||||
... will branch / checkout all the Bazaar branches in a Launchpad
|
||||
team.
|
||||
|
||||
get-build-deps [<packages list or file containing a list of packages>]
|
||||
... will install the build dependencies for a package, if you are
|
||||
inside its source file. Alternatively, you can pass it the name of
|
||||
a file containing a list of packages, one on each line, or just
|
||||
pass them all as parameters, and it will get their build
|
||||
dependencies.
|
||||
|
||||
hugdaylist [-n <number>] <bug list url>
|
||||
... will create a list of <number> bug list for a hug day listing
|
||||
|
||||
massfile
|
||||
... will perform a massive bug reporting operation on Launchpad
|
||||
according to the information in the "information" and "list" files
|
||||
that are in the working directory.
|
||||
|
||||
mk-sbuild-lv
|
||||
... will create LVM snapshot chroots via schroot and sbuild. It
|
||||
assumes that sbuild has not be installed and configured before.
|
||||
|
||||
pbuilder-dist [withlog] [create|update|build|clean|login|execute]
|
||||
... is a wrapper to use pbuilder with many different Ubuntu and/or
|
||||
Debian releases. It's recommended to symlink as pbuilder-feisty,
|
||||
pbuilder-gutsy, etc.
|
||||
|
||||
pull-debian-debdiff <package> <version>
|
||||
... will attempt to find and download a specific version of a
|
||||
Debian package and its immediate parent to generate a debdiff.
|
||||
|
||||
requestsync [-n|-s] <source package> <target release> [base version]
|
||||
... will file a sync request for a package from Debian by sending
|
||||
a bug report to Launchpad.
|
||||
|
||||
reverse-build-depends [-c|-s] <package name>
|
||||
... will print <package name>'s build dependencies.
|
||||
|
||||
submittodebian
|
||||
... will submit patches to Debian's BTS. Run it from inside the
|
||||
source directory of a Debian package (note that there has to be
|
||||
a .dsc for it in the parent directory).
|
||||
|
||||
suspicious-source
|
||||
... will output a list of files which are not common source files.
|
||||
This should be run in the root of a source tree to find files which
|
||||
might not be the "prefered form of modification" that the GPL and
|
||||
other licenses require.
|
||||
|
||||
update-maintainer
|
||||
... will update the Maintainer field of an Ubuntu package to match
|
||||
the DebianMaintainerField specification, and add a line about this
|
||||
to the changelog.
|
||||
|
||||
what-patch
|
||||
... will check what patching system is used by a package. You need
|
||||
to be in its source directory in order for it to work.
|
@ -1,54 +0,0 @@
|
||||
Updating the ubuntu-dev-tools package
|
||||
-------------------------------------
|
||||
|
||||
Here are the 10 steps that are recommended to take when updating the
|
||||
ubuntu-dev-tools package in Ubuntu.
|
||||
|
||||
1) Make sure there are no new commits to the package's master branch in git:
|
||||
|
||||
git pull
|
||||
|
||||
2) Check to make sure that all approved merges have been merged:
|
||||
|
||||
https://code.launchpad.net/ubuntu-dev-tools/+activereviews
|
||||
|
||||
3) Make sure that there is no low lying fruit that can be fixed at:
|
||||
|
||||
https://bugs.launchpad.net/ubuntu/+source/ubuntu-dev-tools
|
||||
https://bugs.debian.org/src:ubuntu-dev-tools
|
||||
|
||||
4) Check that the test suite passes
|
||||
|
||||
setup.py test
|
||||
|
||||
5) Before uploading the package change the UNRELEASED field in the
|
||||
debian/changelog file to unstable. (ubuntu-dev-tools is maintained in Debian
|
||||
and synced to Ubuntu)
|
||||
|
||||
If there is no UNRELEASED entry, make sure that the version for the current
|
||||
one has not been uploaded by someone else already:
|
||||
|
||||
https://tracker.debian.org/pkg/ubuntu-dev-tools
|
||||
https://launchpad.net/ubuntu/+source/ubuntu-dev-tools/+publishinghistory
|
||||
|
||||
6) Once the target release has been changed, commit it to git (where X.YY is
|
||||
the new package version):
|
||||
|
||||
git commit -a -m "Uploaded X.YY to RELEASE."
|
||||
|
||||
7) Create the new source package and tag the new release in git:
|
||||
|
||||
gbp buildpackage -S --git-tag
|
||||
|
||||
For a full list of tags, please see: 'git tag -l'. This is so we can track
|
||||
which git commit is in which release and makes bug triaging easier.
|
||||
|
||||
8) Upload the package to Debian with dput as normal:
|
||||
|
||||
dput ftp-master ubuntu-dev-tools_X.YY_$arch.changes
|
||||
|
||||
9) Create a new blank entry with dch -i and mark it as UNRELEASED.
|
||||
|
||||
10) After it's been dinstalled in Debian, sync to Ubuntu:
|
||||
|
||||
syncpackage ubuntu-dev-tools
|
14
TODO
14
TODO
@ -1,10 +1,4 @@
|
||||
TODO for the ubuntu-dev-tools package
|
||||
-------------------------------------
|
||||
|
||||
- Fix all bugs at Launchpad:
|
||||
https://bugs.launchpad.net/ubuntu/+source/ubuntu-dev-tools
|
||||
|
||||
- Create missing and improve existing manpages (for all commands).
|
||||
|
||||
- Ask all authors who have used GPL if they are happy with using "or any later"
|
||||
versions of the license.
|
||||
- Create missing manpages (for all commands).
|
||||
- Document ubuntutools Python modules.
|
||||
- Add the process-interdiff script to ubuntu-dev-tools.
|
||||
- Modify 404main to use the more robust python-apt module.
|
||||
|
495
backportpackage
495
backportpackage
@ -1,495 +0,0 @@
|
||||
#!/usr/bin/python3
|
||||
# -*- coding: utf-8 -*-
|
||||
# ##################################################################
|
||||
#
|
||||
# Copyright (C) 2010-2011, Evan Broder <evan@ebroder.net>
|
||||
# Copyright (C) 2010, Benjamin Drung <bdrung@ubuntu.com>
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; version 2.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# See file /usr/share/common-licenses/GPL-2 for more details.
|
||||
#
|
||||
# ##################################################################
|
||||
|
||||
import argparse
|
||||
import glob
|
||||
import os
|
||||
import shutil
|
||||
import subprocess
|
||||
import sys
|
||||
import tempfile
|
||||
from urllib.parse import quote
|
||||
|
||||
try:
|
||||
import lsb_release
|
||||
except ImportError:
|
||||
lsb_release = None
|
||||
from distro_info import DebianDistroInfo, UbuntuDistroInfo
|
||||
from httplib2 import Http, HttpLib2Error
|
||||
|
||||
from ubuntutools import getLogger
|
||||
from ubuntutools.archive import DebianSourcePackage, DownloadError, UbuntuSourcePackage
|
||||
from ubuntutools.builder import get_builder
|
||||
from ubuntutools.config import UDTConfig, ubu_email
|
||||
from ubuntutools.lp.lpapicache import (
|
||||
Distribution,
|
||||
Launchpad,
|
||||
PackageNotFoundException,
|
||||
SeriesNotFoundException,
|
||||
)
|
||||
from ubuntutools.misc import codename_to_distribution, system_distribution, vendor_to_distroinfo
|
||||
from ubuntutools.question import YesNoQuestion
|
||||
|
||||
Logger = getLogger()
|
||||
|
||||
|
||||
def error(msg, *args):
|
||||
Logger.error(msg, *args)
|
||||
sys.exit(1)
|
||||
|
||||
|
||||
def check_call(cmd, *args, **kwargs):
|
||||
Logger.debug(" ".join(cmd))
|
||||
ret = subprocess.call(cmd, *args, **kwargs)
|
||||
if ret != 0:
|
||||
error("%s returned %d.", cmd[0], ret)
|
||||
|
||||
|
||||
def parse(argv):
|
||||
usage = "%(prog)s [options] <source package name or .dsc URL/file>"
|
||||
parser = argparse.ArgumentParser(usage=usage)
|
||||
parser.add_argument(
|
||||
"-d",
|
||||
"--destination",
|
||||
metavar="DEST",
|
||||
dest="dest_releases",
|
||||
default=[],
|
||||
action="append",
|
||||
help="Backport to DEST release (default: current release)",
|
||||
)
|
||||
parser.add_argument(
|
||||
"-s",
|
||||
"--source",
|
||||
metavar="SOURCE",
|
||||
dest="source_release",
|
||||
help="Backport from SOURCE release (default: devel release)",
|
||||
)
|
||||
parser.add_argument(
|
||||
"-S",
|
||||
"--suffix",
|
||||
metavar="SUFFIX",
|
||||
help="Suffix to append to version number (default: ~ppa1 when uploading to a PPA)",
|
||||
)
|
||||
parser.add_argument(
|
||||
"-e",
|
||||
"--message",
|
||||
metavar="MESSAGE",
|
||||
default="No-change",
|
||||
help='Changelog message to use instead of "No-change" '
|
||||
"(default: No-change backport to DEST.)",
|
||||
)
|
||||
parser.add_argument(
|
||||
"-b",
|
||||
"--build",
|
||||
default=False,
|
||||
action="store_true",
|
||||
help="Build the package before uploading (default: %(default)s)",
|
||||
)
|
||||
parser.add_argument(
|
||||
"-B",
|
||||
"--builder",
|
||||
metavar="BUILDER",
|
||||
help="Specify the package builder (default: pbuilder)",
|
||||
)
|
||||
parser.add_argument(
|
||||
"-U",
|
||||
"--update",
|
||||
default=False,
|
||||
action="store_true",
|
||||
help="Update the build environment before attempting to build",
|
||||
)
|
||||
parser.add_argument("-u", "--upload", metavar="UPLOAD", help="Specify an upload destination")
|
||||
parser.add_argument(
|
||||
"-k", "--key", dest="keyid", help="Specify the key ID to be used for signing."
|
||||
)
|
||||
parser.add_argument(
|
||||
"--dont-sign", dest="keyid", action="store_false", help="Do not sign the upload."
|
||||
)
|
||||
parser.add_argument(
|
||||
"-y",
|
||||
"--yes",
|
||||
dest="prompt",
|
||||
default=True,
|
||||
action="store_false",
|
||||
help="Do not prompt before uploading to a PPA",
|
||||
)
|
||||
parser.add_argument(
|
||||
"-v", "--version", metavar="VERSION", help="Package version to backport (or verify)"
|
||||
)
|
||||
parser.add_argument(
|
||||
"-w",
|
||||
"--workdir",
|
||||
metavar="WORKDIR",
|
||||
help="Specify a working directory (default: temporary dir)",
|
||||
)
|
||||
parser.add_argument(
|
||||
"-r",
|
||||
"--release-pocket",
|
||||
default=False,
|
||||
action="store_true",
|
||||
help="Target the release pocket in the .changes file. "
|
||||
"Necessary (and default) for uploads to PPAs",
|
||||
)
|
||||
parser.add_argument(
|
||||
"-c", "--close", metavar="BUG", help="Bug to close in the changelog entry."
|
||||
)
|
||||
parser.add_argument(
|
||||
"-m", "--mirror", metavar="URL", help="Preferred mirror (default: Launchpad)"
|
||||
)
|
||||
parser.add_argument(
|
||||
"-l",
|
||||
"--lpinstance",
|
||||
metavar="INSTANCE",
|
||||
help="Launchpad instance to connect to (default: production)",
|
||||
)
|
||||
parser.add_argument(
|
||||
"--no-conf",
|
||||
default=False,
|
||||
action="store_true",
|
||||
help="Don't read config files or environment variables",
|
||||
)
|
||||
parser.add_argument("package_or_dsc", help=argparse.SUPPRESS)
|
||||
|
||||
args = parser.parse_args(argv)
|
||||
config = UDTConfig(args.no_conf)
|
||||
if args.builder is None:
|
||||
args.builder = config.get_value("BUILDER")
|
||||
if not args.update:
|
||||
args.update = config.get_value("UPDATE_BUILDER", boolean=True)
|
||||
if args.workdir is None:
|
||||
args.workdir = config.get_value("WORKDIR")
|
||||
if args.lpinstance is None:
|
||||
args.lpinstance = config.get_value("LPINSTANCE")
|
||||
if args.upload is None:
|
||||
args.upload = config.get_value("UPLOAD")
|
||||
if args.keyid is None:
|
||||
args.keyid = config.get_value("KEYID")
|
||||
if not args.upload and not args.workdir:
|
||||
parser.error("Please specify either a working dir or an upload target!")
|
||||
if args.upload and args.upload.startswith("ppa:"):
|
||||
args.release_pocket = True
|
||||
|
||||
return args, config
|
||||
|
||||
|
||||
def find_release_package(mirror, workdir, package, version, source_release, config):
|
||||
srcpkg = None
|
||||
|
||||
if source_release:
|
||||
distribution = codename_to_distribution(source_release)
|
||||
if not distribution:
|
||||
error("Unknown release codename %s", source_release)
|
||||
info = vendor_to_distroinfo(distribution)()
|
||||
source_release = info.codename(source_release, default=source_release)
|
||||
else:
|
||||
distribution = system_distribution()
|
||||
mirrors = [mirror] if mirror else []
|
||||
|
||||
mirrors.append(config.get_value(f"{distribution.upper()}_MIRROR"))
|
||||
|
||||
if not version:
|
||||
archive = Distribution(distribution.lower()).getArchive()
|
||||
try:
|
||||
spph = archive.getSourcePackage(package, source_release)
|
||||
except (SeriesNotFoundException, PackageNotFoundException) as e:
|
||||
error("%s", str(e))
|
||||
version = spph.getVersion()
|
||||
|
||||
if distribution == "Debian":
|
||||
srcpkg = DebianSourcePackage(package, version, workdir=workdir, mirrors=mirrors)
|
||||
elif distribution == "Ubuntu":
|
||||
srcpkg = UbuntuSourcePackage(package, version, workdir=workdir, mirrors=mirrors)
|
||||
|
||||
return srcpkg
|
||||
|
||||
|
||||
def find_package(mirror, workdir, package, version, source_release, config):
|
||||
"Returns the SourcePackage"
|
||||
if package.endswith(".dsc"):
|
||||
# Here we are using UbuntuSourcePackage just because we don't have any
|
||||
# "general" class that is safely instantiable (as SourcePackage is an
|
||||
# abstract class). None of the distribution-specific details within
|
||||
# UbuntuSourcePackage is relevant for this use case.
|
||||
return UbuntuSourcePackage(
|
||||
version=version, dscfile=package, workdir=workdir, mirrors=(mirror,)
|
||||
)
|
||||
|
||||
if not source_release and not version:
|
||||
info = vendor_to_distroinfo(system_distribution())
|
||||
source_release = info().devel()
|
||||
|
||||
srcpkg = find_release_package(mirror, workdir, package, version, source_release, config)
|
||||
if version and srcpkg.version != version:
|
||||
error(
|
||||
"Requested backport of version %s but version of %s in %s is %s",
|
||||
version,
|
||||
package,
|
||||
source_release,
|
||||
srcpkg.version,
|
||||
)
|
||||
|
||||
return srcpkg
|
||||
|
||||
|
||||
def get_backport_version(version, suffix, upload, release):
|
||||
distribution = codename_to_distribution(release)
|
||||
if not distribution:
|
||||
error("Unknown release codename %s", release)
|
||||
if distribution == "Debian":
|
||||
debian_distro_info = DebianDistroInfo()
|
||||
debian_codenames = debian_distro_info.supported()
|
||||
if release in debian_codenames:
|
||||
release_version = debian_distro_info.version(release)
|
||||
if not release_version:
|
||||
error("Can't find the release version for %s", release)
|
||||
backport_version = f"{version}~bpo{release_version}+1"
|
||||
else:
|
||||
error("%s is not a supported release (%s)", release, debian_codenames)
|
||||
elif distribution == "Ubuntu":
|
||||
series = Distribution(distribution.lower()).getSeries(name_or_version=release)
|
||||
|
||||
backport_version = f"{version}~bpo{series.version}.1"
|
||||
else:
|
||||
error("Unknown distribution «%s» for release «%s»", distribution, release)
|
||||
if suffix is not None:
|
||||
backport_version += suffix
|
||||
elif upload and upload.startswith("ppa:"):
|
||||
backport_version += "~ppa1"
|
||||
return backport_version
|
||||
|
||||
|
||||
def get_old_version(source, release):
|
||||
try:
|
||||
distribution = codename_to_distribution(release)
|
||||
archive = Distribution(distribution.lower()).getArchive()
|
||||
pkg = archive.getSourcePackage(
|
||||
source, release, ("Release", "Security", "Updates", "Proposed", "Backports")
|
||||
)
|
||||
return pkg.getVersion()
|
||||
except (SeriesNotFoundException, PackageNotFoundException):
|
||||
pass
|
||||
return None
|
||||
|
||||
|
||||
def get_backport_dist(release, release_pocket):
|
||||
if release_pocket:
|
||||
return release
|
||||
return f"{release}-backports"
|
||||
|
||||
|
||||
def do_build(workdir, dsc, release, builder, update):
|
||||
builder = get_builder(builder)
|
||||
if not builder:
|
||||
return None
|
||||
|
||||
if update:
|
||||
if 0 != builder.update(release):
|
||||
sys.exit(1)
|
||||
|
||||
# builder.build is going to chdir to buildresult:
|
||||
workdir = os.path.realpath(workdir)
|
||||
return builder.build(os.path.join(workdir, dsc), release, os.path.join(workdir, "buildresult"))
|
||||
|
||||
|
||||
def do_upload(workdir, package, bp_version, changes, upload, prompt):
|
||||
print(f"Please check {package} {bp_version} in file://{workdir} carefully!")
|
||||
if prompt or upload == "ubuntu":
|
||||
question = f"Do you want to upload the package to {upload}"
|
||||
answer = YesNoQuestion().ask(question, "yes")
|
||||
if answer == "no":
|
||||
return
|
||||
|
||||
check_call(["dput", upload, changes], cwd=workdir)
|
||||
|
||||
|
||||
def orig_needed(upload, workdir, pkg):
|
||||
"""Avoid a -sa if possible"""
|
||||
if not upload or not upload.startswith("ppa:"):
|
||||
return True
|
||||
ppa = upload.split(":", 1)[1]
|
||||
user, ppa = ppa.split("/", 1)
|
||||
|
||||
version = pkg.version.upstream_version
|
||||
|
||||
http = Http()
|
||||
for filename in glob.glob(os.path.join(workdir, f"{pkg.source}_{version}.orig*")):
|
||||
url = (
|
||||
f"https://launchpad.net/~{quote(user)}/+archive/{quote(ppa)}/+sourcefiles"
|
||||
f"/{quote(pkg.source)}/{quote(pkg.version.full_version)}"
|
||||
f"/{quote(os.path.basename(filename))}"
|
||||
)
|
||||
try:
|
||||
headers = http.request(url, "HEAD")[0]
|
||||
if headers.status != 200 or not headers["content-location"].startswith(
|
||||
"https://launchpadlibrarian.net"
|
||||
):
|
||||
return True
|
||||
except HttpLib2Error as e:
|
||||
Logger.debug(e)
|
||||
return True
|
||||
return False
|
||||
|
||||
|
||||
def do_backport(
|
||||
workdir,
|
||||
pkg,
|
||||
suffix,
|
||||
message,
|
||||
close,
|
||||
release,
|
||||
release_pocket,
|
||||
build,
|
||||
builder,
|
||||
update,
|
||||
upload,
|
||||
keyid,
|
||||
prompt,
|
||||
):
|
||||
dirname = f"{pkg.source}-{release}"
|
||||
srcdir = os.path.join(workdir, dirname)
|
||||
|
||||
if os.path.exists(srcdir):
|
||||
question = f"Working directory {srcdir} already exists. Delete it?"
|
||||
if YesNoQuestion().ask(question, "no") == "no":
|
||||
sys.exit(1)
|
||||
shutil.rmtree(srcdir)
|
||||
|
||||
pkg.unpack(dirname)
|
||||
|
||||
bp_version = get_backport_version(pkg.version.full_version, suffix, upload, release)
|
||||
old_version = get_old_version(pkg.source, release)
|
||||
bp_dist = get_backport_dist(release, release_pocket)
|
||||
|
||||
changelog = f"{message} backport to {release}."
|
||||
if close:
|
||||
changelog += f" (LP: #{close})"
|
||||
check_call(
|
||||
[
|
||||
"dch",
|
||||
"--force-bad-version",
|
||||
"--force-distribution",
|
||||
"--preserve",
|
||||
"--newversion",
|
||||
bp_version,
|
||||
"--distribution",
|
||||
bp_dist,
|
||||
changelog,
|
||||
],
|
||||
cwd=srcdir,
|
||||
)
|
||||
|
||||
cmd = ["debuild", "--no-lintian", "-S", "-nc", "-uc", "-us"]
|
||||
if orig_needed(upload, workdir, pkg):
|
||||
cmd.append("-sa")
|
||||
else:
|
||||
cmd.append("-sd")
|
||||
if old_version:
|
||||
cmd.append(f"-v{old_version}")
|
||||
env = os.environ.copy()
|
||||
# An ubuntu.com e-mail address would make dpkg-buildpackage fail if there
|
||||
# wasn't an Ubuntu maintainer for an ubuntu-versioned package. LP: #1007042
|
||||
env.pop("DEBEMAIL", None)
|
||||
check_call(cmd, cwd=srcdir, env=env)
|
||||
|
||||
fn_base = pkg.source + "_" + bp_version.split(":", 1)[-1]
|
||||
changes = fn_base + "_source.changes"
|
||||
|
||||
if build:
|
||||
if 0 != do_build(workdir, fn_base + ".dsc", release, builder, update):
|
||||
sys.exit(1)
|
||||
|
||||
# None: sign with the default signature. False: don't sign
|
||||
if keyid is not False:
|
||||
cmd = ["debsign"]
|
||||
if keyid:
|
||||
cmd.append("-k" + keyid)
|
||||
cmd.append(changes)
|
||||
check_call(cmd, cwd=workdir)
|
||||
if upload:
|
||||
do_upload(workdir, pkg.source, bp_version, changes, upload, prompt)
|
||||
|
||||
shutil.rmtree(srcdir)
|
||||
|
||||
|
||||
def main(argv):
|
||||
ubu_email()
|
||||
|
||||
args, config = parse(argv[1:])
|
||||
|
||||
Launchpad.login_anonymously(service=args.lpinstance)
|
||||
|
||||
if not args.dest_releases:
|
||||
if lsb_release:
|
||||
distinfo = lsb_release.get_distro_information()
|
||||
try:
|
||||
current_distro = distinfo["ID"]
|
||||
except KeyError:
|
||||
error("No destination release specified and unable to guess yours.")
|
||||
else:
|
||||
err, current_distro = subprocess.getstatusoutput("lsb_release --id --short")
|
||||
if err:
|
||||
error("Could not run lsb_release to retrieve distribution")
|
||||
|
||||
if current_distro == "Ubuntu":
|
||||
args.dest_releases = [UbuntuDistroInfo().lts()]
|
||||
elif current_distro == "Debian":
|
||||
args.dest_releases = [DebianDistroInfo().stable()]
|
||||
else:
|
||||
error("Unknown distribution %s, can't guess target release", current_distro)
|
||||
|
||||
if args.workdir:
|
||||
workdir = os.path.expanduser(args.workdir)
|
||||
else:
|
||||
workdir = tempfile.mkdtemp(prefix="backportpackage-")
|
||||
|
||||
if not os.path.exists(workdir):
|
||||
os.makedirs(workdir)
|
||||
|
||||
try:
|
||||
pkg = find_package(
|
||||
args.mirror, workdir, args.package_or_dsc, args.version, args.source_release, config
|
||||
)
|
||||
pkg.pull()
|
||||
|
||||
for release in args.dest_releases:
|
||||
do_backport(
|
||||
workdir,
|
||||
pkg,
|
||||
args.suffix,
|
||||
args.message,
|
||||
args.close,
|
||||
release,
|
||||
args.release_pocket,
|
||||
args.build,
|
||||
args.builder,
|
||||
args.update,
|
||||
args.upload,
|
||||
args.keyid,
|
||||
args.prompt,
|
||||
)
|
||||
except DownloadError as e:
|
||||
error("%s", str(e))
|
||||
finally:
|
||||
if not args.workdir:
|
||||
shutil.rmtree(workdir)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
sys.exit(main(sys.argv))
|
@ -21,7 +21,7 @@ _pbuilder-dist()
|
||||
|
||||
case $prev in
|
||||
build)
|
||||
_filedir "dsc"
|
||||
COMPREPLY=( $( compgen -o filenames -G "$cur*.dsc" ) )
|
||||
;;
|
||||
*)
|
||||
COMPREPLY=( $( compgen -W "$options" | grep "^$cur" ) )
|
||||
@ -30,17 +30,6 @@ _pbuilder-dist()
|
||||
|
||||
return 0
|
||||
}
|
||||
[ "$have" ] && _pbuilder-aliases()
|
||||
{
|
||||
local distro builder arch
|
||||
for distro in $(ubuntu-distro-info --all; debian-distro-info --all) stable testing unstable; do
|
||||
for builder in pbuilder cowbuilder; do
|
||||
echo "$builder-$distro"
|
||||
for arch in i386 amd64 armhf; do
|
||||
echo "$builder-$distro-$arch"
|
||||
done
|
||||
done
|
||||
done
|
||||
return 0
|
||||
}
|
||||
[ "$have" ] && complete -F _pbuilder-dist -o filenames pbuilder-dist cowbuilder-dist $(_pbuilder-aliases)
|
||||
[ "$have" ] && complete -F _pbuilder-dist -o filenames \
|
||||
pbuilder-{dist,dapper,edgy,feisty,gutsy,hardy,intrepid,sarge,etch,lenny,sid}
|
||||
# Make it pbuilder-* if you know how to do it
|
||||
|
203
check-mir
203
check-mir
@ -1,203 +0,0 @@
|
||||
#!/usr/bin/python3
|
||||
#
|
||||
# Check components of build dependencies and warn about universe/multiverse
|
||||
# ones, for a package destined for main/restricted
|
||||
#
|
||||
# Copyright (C) 2011 Canonical
|
||||
#
|
||||
# Authors:
|
||||
# Martin Pitt
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify it under
|
||||
# the terms of the GNU General Public License as published by the Free Software
|
||||
# Foundation; version 3.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful, but WITHOUT
|
||||
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
|
||||
# FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
|
||||
# details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License along with
|
||||
# this program; if not, write to the Free Software Foundation, Inc.,
|
||||
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
|
||||
# pylint: disable=invalid-name
|
||||
# pylint: enable=invalid-name
|
||||
|
||||
"""Check if any of a package's build or binary dependencies are in universe or multiverse.
|
||||
|
||||
Run this inside an unpacked source package
|
||||
"""
|
||||
|
||||
import argparse
|
||||
import os.path
|
||||
import sys
|
||||
|
||||
import apt
|
||||
|
||||
|
||||
def check_support(apt_cache, pkgname, alt=False):
|
||||
"""Check if pkgname is in main or restricted.
|
||||
|
||||
This prints messages if a package is not in main/restricted, or only
|
||||
partially (i. e. source in main, but binary in universe).
|
||||
"""
|
||||
if alt:
|
||||
prefix = " ... alternative " + pkgname
|
||||
else:
|
||||
prefix = " * " + pkgname
|
||||
|
||||
prov_packages = apt_cache.get_providing_packages(pkgname)
|
||||
if pkgname in apt_cache:
|
||||
pkg = apt_cache[pkgname]
|
||||
|
||||
# If this is a virtual package, iterate through the binary packages that
|
||||
# provide this, and ensure they are all in Main. Source packages in and of
|
||||
# themselves cannot provide virtual packages, only binary packages can.
|
||||
elif len(prov_packages) > 0:
|
||||
supported, unsupported = [], []
|
||||
for pkg in prov_packages:
|
||||
candidate = pkg.candidate
|
||||
if candidate:
|
||||
section = candidate.section
|
||||
if section.startswith("universe") or section.startswith("multiverse"):
|
||||
unsupported.append(pkg.name)
|
||||
else:
|
||||
supported.append(pkg.name)
|
||||
|
||||
if len(supported) > 0:
|
||||
msg = "is a virtual package, which is provided by the following "
|
||||
msg += "candidates in Main: " + " ".join(supported)
|
||||
print(prefix, msg)
|
||||
elif len(unsupported) > 0:
|
||||
msg = "is a virtual package, but is only provided by the "
|
||||
msg += "following non-Main candidates: " + " ".join(unsupported)
|
||||
print(prefix, msg, file=sys.stderr)
|
||||
return False
|
||||
else:
|
||||
msg = "is a virtual package that exists but is not provided by "
|
||||
msg += "package currently in the archive. Proceed with caution."
|
||||
print(prefix, msg, file=sys.stderr)
|
||||
return False
|
||||
|
||||
else:
|
||||
print(prefix, "does not exist", file=sys.stderr)
|
||||
return False
|
||||
|
||||
section = pkg.candidate.section
|
||||
if section.startswith("universe") or section.startswith("multiverse"):
|
||||
# check if the source package is in main and thus will only need binary
|
||||
# promotion
|
||||
source_records = apt.apt_pkg.SourceRecords()
|
||||
if not source_records.lookup(pkg.candidate.source_name):
|
||||
print("ERROR: Cannot lookup source package for", pkg.name, file=sys.stderr)
|
||||
print(prefix, "package is in", section.split("/")[0])
|
||||
return False
|
||||
src = apt.apt_pkg.TagSection(source_records.record)
|
||||
if src["Section"].startswith("universe") or src["Section"].startswith("multiverse"):
|
||||
print(prefix, "binary and source package is in", section.split("/")[0])
|
||||
return False
|
||||
|
||||
print(
|
||||
prefix,
|
||||
"is in",
|
||||
section.split("/")[0] + ", but its source",
|
||||
pkg.candidate.source_name,
|
||||
"is already in main; file an ubuntu-archive bug for "
|
||||
"promoting the current preferred alternative",
|
||||
)
|
||||
return True
|
||||
|
||||
if alt:
|
||||
print(prefix, "is already in main; consider preferring it")
|
||||
|
||||
return True
|
||||
|
||||
|
||||
def check_build_dependencies(apt_cache, control):
|
||||
print("Checking support status of build dependencies...")
|
||||
|
||||
any_unsupported = False
|
||||
|
||||
for field in ("Build-Depends", "Build-Depends-Indep"):
|
||||
if field not in control.section:
|
||||
continue
|
||||
for or_group in apt.apt_pkg.parse_src_depends(control.section[field]):
|
||||
pkgname = or_group[0][0]
|
||||
|
||||
# debhelper-compat is expected to be a build dependency of every
|
||||
# package, so it is a red herring to display it in this report.
|
||||
# (src:debhelper is in Ubuntu Main anyway)
|
||||
if pkgname == "debhelper-compat":
|
||||
continue
|
||||
|
||||
if not check_support(apt_cache, pkgname):
|
||||
# check non-preferred alternatives
|
||||
for altpkg in or_group[1:]:
|
||||
if check_support(apt_cache, altpkg[0], alt=True):
|
||||
break
|
||||
else:
|
||||
any_unsupported = True
|
||||
|
||||
return any_unsupported
|
||||
|
||||
|
||||
def check_binary_dependencies(apt_cache, control):
|
||||
any_unsupported = False
|
||||
|
||||
print("\nChecking support status of binary dependencies...")
|
||||
while True:
|
||||
try:
|
||||
next(control)
|
||||
except StopIteration:
|
||||
break
|
||||
|
||||
for field in ("Depends", "Pre-Depends", "Recommends"):
|
||||
if field not in control.section:
|
||||
continue
|
||||
for or_group in apt.apt_pkg.parse_src_depends(control.section[field]):
|
||||
pkgname = or_group[0][0]
|
||||
if pkgname.startswith("$"):
|
||||
continue
|
||||
if not check_support(apt_cache, pkgname):
|
||||
# check non-preferred alternatives
|
||||
for altpkg in or_group[1:]:
|
||||
if check_support(apt_cache, altpkg[0], alt=True):
|
||||
break
|
||||
else:
|
||||
any_unsupported = True
|
||||
|
||||
return any_unsupported
|
||||
|
||||
|
||||
def main():
|
||||
parser = argparse.ArgumentParser(description=__doc__)
|
||||
parser.parse_args()
|
||||
apt_cache = apt.Cache()
|
||||
|
||||
if not os.path.exists("debian/control"):
|
||||
print(
|
||||
"debian/control not found. You need to run this tool in a source package directory",
|
||||
file=sys.stderr,
|
||||
)
|
||||
sys.exit(1)
|
||||
|
||||
# get build dependencies from debian/control
|
||||
control = apt.apt_pkg.TagFile(open("debian/control", encoding="utf-8"))
|
||||
next(control)
|
||||
|
||||
unsupported_build_deps = check_build_dependencies(apt_cache, control)
|
||||
unsupported_binary_deps = check_binary_dependencies(apt_cache, control)
|
||||
|
||||
if unsupported_build_deps or unsupported_binary_deps:
|
||||
print(
|
||||
"\nPlease check https://wiki.ubuntu.com/MainInclusionProcess if "
|
||||
"this source package needs to get into in main/restricted, or "
|
||||
"reconsider if the package really needs above dependencies."
|
||||
)
|
||||
else:
|
||||
print("All dependencies are supported in main or restricted.")
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
114
check-symbols
114
check-symbols
@ -1,108 +1,42 @@
|
||||
#!/bin/bash
|
||||
#
|
||||
# Copyright (C) 2006-2007 Daniel Holbach <daniel.holbach@ubuntu.com>
|
||||
# Copyright 2006-2007 (C) Daniel Holbach <daniel.holbach@ubuntu.com>
|
||||
# Modified by Siegfried-A. Gevatter <rainct@ubuntu.com>
|
||||
#
|
||||
# ##################################################################
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; version 2.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# See file /usr/share/common-licenses/GPL-2 for more details.
|
||||
#
|
||||
# ##################################################################
|
||||
# License: GPLv2
|
||||
#
|
||||
# This script is used to get a diff of the exported symbols of all .so files in
|
||||
# every binary package of package $1.
|
||||
|
||||
# Required tools (besides awk, coreutils, grep and sed):
|
||||
# * apt-cache and apt-get (from apt)
|
||||
# * diff (from diffutils)
|
||||
# * dpkg
|
||||
# * lsb_release (from lsb-release)
|
||||
# * nm (from binutils)
|
||||
|
||||
DISTRO=$(lsb_release -c -s)
|
||||
VERSION=$(apt-cache madison "$1" | grep -- "$DISTRO"'/.*Sources$' | awk '{print $3}')
|
||||
PACKAGES=$(apt-cache showsrc "$1" | grep-dctrl -s Binary -F Version "$VERSION" | sed 's/Binary\:\ //g;s/\,//g' | sort -u)
|
||||
DEBLINE=""
|
||||
DEBUG=False
|
||||
|
||||
usage() {
|
||||
prog=$(basename $0)
|
||||
cat <<EOF
|
||||
Usage: $prog [options] source-package [DEBDIR]
|
||||
|
||||
Get a diff of the exported symbols of all .so files in every binary package of
|
||||
package the source package. The source package will be found in DEBDIR, defaulting to /var/cache/pbuilder/result.
|
||||
|
||||
Options:
|
||||
-h, --help show this help message and exit
|
||||
EOF
|
||||
exit $1
|
||||
}
|
||||
|
||||
PACKAGE=""
|
||||
DEBDIR="/var/cache/pbuilder/result"
|
||||
POSITION=0
|
||||
while [ $# -gt 0 ]; do
|
||||
case "$1" in
|
||||
-h|--help)
|
||||
usage 0
|
||||
;;
|
||||
-*)
|
||||
usage 1
|
||||
;;
|
||||
*)
|
||||
if [ $POSITION -eq 0 ]; then
|
||||
PACKAGE="$1"
|
||||
elif [ $POSITION -eq 1 ]; then
|
||||
DEBDIR="$1"
|
||||
else
|
||||
echo "Too many arguments." >&2
|
||||
usage 1
|
||||
fi
|
||||
POSITION=$(($POSITION+1))
|
||||
esac
|
||||
shift
|
||||
done
|
||||
|
||||
if [ $POSITION -eq 0 ]; then
|
||||
echo "Missing argument: source package name." >&2
|
||||
usage 1
|
||||
if [[ -z $1 ]]; then
|
||||
echo "Missing argument: source package name.";
|
||||
exit;
|
||||
fi
|
||||
|
||||
VERSION=$(apt-cache madison "$PACKAGE" | grep -- "$DISTRO"'/.*Sources$' | awk '{print $3}')
|
||||
PACKAGES=$(apt-cache showsrc "$PACKAGE" | grep-dctrl -s Binary -F Version "$VERSION" | sed 's/Binary\:\ //g;s/\,//g' | sort -u)
|
||||
|
||||
if [ `id -u` != "0" ]
|
||||
then
|
||||
echo
|
||||
echo -n "You might now be asked for your password, as this script requires"
|
||||
echo " sudo privilegies in order to install the packages you want to check."
|
||||
echo
|
||||
if [[ -z $2 ]]; then
|
||||
DEBDIR="/var/cache/pbuilder/result";
|
||||
else
|
||||
DEBDIR="$2";
|
||||
fi
|
||||
|
||||
sudo apt-get install $PACKAGES
|
||||
echo
|
||||
|
||||
for pack in $PACKAGES;
|
||||
do
|
||||
for lib in `dpkg -L $pack | grep -E "\.so$" | sort -u`
|
||||
for lib in `dpkg -L $pack | grep -E "\.so$" | sort -u`;
|
||||
do
|
||||
LIBNAME=$(basename $lib)
|
||||
nm -D $lib | cut -d' ' -f3 | sort -u > /tmp/$LIBNAME.old
|
||||
LIBNAME=$(basename $lib);
|
||||
nm -D $lib | cut -d' ' -f3 | sort -u > /tmp/$LIBNAME.old;
|
||||
done;
|
||||
DEBLINE="$DEBLINE $DEBDIR/$pack*.deb "
|
||||
DEBLINE="$DEBLINE $DEBDIR/$pack*.deb ";
|
||||
done
|
||||
|
||||
if [[ -z $DEBLINE ]]; then
|
||||
echo "Package doesn't exist: $PACKAGE."
|
||||
exit 1
|
||||
echo "Package doesn't exist: $1."; exit
|
||||
fi
|
||||
|
||||
NOFILE=True
|
||||
@ -114,21 +48,19 @@ for filename in $DEBLINE; do
|
||||
done
|
||||
|
||||
if [[ $NOFILE == True ]]; then
|
||||
echo "No matching binary files found in «$DEBDIR»."
|
||||
exit 1
|
||||
echo "No matching binary files found in «$DEBDIR»."; exit
|
||||
fi
|
||||
|
||||
sudo dpkg -i $DEBLINE;
|
||||
echo
|
||||
|
||||
for pack in $PACKAGES;
|
||||
do
|
||||
for lib in `dpkg -L $pack | grep -E "\.so$" | sort -u`
|
||||
for lib in `dpkg -L $pack | grep -E "\.so$" | sort -u`;
|
||||
do
|
||||
LIBNAME=$(basename $lib)
|
||||
nm -D $lib | cut -d' ' -f3 | sort -u > /tmp/$LIBNAME.new
|
||||
echo "Checking: $lib"
|
||||
diff -u /tmp/$LIBNAME.{old,new}
|
||||
rm /tmp/$LIBNAME.{old,new}
|
||||
LIBNAME=$(basename $lib);
|
||||
nm -D $lib | cut -d' ' -f3 | sort -u > /tmp/$LIBNAME.new;
|
||||
echo "Checking: $lib";
|
||||
diff -u /tmp/$LIBNAME.{old,new};
|
||||
rm /tmp/$LIBNAME.{old,new};
|
||||
done;
|
||||
done
|
||||
|
38
dch-repeat
38
dch-repeat
@ -1,24 +1,6 @@
|
||||
#!/usr/bin/perl
|
||||
#
|
||||
# Copyright (C) 2007-2008 Canonical, Ltd.,
|
||||
# 2011, Stefano Rivera <stefanor@ubuntu.com>
|
||||
# Author: Kees Cook <kees@ubuntu.com>
|
||||
#
|
||||
# ##################################################################
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 3
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# See file /usr/share/common-licenses/GPL for more details.
|
||||
#
|
||||
# ##################################################################
|
||||
# Copyright 2007 (C) Kees Cook <kees@ubuntu.com>
|
||||
# License: GPLv2
|
||||
#
|
||||
# This script is used to repeat a change log into an older release. It
|
||||
# expects that --build-tree is laid out with each Ubuntu release as a
|
||||
@ -48,11 +30,11 @@ EOM
|
||||
exit(0);
|
||||
}
|
||||
|
||||
my @releases = undef;
|
||||
our $devel_release = undef;
|
||||
my @releases = ('dapper', 'edgy', 'feisty', 'gutsy', 'hardy');
|
||||
|
||||
#Getopt::Long::Configure("bundling", "no_ignore_case");
|
||||
our $opt_build_tree = "/scratch/ubuntu/build";
|
||||
our $opt_devel_release = $releases[$#releases];
|
||||
our $opt_pocket = undef;
|
||||
our $opt_package = undef;
|
||||
our $opt_source_release = undef;
|
||||
@ -71,10 +53,6 @@ Usage() unless (GetOptions(
|
||||
));
|
||||
Usage() if ($opt_help);
|
||||
|
||||
@releases = split(/\s+/, `ubuntu-distro-info --supported`);
|
||||
$devel_release = `ubuntu-distro-info --devel`;
|
||||
chomp($devel_release);
|
||||
|
||||
sub get_changelog($)
|
||||
{
|
||||
my ($path) = @_;
|
||||
@ -140,8 +118,8 @@ warn "package: '$opt_package\n" if ($opt_verbose);
|
||||
|
||||
# By default, take changelog from newer release
|
||||
if (!defined($opt_source_release)) {
|
||||
if ($opt_target_release eq $devel_release) {
|
||||
die "No more recent release than '$devel_release' to take changelog from\n";
|
||||
if ($opt_target_release eq $opt_devel_release) {
|
||||
die "No more recent release than '$opt_devel_release' to take changelog from\n";
|
||||
}
|
||||
foreach my $i (0 .. $#releases) {
|
||||
if ($releases[$i] eq $opt_target_release) {
|
||||
@ -153,11 +131,11 @@ if (!defined($opt_source_release)) {
|
||||
}
|
||||
}
|
||||
warn "source-release: '$opt_source_release\n" if ($opt_verbose);
|
||||
warn "devel-release: '$devel_release\n" if ($opt_verbose);
|
||||
warn "devel-release: '$opt_devel_release\n" if ($opt_verbose);
|
||||
|
||||
# By default, use "security" pocket for non-devel releases
|
||||
if (!defined($opt_pocket)) {
|
||||
if ($opt_target_release eq $devel_release) {
|
||||
if ($opt_target_release eq $opt_devel_release) {
|
||||
$opt_pocket = "";
|
||||
}
|
||||
else {
|
||||
|
1
debian/.gitignore
vendored
1
debian/.gitignore
vendored
@ -1 +0,0 @@
|
||||
files
|
49
debian/NEWS
vendored
49
debian/NEWS
vendored
@ -1,49 +0,0 @@
|
||||
ubuntu-dev-tools (0.135) unstable; urgency=low
|
||||
|
||||
reverse-build-depends was removed from ubuntu-dev-tools. reverse-depends -b
|
||||
is equivalent.
|
||||
|
||||
-- Stefano Rivera <stefanor@debian.org> Sat, 12 Nov 2011 13:11:21 +0200
|
||||
|
||||
ubuntu-dev-tools (0.131) unstable; urgency=low
|
||||
|
||||
get-build-deps was removed from ubuntu-dev-tools. The newer mk-build-deps in
|
||||
devscripts is equivalent (with the -ir options).
|
||||
|
||||
-- Stefano Rivera <stefanor@debian.org> Sat, 10 Sep 2011 00:13:18 +0200
|
||||
|
||||
ubuntu-dev-tools (0.129) unstable; urgency=low
|
||||
|
||||
Several tools that worked against Launchpad but were not specific to Ubuntu
|
||||
have been migrated to the "lptools" project.
|
||||
|
||||
The following tools have moved:
|
||||
- get-branches (renamed to lp-get-branches)
|
||||
- grab-attachments (renamed to lp-grab-attachments)
|
||||
- lp-project-upload
|
||||
- lp-list-bugs
|
||||
- lp-set-dup
|
||||
- lp-shell
|
||||
|
||||
They can now be found in the lptools package (version 0.0.1~bzr28-1 or
|
||||
later).
|
||||
|
||||
-- Jelmer Vernooij <jelmer@debian.org> Fri, 02 Sep 2011 13:43:34 +0200
|
||||
|
||||
ubuntu-dev-tools (0.119) unstable; urgency=low
|
||||
|
||||
launchpadlib 1.9 will cause some issues, as it uses the GNOME Keyring / KDE
|
||||
wallet to store credentials.
|
||||
https://help.launchpad.net/API/ThirdPartyIntegration
|
||||
|
||||
Known issues and workarounds:
|
||||
|
||||
Seeing keyring.backend.PasswordSetError or gnomekeyring.IOError when
|
||||
using ubuntu-dev-tools on a remote machine?
|
||||
Try ssh -X and run export `dbus-launch` in the ssh session.
|
||||
|
||||
Otherwise, uninstalling python-gnomekeyring will force the credentials to be
|
||||
stored in ~/keyring_pass.cfg instead of a keyring, and bypass all these
|
||||
issues.
|
||||
|
||||
-- Stefano Rivera <stefanor@debian.org> Tue, 01 Mar 2011 15:01:01 +0200
|
26
debian/README.source
vendored
26
debian/README.source
vendored
@ -1,26 +0,0 @@
|
||||
Changelog generation and releasing
|
||||
----------------------------------
|
||||
|
||||
The changelog is generated by the uploader using `gbp dch' from
|
||||
`git-buildpackage'. To invoke, just run
|
||||
|
||||
$ gbp dch
|
||||
|
||||
and then edit the changelog as appropriate - wrap lines, remove Signed-Off-By,
|
||||
and so on. Then finalise the changelog, e.g.
|
||||
|
||||
$ dch -D unstable --release ""
|
||||
|
||||
commit it
|
||||
|
||||
$ git commit debian/changelog -m "Releasing 0.foo"
|
||||
|
||||
and tag/sign this commit
|
||||
|
||||
$ gbp buildpackage --git-tag-only
|
||||
|
||||
then build using (for example)
|
||||
|
||||
$ gbp buildpackage -S
|
||||
|
||||
and test/upload as normal.
|
3614
debian/changelog
vendored
3614
debian/changelog
vendored
File diff suppressed because it is too large
Load Diff
1
debian/clean
vendored
1
debian/clean
vendored
@ -1 +0,0 @@
|
||||
*.egg-info/
|
1
debian/compat
vendored
Normal file
1
debian/compat
vendored
Normal file
@ -0,0 +1 @@
|
||||
5
|
165
debian/control
vendored
165
debian/control
vendored
@ -1,155 +1,24 @@
|
||||
Source: ubuntu-dev-tools
|
||||
Section: devel
|
||||
Priority: optional
|
||||
Maintainer: Ubuntu Developers <ubuntu-dev-tools@packages.debian.org>
|
||||
Uploaders:
|
||||
Benjamin Drung <bdrung@debian.org>,
|
||||
Stefano Rivera <stefanor@debian.org>,
|
||||
Mattia Rizzolo <mattia@debian.org>,
|
||||
Simon Quigley <tsimonq2@debian.org>,
|
||||
Build-Depends:
|
||||
black <!nocheck>,
|
||||
dctrl-tools,
|
||||
debhelper-compat (= 13),
|
||||
devscripts (>= 2.11.0~),
|
||||
dh-make,
|
||||
dh-python,
|
||||
distro-info (>= 0.2~),
|
||||
flake8,
|
||||
isort <!nocheck>,
|
||||
lsb-release,
|
||||
pylint <!nocheck>,
|
||||
python3-all,
|
||||
python3-apt,
|
||||
python3-dateutil,
|
||||
python3-debian,
|
||||
python3-debianbts,
|
||||
python3-distro-info,
|
||||
python3-httplib2,
|
||||
python3-launchpadlib-desktop,
|
||||
python3-pytest,
|
||||
python3-requests <!nocheck>,
|
||||
python3-setuptools,
|
||||
python3-yaml <!nocheck>,
|
||||
Standards-Version: 4.7.2
|
||||
Rules-Requires-Root: no
|
||||
Vcs-Git: https://git.launchpad.net/ubuntu-dev-tools
|
||||
Vcs-Browser: https://git.launchpad.net/ubuntu-dev-tools
|
||||
Homepage: https://launchpad.net/ubuntu-dev-tools
|
||||
Maintainer: Ubuntu MOTU Developers <ubuntu-motu@lists.ubuntu.com>
|
||||
Vcs-Bzr: http://bazaar.launchpad.net/~ubuntu-dev/ubuntu-dev-tools/trunk
|
||||
Vcs-Browser: http://codebrowse.launchpad.net/~ubuntu-dev/ubuntu-dev-tools/trunk/changes
|
||||
Build-Depends: cdbs (>= 0.4.49), debhelper (>= 5), python-all-dev (>= 2.4)
|
||||
Build-Depends-Indep: python-central (>= 0.5)
|
||||
XS-Python-Version: all
|
||||
Homepage: https://launchpad.net/ubuntu-dev-tools/
|
||||
Standards-Version: 3.7.3
|
||||
|
||||
Package: ubuntu-dev-tools
|
||||
Architecture: all
|
||||
Depends:
|
||||
binutils,
|
||||
dctrl-tools,
|
||||
devscripts (>= 2.11.0~),
|
||||
diffstat,
|
||||
distro-info (>= 0.2~),
|
||||
dpkg-dev,
|
||||
dput,
|
||||
lsb-release,
|
||||
python3,
|
||||
python3-apt,
|
||||
python3-debian,
|
||||
python3-debianbts,
|
||||
python3-distro-info,
|
||||
python3-httplib2,
|
||||
python3-launchpadlib-desktop,
|
||||
python3-lazr.restfulclient,
|
||||
python3-ubuntutools (= ${binary:Version}),
|
||||
python3-yaml,
|
||||
sensible-utils,
|
||||
sudo,
|
||||
tzdata,
|
||||
${misc:Depends},
|
||||
${perl:Depends},
|
||||
Recommends:
|
||||
arch-test,
|
||||
ca-certificates,
|
||||
debian-archive-keyring,
|
||||
debian-keyring,
|
||||
debootstrap,
|
||||
genisoimage,
|
||||
lintian,
|
||||
patch,
|
||||
sbuild | pbuilder | cowbuilder,
|
||||
python3-dns,
|
||||
quilt,
|
||||
reportbug (>= 3.39ubuntu1),
|
||||
ubuntu-keyring | ubuntu-archive-keyring,
|
||||
Suggests:
|
||||
bzr | brz,
|
||||
bzr-builddeb | brz-debian,
|
||||
qemu-user-static,
|
||||
Section: devel
|
||||
Depends: ${python:Depends}, binutils, devscripts, sudo, python-launchpad-bugs (>= 0.2.25), python-debian, dctrl-tools, lsb-release
|
||||
Recommends: bzr, pbuilder, reportbug (>= 3.39ubuntu1)
|
||||
Conflicts: devscripts (<< 2.10.7ubuntu5)
|
||||
Replaces: devscripts (<< 2.10.7ubuntu5)
|
||||
XB-Python-Version: ${python:Versions}
|
||||
Description: useful tools for Ubuntu developers
|
||||
This is a collection of useful tools that Ubuntu developers use to make their
|
||||
packaging work a lot easier.
|
||||
.
|
||||
Such tools include:
|
||||
.
|
||||
- backportpackage - helper to test package backports
|
||||
- bitesize - add the 'bitesize' tag to a bug and comment that you are
|
||||
willing to help fix it.
|
||||
- check-mir - check support status of build/binary dependencies
|
||||
- check-symbols - will compare and give you a diff of the exported symbols of
|
||||
all .so files in a binary package.
|
||||
- dch-repeat - used to repeat a change log into an older release.
|
||||
- grab-merge - grabs a merge from merges.ubuntu.com easily.
|
||||
- grep-merges - search for pending merges from Debian.
|
||||
- import-bug-from-debian - copy a bug from the Debian BTS to Launchpad
|
||||
- merge-changelog - manually merges two Debian changelogs with the same base
|
||||
version.
|
||||
- mk-sbuild - script to create LVM snapshot chroots via schroot and
|
||||
sbuild.
|
||||
- pbuilder-dist, cowbuilder-dist - wrapper script for managing several build
|
||||
chroots (for different Ubuntu and Debian releases) on the same system.
|
||||
- pull-debian-debdiff - attempts to find and download a specific version of
|
||||
a Debian package and its immediate parent to generate a debdiff.
|
||||
- pull-debian-source - downloads the latest source package available in
|
||||
Debian of a package.
|
||||
- pull-lp-source - downloads source package from Launchpad.
|
||||
- pull-lp-debs - downloads debs package(s) from Launchpad.
|
||||
- pull-lp-ddebs - downloads dbgsym/ddebs package(s) from Launchpad.
|
||||
- pull-lp-udebs - downloads udebs package(s) from Launchpad.
|
||||
- pull-debian-* - same as pull-lp-* but for Debian packages.
|
||||
- pull-uca-* - same as pull-lp-* but for Ubuntu Cloud Archive packages.
|
||||
- pull-pkg - common script that provides above pull-* functionality.
|
||||
- requestbackport - file a backporting request.
|
||||
- requestsync - files a sync request with Debian changelog and rationale.
|
||||
- reverse-depends - find the reverse dependencies (or build dependencies) of
|
||||
a package.
|
||||
- running-autopkgtests - lists the currently running and/or queued
|
||||
autopkgtests on the Ubuntu autopkgtest infrastructure
|
||||
- seeded-in-ubuntu - query if a package is safe to upload during a freeze.
|
||||
- setup-packaging-environment - assistant to get an Ubuntu installation
|
||||
ready for packaging work.
|
||||
- sponsor-patch - Downloads a patch from a Launchpad bug, patches the source
|
||||
package, and uploads it (to Ubuntu or a PPA)
|
||||
- submittodebian - automatically send your changes to Debian as a bug report.
|
||||
- syncpackage - helper to prepare .changes file to upload synced packages
|
||||
- ubuntu-build - give commands to the Launchpad build daemons from the
|
||||
command line.
|
||||
- ubuntu-iso - output information of an Ubuntu ISO image.
|
||||
- ubuntu-upload-permission - query / list the upload permissions for a
|
||||
package.
|
||||
- update-maintainer - script to update maintainer field in ubuntu packages.
|
||||
|
||||
Package: python3-ubuntutools
|
||||
Architecture: all
|
||||
Section: python
|
||||
Depends:
|
||||
python3-dateutil,
|
||||
python3-debian,
|
||||
python3-distro-info,
|
||||
python3-httplib2,
|
||||
python3-launchpadlib-desktop,
|
||||
python3-lazr.restfulclient,
|
||||
python3-requests,
|
||||
sensible-utils,
|
||||
${misc:Depends},
|
||||
${python3:Depends},
|
||||
Description: useful APIs for Ubuntu developer tools — Python 3 library
|
||||
This package ships a collection of APIs, helpers and wrappers used to
|
||||
develop useful utilities for Ubuntu developers.
|
||||
.
|
||||
This package installs the library for Python 3.
|
||||
This is a collection of useful tools that Ubuntu developers use to
|
||||
make their packaging work a lot easier. Such tools can include bug
|
||||
filing, packaging preparation, package analysis, etc.
|
||||
|
262
debian/copyright
vendored
262
debian/copyright
vendored
@ -1,204 +1,70 @@
|
||||
Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
|
||||
Upstream-Name: Ubuntu Developer Tools
|
||||
Upstream-Contact: Ubuntu Developers <ubuntu-devel-discuss@lists.ubuntu.com>
|
||||
Source: https://launchpad.net/ubuntu-dev-tools
|
||||
This package was re-debianized by Daniel Holbach <daniel.holbach@ubuntu.com> on
|
||||
Fri, 01 Jun 2007 11:30:08 +0200.
|
||||
|
||||
Files: backportpackage
|
||||
bash_completion/pbuilder-dist
|
||||
check-symbols
|
||||
debian/*
|
||||
doc/backportpackage.1
|
||||
doc/check-symbols.1
|
||||
doc/requestsync.1
|
||||
doc/ubuntu-iso.1
|
||||
doc/running-autopkgtests.1
|
||||
GPL-2
|
||||
README.updates
|
||||
requestsync
|
||||
setup.py
|
||||
TODO
|
||||
ubuntu-iso
|
||||
ubuntutools/requestsync/*.py
|
||||
Copyright: 2007, Albert Damen <albrt@gmx.net>
|
||||
2010-2024, Benjamin Drung <bdrung@ubuntu.com>
|
||||
2007-2023, Canonical Ltd.
|
||||
2006-2007, Daniel Holbach <daniel.holbach@ubuntu.com>
|
||||
2010, Evan Broder <evan@ebroder.net>
|
||||
2006-2007, Luke Yelavich <themuso@ubuntu.com>
|
||||
2009-2010, Michael Bienia <geser@ubuntu.com>
|
||||
2024-2025, Simon Quigley <tsimonq2@debian.org>
|
||||
2010-2011, Stefano Rivera <stefanor@ubuntu.com>
|
||||
2008, Stephan Hermann <sh@sourcecode.de>
|
||||
2007, Steve Kowalik <stevenk@ubuntu.com>
|
||||
License: GPL-2
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
Upstream Authors:
|
||||
|
||||
Albert Damen <albrt@gmx.net>
|
||||
Albin Tonnerre <lut1n.tne@gmail.com>
|
||||
Daniel Holbach <daniel.holbach@ubuntu.com>
|
||||
Jamin W. Collins <jcollins@asgardsrealm.net>
|
||||
Jordan Mantha <mantha@ubuntu.com>
|
||||
Luke Yelavich <themuso@ubuntu.com>
|
||||
Martin Pitt <martin.pitt@ubuntu.com>
|
||||
Michael Bienia <geser@ubuntu.com>
|
||||
Pete Savage <petesavage@ubuntu.com>
|
||||
Kees Cook <kees@ubuntu.com>
|
||||
Siegfried-A. Gevatter <rainct@ubuntu.com>
|
||||
Soren Hansen <soren@ubuntu.com>
|
||||
Steve Kowalik <stevenk@ubuntu.com>
|
||||
Terence Simpson <stdin@stdin.me.uk>
|
||||
|
||||
Copyright:
|
||||
|
||||
Canonical Ltd. 2006-2008
|
||||
Albert Damen <albrt@gmx.net> 2007
|
||||
Albin Tonnerre <lut1n.tne@gmail.com> 2006-2007
|
||||
Daniel Holbach <daniel.holbach@ubuntu.com> 2006-2007
|
||||
Luke Yelavich <themuso@ubuntu.com> 2006-2007
|
||||
Martin Pitt <martin.pitt@ubuntu.com> 2007
|
||||
Michael Bienia <geser@ubuntu.com> 2006-2007
|
||||
Kees Cook <kees@ubuntu.com> 2006-2008
|
||||
Pete Savage <petesavage@ubuntu.com> 2006-2007
|
||||
Siegfried-A. Gevatter <rainct@ubuntu.com> 2007-2008
|
||||
Terence Simpson <stdin@stdin.me.uk> 2007
|
||||
|
||||
Licenses:
|
||||
|
||||
404main, check-symbols, dch-repeat, dgetlp, mk-sbuild-lv, pbuilder-dist,
|
||||
pull-debian-debdiff, requestsync, reverse-build-depends, submittodebian,
|
||||
update-maintainer and what-patch are licensed under GPLv2:
|
||||
|
||||
This package is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, version 2 of the License.
|
||||
.
|
||||
the Free Software Foundation, at version 2.
|
||||
|
||||
This package is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
On Debian systems, the complete text of the GNU General Public License v2
|
||||
can be found in `/usr/share/common-licenses/GPL-2'.
|
||||
|
||||
get-branches, get-build-deps, massfile, ppaput and suspicious-source
|
||||
are licensed under GPLv3:
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, at version 3.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
General Public License for more details.
|
||||
.
|
||||
On Debian systems, the complete text of the GNU General Public License
|
||||
version 2 can be found in the /usr/share/common-licenses/GPL-2 file.
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
Files: doc/import-bug-from-debian.1
|
||||
doc/pbuilder-dist-simple.1
|
||||
doc/pbuilder-dist.1
|
||||
doc/submittodebian.1
|
||||
import-bug-from-debian
|
||||
pbuilder-dist
|
||||
pbuilder-dist-simple
|
||||
submittodebian
|
||||
Copyright: 2007-2010, Canonical Ltd.
|
||||
2009, James Westby <james.westby@ubuntu.com>
|
||||
2008, Jamin W. Collins <jcollins@asgardsrealm.net>
|
||||
2008, Jordan Mantha <mantha@ubuntu.com>
|
||||
2006-2007, Pete Savage <petesavage@ubuntu.com>
|
||||
2009, Ryan Kavanagh <ryanakca@kubuntu.org>
|
||||
2007, Siegfried-Angel Gevatter Pujals <rainct@ubuntu.com>
|
||||
2010-2011, Stefano Rivera <stefanor@ubuntu.com>
|
||||
2008, Terence Simpson <tsimpson@ubuntu.com>
|
||||
License: GPL-2+
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
.
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
General Public License for more details.
|
||||
.
|
||||
On Debian systems, the complete text of the GNU General Public License
|
||||
version 2 can be found in the /usr/share/common-licenses/GPL-2 file.
|
||||
On Debian systems, the complete text of the GNU General Public License v3
|
||||
can be found in `/usr/share/common-licenses/GPL-3'.
|
||||
|
||||
Files: doc/lp-bitesize.1
|
||||
doc/check-mir.1
|
||||
doc/grab-merge.1
|
||||
doc/merge-changelog.1
|
||||
doc/pm-helper.1
|
||||
doc/setup-packaging-environment.1
|
||||
doc/syncpackage.1
|
||||
lp-bitesize
|
||||
check-mir
|
||||
GPL-3
|
||||
grab-merge
|
||||
merge-changelog
|
||||
pm-helper
|
||||
pyproject.toml
|
||||
run-linters
|
||||
running-autopkgtests
|
||||
setup-packaging-environment
|
||||
syncpackage
|
||||
ubuntutools/running_autopkgtests.py
|
||||
ubuntutools/utils.py
|
||||
Copyright: 2010-2024, Benjamin Drung <bdrung@ubuntu.com>
|
||||
2007-2024, Canonical Ltd.
|
||||
2008, Jonathan Patrick Davies <jpds@ubuntu.com>
|
||||
2008-2010, Martin Pitt <martin.pitt@canonical.com>
|
||||
2009, Siegfried-Angel Gevatter Pujals <rainct@ubuntu.com>
|
||||
2010-2011, Stefano Rivera <stefanor@ubuntu.com>
|
||||
License: GPL-3
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, version 3 of the License.
|
||||
.
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
General Public License for more details.
|
||||
.
|
||||
On Debian systems, the complete text of the GNU General Public License
|
||||
version 3 can be found in the /usr/share/common-licenses/GPL-3 file.
|
||||
|
||||
Files: dch-repeat
|
||||
doc/dch-repeat.1
|
||||
doc/grep-merges.1
|
||||
doc/mk-sbuild.1
|
||||
doc/pull-pkg.1
|
||||
doc/ubuntu-build.1
|
||||
grep-merges
|
||||
mk-sbuild
|
||||
pull-pkg
|
||||
pull-*debs
|
||||
pull-*-source
|
||||
requirements.txt
|
||||
test-requirements.txt
|
||||
tox.ini
|
||||
ubuntu-build
|
||||
ubuntutools/__init__.py
|
||||
ubuntutools/lp/__init__.py
|
||||
ubuntutools/lp/lpapicache.py
|
||||
ubuntutools/lp/udtexceptions.py
|
||||
ubuntutools/misc.py
|
||||
ubuntutools/pullpkg.py
|
||||
Copyright: 2007-2010, Canonical Ltd.
|
||||
2008-2009, Iain Lane <iain@orangesquash.org.uk>
|
||||
2006, John Dong <jdong@ubuntu.com>
|
||||
2009, Jonathan Davies <jpds@ubuntu.com>
|
||||
2009, Markus Korn <thekorn@gmx.de>
|
||||
2009-2010, Michael Bienia <geser@ubuntu.com>
|
||||
2009, Nathan Handler <nhandler@ubuntu.com>
|
||||
2007-2008, Siegfried-Angel Gevatter Pujals <rainct@ubuntu.com>
|
||||
2010-2012, Stefano Rivera <stefanor@ubuntu.com>
|
||||
2012, Steve Langasek <steve.langasek@ubuntu.com>
|
||||
License: GPL-3+
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
.
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
General Public License for more details.
|
||||
.
|
||||
On Debian systems, the complete text of the GNU General Public License
|
||||
version 3 can be found in the /usr/share/common-licenses/GPL-3 file.
|
||||
|
||||
Files: doc/pull-debian-debdiff.1
|
||||
doc/requestbackport.1
|
||||
doc/reverse-depends.1
|
||||
doc/seeded-in-ubuntu.1
|
||||
doc/sponsor-patch.1
|
||||
doc/ubuntu-dev-tools.5
|
||||
doc/ubuntu-upload-permission.1
|
||||
doc/update-maintainer.1
|
||||
enforced-editing-wrapper
|
||||
pull-debian-debdiff
|
||||
requestbackport
|
||||
reverse-depends
|
||||
seeded-in-ubuntu
|
||||
sponsor-patch
|
||||
ubuntu-upload-permission
|
||||
ubuntutools/archive.py
|
||||
ubuntutools/builder.py
|
||||
ubuntutools/config.py
|
||||
ubuntutools/question.py
|
||||
ubuntutools/rdepends.py
|
||||
ubuntutools/sponsor_patch/*
|
||||
ubuntutools/test/*
|
||||
ubuntutools/update_maintainer.py
|
||||
ubuntutools/version.py
|
||||
update-maintainer
|
||||
.pylintrc
|
||||
Copyright: 2009-2024, Benjamin Drung <bdrung@ubuntu.com>
|
||||
2010, Evan Broder <evan@ebroder.net>
|
||||
2008, Siegfried-Angel Gevatter Pujals <rainct@ubuntu.com>
|
||||
2010-2011, Stefano Rivera <stefanor@ubuntu.com>
|
||||
2017-2021, Dan Streetman <ddstreet@canonical.com>
|
||||
2024, Canonical Ltd.
|
||||
License: ISC
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
.
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
||||
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
||||
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
||||
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
||||
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
||||
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
||||
PERFORMANCE OF THIS SOFTWARE.
|
||||
The following of the scripts can be used, at your option, regarding any
|
||||
later version of the previously specified license: 404main, pbuilder-dist,
|
||||
dgetlp, reverse-build-depends, suspicious-source and get-build-deps.
|
||||
|
9
debian/gbp.conf
vendored
9
debian/gbp.conf
vendored
@ -1,9 +0,0 @@
|
||||
[DEFAULT]
|
||||
debian-tag = %(version)s
|
||||
debian-branch = master
|
||||
sign-tags = True
|
||||
|
||||
[dch]
|
||||
meta = True
|
||||
auto = True
|
||||
full = True
|
2
debian/links
vendored
2
debian/links
vendored
@ -1,2 +0,0 @@
|
||||
/usr/bin/pbuilder-dist /usr/bin/cowbuilder-dist
|
||||
/usr/share/man/man1/pbuilder-dist.1.gz /usr/share/man/man1/cowbuilder-dist.1.gz
|
1
debian/python3-ubuntutools.install
vendored
1
debian/python3-ubuntutools.install
vendored
@ -1 +0,0 @@
|
||||
/usr/lib/python3.*
|
17
debian/rules
vendored
17
debian/rules
vendored
@ -1,14 +1,11 @@
|
||||
#!/usr/bin/make -f
|
||||
|
||||
override_dh_auto_clean:
|
||||
dh_auto_clean
|
||||
rm -f .coverage
|
||||
rm -rf .tox
|
||||
DEB_PYTHON_SYSTEM := pycentral
|
||||
|
||||
override_dh_auto_test:
|
||||
ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
|
||||
python3 -m pytest -v ubuntutools
|
||||
endif
|
||||
include /usr/share/cdbs/1/rules/debhelper.mk
|
||||
include /usr/share/cdbs/1/class/python-distutils.mk
|
||||
|
||||
%:
|
||||
dh $@ --with python3 --buildsystem=pybuild
|
||||
DEB_INSTALL_MANPAGES_ubuntu-dev-tools = doc/*.1
|
||||
|
||||
binary-install/ubuntu-dev-tools::
|
||||
rm -rf debian/ubuntu-dev-tools/usr/lib
|
||||
|
3
debian/source.lintian-overrides
vendored
Normal file
3
debian/source.lintian-overrides
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
# Override useless NMU warnings; this is a native Ubuntu package.
|
||||
ubuntu-dev-tools source: changelog-should-mention-nmu
|
||||
ubuntu-dev-tools source: source-nmu-has-incorrect-version-number
|
1
debian/source/format
vendored
1
debian/source/format
vendored
@ -1 +0,0 @@
|
||||
3.0 (native)
|
3
debian/source/lintian-overrides
vendored
3
debian/source/lintian-overrides
vendored
@ -1,3 +0,0 @@
|
||||
# pyc files are machine-generated; they're expected to have long lines and have unstated copyright
|
||||
source: file-without-copyright-information *.pyc [debian/copyright]
|
||||
source: very-long-line-length-in-source-file * > 512 [*.pyc:*]
|
7
debian/tests/control
vendored
7
debian/tests/control
vendored
@ -1,7 +0,0 @@
|
||||
Test-Command: python3 -m pytest -v ubuntutools
|
||||
Depends:
|
||||
dh-make,
|
||||
python3-pytest,
|
||||
python3-setuptools,
|
||||
@,
|
||||
Restrictions: allow-stderr
|
1
debian/ubuntu-dev-tools.examples
vendored
Normal file
1
debian/ubuntu-dev-tools.examples
vendored
Normal file
@ -0,0 +1 @@
|
||||
examples/*
|
3
debian/ubuntu-dev-tools.install
vendored
3
debian/ubuntu-dev-tools.install
vendored
@ -1,2 +1 @@
|
||||
/usr/bin
|
||||
/usr/share
|
||||
bash_completion/* etc/bash_completion.d/
|
||||
|
169
dgetlp
Executable file
169
dgetlp
Executable file
@ -0,0 +1,169 @@
|
||||
#!/bin/bash
|
||||
# Copyright (C) 2008 Terence Simpson <tsimpson@ubuntu.com>
|
||||
# Modified by Siegfried-A. Gevatter <rainct@ubuntu.com>
|
||||
# License:
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; either version 2 of the License, or
|
||||
# (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License along
|
||||
# with this program; if not, write to the Free Software Foundation, Inc.,
|
||||
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
#
|
||||
# This script simulates «dget»'s behaviour for files hosted at
|
||||
# launchpadlibrarian.net.
|
||||
#
|
||||
# Detailed description:
|
||||
# This script attempts to download the source package in the same
|
||||
# way as dget does, but from launchpadlibrarian.net, which doesn't
|
||||
# store all the files in the same directory. It (the script) assumes
|
||||
# that the files are stored in sequential directories on Launchpad
|
||||
# Librarian and attemps to download and then unpack them.
|
||||
|
||||
GET="wget"
|
||||
UNPACK="dpkg-source -x {dsc-file}"
|
||||
DIRECT_TO_NULL="/dev/null"
|
||||
|
||||
usage()
|
||||
{
|
||||
cat << EOF
|
||||
Usage: $0 [-d] <Launchpad URL>
|
||||
|
||||
This scripts simulates «dget»'s behaviour for files hostead at
|
||||
launchpadlibrarian.net.
|
||||
|
||||
If you specify the -d option then it won't do anything, except download the
|
||||
.dsc file, but just print the commands it would run otherwise.
|
||||
|
||||
Example:
|
||||
$(basename $0) http://launchpadlibrarian.net/10348157/coreutils_5.97-5.4ubuntu1.dsc
|
||||
EOF
|
||||
}
|
||||
|
||||
while [ $# -ne 1 ]; do
|
||||
case "$1" in
|
||||
-d|--debug)
|
||||
# Debug Mode
|
||||
OUTPUT="/tmp/"
|
||||
GET="echo ${GET}"
|
||||
UNPACK="echo ${UNPACK}"
|
||||
shift
|
||||
;;
|
||||
-v|--verbose)
|
||||
DIRECT_TO_NULL="$(tty)"
|
||||
shift
|
||||
;;
|
||||
-h|--help)
|
||||
usage
|
||||
exit 0
|
||||
;;
|
||||
-*)
|
||||
echo "Unknown option: \`$1'"
|
||||
usage >&2
|
||||
exit 1
|
||||
;;
|
||||
*)
|
||||
break
|
||||
;;
|
||||
esac
|
||||
done
|
||||
|
||||
if [ $# -ne 1 ]
|
||||
then
|
||||
usage
|
||||
exit 1
|
||||
fi
|
||||
|
||||
## internal functions
|
||||
getBase() {
|
||||
echo "Getting ${BASE}/${NUMBER}/${FILE}"
|
||||
if [ -f "$FILE" ]; then rm -f $FILE; fi # Remove .dsc incase the last run was with debug
|
||||
if ! wget ${BASE}/${NUMBER}/${FILE} -O ${OUTPUT}${FILE} 2>${DIRECT_TO_NULL}
|
||||
then
|
||||
echo "Failed to fetch «.dsc» file, aborting."
|
||||
exit 1
|
||||
fi
|
||||
}
|
||||
|
||||
getUrl() {
|
||||
if [ -f "$2" ]
|
||||
then
|
||||
##Todo: Check the md5sum in the .dsc to see if we should redownload or not
|
||||
echo "Skipping already downloaded ${2}"
|
||||
return 0
|
||||
fi
|
||||
|
||||
echo "Getting ${1}${2}"
|
||||
if ! $GET ${1}${2} 2>$DIRECT_TO_NULL
|
||||
then
|
||||
echo "Failed to fetch «${3}»"
|
||||
exit 1
|
||||
fi
|
||||
}
|
||||
|
||||
unpack() {
|
||||
if ! $UNPACK
|
||||
then
|
||||
echo "Failed to unpack source, aborting."
|
||||
exit 1
|
||||
fi
|
||||
}
|
||||
|
||||
## begin #!/bin/bash
|
||||
|
||||
# Store download URL into a local variable to be able to modify it
|
||||
URL=$1
|
||||
|
||||
if [ ${URL:0:4} == 'www.' ]
|
||||
then
|
||||
URL="http://"${URL:4}
|
||||
fi
|
||||
|
||||
if [ ${URL:0:7} != 'http://' ]
|
||||
then
|
||||
URL="http://"$URL
|
||||
fi
|
||||
|
||||
if [ ${URL:0:30} != 'http://launchpadlibrarian.net/' ]
|
||||
then
|
||||
echo "Error: This utility only works for files on launchpadlibrarian.net."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ ${URL##*.} != 'dsc' ]
|
||||
then
|
||||
echo "You have to provide the URL for the .dsc file."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
#BASE="http://$(echo $URL|cut -d '/' -f 3)" #Not needed as we know the base URL
|
||||
BASE="http://launchpadlibrarian.net"
|
||||
NUMBER="$(echo $URL|cut -d '/' -f 4)"
|
||||
FILE="$(echo $URL|cut -d '/' -f 5)"
|
||||
|
||||
UNPACK=$(echo $UNPACK | sed s/{dsc-file}/${FILE}/g)
|
||||
|
||||
if [ -f "$FILE" ]; then rm -f $FILE; fi
|
||||
getBase;
|
||||
PkgVersion="$(grep -B100 "^Files:" ${OUTPUT}${FILE}|grep "^Version:"|cut -d' ' -f2)"
|
||||
PkgName="$(grep -B100 "^Files:" ${OUTPUT}${FILE}|grep "^Source:"|cut -d' ' -f2)"
|
||||
|
||||
if $(echo ${PkgVersion} | grep '-' >/dev/null)
|
||||
then
|
||||
getUrl ${BASE}/$((${NUMBER}-1))/ "$(echo $FILE|sed 's,\.dsc,.diff.gz,')" "diff.gz"
|
||||
getUrl ${BASE}/$((${NUMBER}-2))/ "${PkgName}_$(echo ${PkgVersion}|sed 's,-[0-9]*[a-z]*[0-9]*,.orig.tar.gz,')" "orig.tar.gz"
|
||||
else
|
||||
getUrl ${BASE}/$((${NUMBER}-1))/ "${PkgName}_${PkgVersion}.tar.gz" "tar.gz"
|
||||
fi
|
||||
|
||||
if [ "x${OUTPUT}" != "x" ]
|
||||
then rm -f ${OUTPUT}${FILE}
|
||||
fi
|
||||
|
||||
unpack;
|
29
doc/404main.1
Normal file
29
doc/404main.1
Normal file
@ -0,0 +1,29 @@
|
||||
.TH 404main 1 "February 17, 2008" "ubuntu-dev-tools"
|
||||
|
||||
.SH NAME
|
||||
404main \- check if all build dependencies of a package are in main
|
||||
|
||||
.SH SYNOPSIS
|
||||
\fB404main\fP <\fIpackage name\fP> [<\fIdistribution\fP>]
|
||||
|
||||
.SH DESCRIPTION
|
||||
\fB404main\fP is a script that can be used to check if a package and
|
||||
all its build dependencies are in Ubuntu's main component or not.
|
||||
|
||||
.SH CAVEATS
|
||||
\fB404main\fP will take the dependencies and build dependencies of the
|
||||
packages from the distribution you have first in your
|
||||
/etc/apt/sources.list file.
|
||||
.PP
|
||||
Also, because of this the <\fIdistribution\fP> option is NOT trustful, if
|
||||
the dependencies changed YOU WILL GET INCORRECT RESULTS.
|
||||
|
||||
.SH SEE ALSO
|
||||
.BR apt-cache (8)
|
||||
|
||||
.SH AUTHORS
|
||||
\fB404main\fP was written by Pete Savage <petesavage@ubuntu.com> and
|
||||
this manpage by Siegfried-Angel Gevatter Pujals <rainct@ubuntu.com>.
|
||||
.PP
|
||||
Both are released under the GNU General Public License, version 2 or
|
||||
later.
|
@ -1,190 +0,0 @@
|
||||
.TH BACKPORTPACKAGE "1" "December 2010" "ubuntu-dev-tools"
|
||||
.SH NAME
|
||||
backportpackage \- helper to test package backports
|
||||
.SH SYNOPSIS
|
||||
.TP
|
||||
.B backportpackage \fR[\fIadditional options\fR]
|
||||
\-\-upload <\fIupload target\fR>
|
||||
.br
|
||||
<\fIsource package name or .dsc URL/file\fR>
|
||||
.PP
|
||||
.B backportpackage \-h
|
||||
.SH DESCRIPTION
|
||||
\fBbackportpackage\fR fetches a package from one distribution release
|
||||
or from a specified .dsc path or URL and creates a no-change backport
|
||||
of that package to one or more Ubuntu releases release, optionally
|
||||
doing a test build of the package and/or uploading the resulting
|
||||
backport for testing.
|
||||
.PP
|
||||
Unless a working directory is specified, the backported package is
|
||||
fetched and built in a temporary directory in \fB/tmp\fR, which is
|
||||
removed once the script finishes running.
|
||||
.PP
|
||||
\fBbackportpackage\fR is only recommended for testing backports in a
|
||||
PPA, not uploading backports to the Ubuntu archive.
|
||||
.SH OPTIONS
|
||||
.TP
|
||||
.B \-d \fIDEST\fR, \fB\-\-destination\fR=\fIDEST\fR
|
||||
Backport the package to the specified Ubuntu release. If this option
|
||||
is unspecified, then \fBbackportpackage\fR defaults to the release on
|
||||
which it is currently running.
|
||||
.TP
|
||||
.B \-s \fISOURCE\fR, \fB\-\-source\fR=\fISOURCE\fR
|
||||
Backport the package from the specified release, which can be any
|
||||
release of your distribution or any of your distribution's parent
|
||||
distributions. If neither this option nor \fB\-\-version\fR are
|
||||
specified, then \fBbackportpackage\fR defaults to the current
|
||||
development release for your distribution.
|
||||
.TP
|
||||
.B \-S \fISUFFIX\fR, \fB\-\-suffix\fR=\fISUFFIX\fR
|
||||
Add the specified suffix to the version number when
|
||||
backporting. \fBbackportpackage\fR will always append
|
||||
~ubuntu\fIDESTINATION\fR.1 to the original version number, and if
|
||||
\fISUFFIX\fR is specified, it is appended to that, to get version
|
||||
numbers of the form
|
||||
\fIORIGINAL_VERSION\fR~ubuntu\fIDESTINATION\fR.1\fISUFFIX\fR. If the
|
||||
backported package is being uploaded to a PPA, then \fISUFFIX\fR
|
||||
defaults to \fB~ppa1\fR, otherwise the default is blank.
|
||||
.TP
|
||||
.B \-b\fR, \fB\-\-build
|
||||
Build the package with the specified builder before uploading. Note
|
||||
for \fBcowbuilder\fR(8) and \fBpbuilder\fR(8) users:
|
||||
This assumes the common configuration,
|
||||
where the \fBARCH\fR and \fBDIST\fR environment is read by \fBpbuilderrc\fR(5)
|
||||
to select the correct base image.
|
||||
.TP
|
||||
.B \-B \fIBUILDER\fR, \fB\-\-builder\fR=\fIBUILDER
|
||||
Use the specified builder to build the package. Supported are
|
||||
\fBcowbuilder\fR(8), \fBcowbuilder-dist\fR(1), \fBpbuilder\fR(8),
|
||||
\fBpbuilder-dist\fR(1), and \fBsbuild\fR(1).
|
||||
The default is \fBpbuilder\fR(8).
|
||||
.TP
|
||||
.B \-U\fR, \fB\-\-update
|
||||
Update the build environment before attempting to build.
|
||||
.TP
|
||||
.B \-u \fIUPLOAD\fR, \fB\-\-upload\fR=\fIUPLOAD\fR
|
||||
Upload to \fIUPLOAD\fR with \fBdput\fR(1) (after confirmation).
|
||||
.TP
|
||||
.B \-k \fIKEYID\fR, \fB\-\-key\fR=\fIKEYID\fR
|
||||
Specify the key ID to be used for signing.
|
||||
.TP
|
||||
.B \-\-dont\-sign
|
||||
Do not sign the upload.
|
||||
.TP
|
||||
.B \-y\fR, \fB\-\-yes
|
||||
Do not prompt before uploading to a PPA. For everyone's safety, this
|
||||
option is ignored if \fIUPLOAD\fR is \fBubuntu\fR.
|
||||
.TP
|
||||
.B \-v \fIVERSION\fR, \fB\-\-version\fR=\fIVERSION\fR
|
||||
If the \fB\-\-source\fR option is specified, then
|
||||
\fBbackportpackage\fR verifies that the current version of \fIsource
|
||||
package\fR in \fISOURCE\fR is the same as \fIVERSION\fR. Otherwise,
|
||||
\fBbackportpackage\fR finds version \fIVERSION\fR of \fIsource
|
||||
package\fR in your distribution's publishing history, regardless of
|
||||
the release in which it was published (or if that version is still
|
||||
current). This option is ignored if a .dsc URL or path is passed in
|
||||
instead of a source package name.
|
||||
.TP
|
||||
.B \-w \fIWORKDIR\fR, \fB\-\-workdir\fR=\fIWORKDIR\fR
|
||||
If \fIWORKDIR\fR is specified, then all files are downloaded,
|
||||
unpacked, built into, and otherwise manipulated in
|
||||
\fIWORKDIR\fR. Otherwise, a temporary directory is created, which is
|
||||
deleted before \fIbackportpackage\fR exits.
|
||||
.TP
|
||||
.B \-r\fR, \fB\-\-release\-pocket
|
||||
Target the upload at the release pocket, rather than the
|
||||
\fB\-backports\fR pocket.
|
||||
This is required for Launchpad PPAs, which are pocket-less (and the
|
||||
default, when the upload target is a PPA).
|
||||
.TP
|
||||
.B \-m \fIMIRROR\fR, \fB\-\-mirror\fR=\fIMIRROR\fR
|
||||
Use the specified mirror.
|
||||
Should be in the form \fBhttp://archive.ubuntu.com/ubuntu\fR.
|
||||
If the package isn't found on this mirror, \fBbackportpackage\fR
|
||||
will use Launchpad.
|
||||
.TP
|
||||
.B \-c \fIBUG\fR, \fB\-\-close\fR=\fIBUG\fR
|
||||
Include a Launchpad closer for the specified bug in the auto-generated
|
||||
changelog. In the future, this may actually close the bug, but
|
||||
currently does not.
|
||||
.TP
|
||||
.B \-l \fIINSTANCE\fR, \fB\-\-lpinstance\fR=\fIINSTANCE\fR
|
||||
Use the specified instance of Launchpad (e.g. "staging"), instead of
|
||||
the default of "production".
|
||||
.TP
|
||||
.B \-\-no\-conf
|
||||
Do not read any configuration files, or configuration from environment
|
||||
variables.
|
||||
.SH ENVIRONMENT
|
||||
.TP
|
||||
.BR DEBFULLNAME ", " DEBEMAIL ", " UBUMAIL
|
||||
Used to determine the uploader (if not supplied as options).
|
||||
See
|
||||
.BR ubuntu\-dev\-tools (5)
|
||||
for details.
|
||||
.P
|
||||
All of the \fBCONFIGURATION VARIABLES\fR below are also supported as
|
||||
environment variables.
|
||||
Variables in the environment take precedence to those in configuration
|
||||
files.
|
||||
.SH CONFIGURATION VARIABLES
|
||||
The following variables can be set in the environment or in
|
||||
.BR ubuntu\-dev\-tools (5)
|
||||
configuration files.
|
||||
In each case, the script\-specific variable takes precedence over the
|
||||
package\-wide variable.
|
||||
.TP
|
||||
.BR BACKPORTPACKAGE_BUILDER ", " UBUNTUTOOLS_BUILDER
|
||||
The default value for \fB\-\-builder\fR.
|
||||
.TP
|
||||
.BR BACKPORTPACKAGE_UPDATE_BUILDER ", " UBUNTUTOOLS_UPDATE_BUILDER
|
||||
The default value for \fB--update\fR.
|
||||
.TP
|
||||
.B BACKPORTPACKAGE_UPLOAD
|
||||
The default value for \fB--upload\fR.
|
||||
.TP
|
||||
.BR BACKPORTPACKAGE_WORKDIR ", " UBUNTUTOOLS_WORKDIR
|
||||
The default value for \fB--workdir\fR.
|
||||
.TP
|
||||
.BR BACKPORTPACKAGE_UBUNTU_MIRROR ", " UBUNTUTOOLS_UBUNTU_MIRROR
|
||||
The default value for \fB\-\-mirror\fR if the specified \fISOURCE\fR
|
||||
release is an Ubuntu release.
|
||||
.TP
|
||||
.BR BACKPORTPACKAGE_DEBIAN_MIRROR ", " UBUNTUTOOLS_DEBIAN_MIRROR
|
||||
The default value for \fB\-\-mirror\fR if the specified \fISOURCE\fR
|
||||
release is a Debian release.
|
||||
.TP
|
||||
.BR BACKPORTPACKAGE_LPINSTANCE ", " UBUNTUTOOLS_LPINSTANCE
|
||||
The default value for \fB--lpinstance\fR.
|
||||
.SH EXAMPLES
|
||||
Test-build in your PPA a backport of znc from the current development
|
||||
release to your workstation's release, deleting the build products
|
||||
afterwards:
|
||||
.IP
|
||||
.nf
|
||||
.B backportpackage -u ppa:\fIuser\fR/\fIppa\fB znc
|
||||
.fi
|
||||
.PP
|
||||
Backport squashfs-tools from Maverick to both Karmic and Lucid and
|
||||
test-build both locally, leaving all build products in the current
|
||||
working directory:
|
||||
.IP
|
||||
.nf
|
||||
.B backportpackage -b -s maverick -d karmic -d lucid -w . \\\\
|
||||
.B " "squashfs-tools
|
||||
.fi
|
||||
.PP
|
||||
Fetch a package from a PPA, backport it to Hardy, then upload it back
|
||||
to the same PPA:
|
||||
.IP
|
||||
.nf
|
||||
.B backportpackage -d hardy -u ppa:\fIuser\fR/\fIppa\fR \\\\
|
||||
.B " "https://launchpad.net/\fIsome/file.dsc\fR
|
||||
.fi
|
||||
.SH SEE ALSO
|
||||
.BR ubuntu\-dev\-tools (5)
|
||||
.SH AUTHOR
|
||||
\fBbackportpackage\fR and this manpage were written by Evan Broder
|
||||
<evan@ebroder.net>
|
||||
.PP
|
||||
Both are released under GNU General Public License, version 2.
|
@ -1,18 +0,0 @@
|
||||
.TH check\-mir "1" "13 January 2011" "ubuntu-dev-tools"
|
||||
.SH NAME
|
||||
check\-mir \- check support status of dependencies
|
||||
|
||||
.SH SYNOPSIS
|
||||
.B check\-mir
|
||||
|
||||
.SH DESCRIPTION
|
||||
This script checks if any of a package's build or binary dependencies is
|
||||
in universe/multiverse. If the source package is destined for Ubuntu main or
|
||||
restricted, these either need to be eliminated or need to be promoted to main,
|
||||
following \fBhttps://wiki.ubuntu.com/MainInclusionProcess\fR.
|
||||
|
||||
There are no options, just run it in a source package directory.
|
||||
|
||||
.SH AUTHOR
|
||||
.B check\-mir
|
||||
was written by Martin Pitt <martin.pitt@ubuntu.com>.
|
@ -8,36 +8,36 @@ check\-symbols \- verify symbols exported by a new library version
|
||||
|
||||
.SH "DESCRIPTION"
|
||||
To verify the symbols exported by a new library version, run
|
||||
\fBcheck\-symbols\fP with the name of the source package as argument.
|
||||
\fBcheck\-symbols\fP will first determine the symbols exported by the
|
||||
existing and installed library version, then install the new library and
|
||||
compare the symbols exported by the new library version with the symbols
|
||||
exported by the old version.
|
||||
For each of the symbols found, \fBcheck\-symbols\fP will list if the symbol
|
||||
is new, unchanged or has been removed in the new library version.
|
||||
\fBcheck-symbols\fP with the name of the source package as argument.
|
||||
\fBcheck-symbols\fP will first determine the symbols exported by the existing
|
||||
and installed libary version, then install the new library and compare the
|
||||
symbols exported by the new library version with the symbols exported
|
||||
by the old version. For each of the symbols found, \fBcheck-symbols\fP
|
||||
will list if the symbol is new, unchanged or has been removed in the
|
||||
new library version.
|
||||
.PP
|
||||
In case the source package contains multiple binary library packages,
|
||||
all library files in each of the binary packages will be verified.
|
||||
.PP
|
||||
\fBcheck\-symbols\fP uses \fBnm\fP \-D to determine
|
||||
\fBcheck\-symbols\fP uses \fBnm\fP -D to determine
|
||||
the exported symbols of the libraries.
|
||||
.PP
|
||||
If no value is given for DEBDIR, the script will assume the new library
|
||||
deb files are stored in /var/cache/pbuilder/result.
|
||||
|
||||
.SH "EXAMPLES"
|
||||
\fBcheck\-symbols\fP telepathy\-glib .
|
||||
\fBcheck\-symbols\fP telepathy-glib .
|
||||
.TP
|
||||
This will:
|
||||
.RS 2
|
||||
.TP 2
|
||||
\(bu Use \fBnm\fP \-D to determine the exported symbols of the old,
|
||||
\(bu Use \fBnm\fP -D to determine the exported symbols of the old,
|
||||
installed versions of the libraries provided by telepathy\-glib.
|
||||
.TP 2
|
||||
\(bu Install the binary libraries provided by the new version of
|
||||
\(bu Install the binary libaries provided by the new version of
|
||||
telepathy\-glib.
|
||||
.TP 2
|
||||
\(bu Compare the output of \fBnm\fP \-D of the new libraries with the
|
||||
\(bu Compare the output of \fBnm\fP -D of the new libraries with the
|
||||
output of the old version.
|
||||
.TP 2
|
||||
\(bu List the result in diff format.
|
||||
|
@ -1,56 +0,0 @@
|
||||
.TH DCH\-REPEAT "1" "10 August 2008" "ubuntu-dev-tools"
|
||||
.SH NAME
|
||||
dch\-repeat \- repeats a changelog entry into an older release
|
||||
|
||||
.SH SYNOPSIS
|
||||
.B dch\-repeat \-\-build\-tree <\fIPATH\fR>
|
||||
.br
|
||||
.B dch\-repeat \-\-source\-release <\fIRELEASE\fR>
|
||||
.br
|
||||
.B dch\-repeat \-\-target\-release <\fIRELEASE\fR>
|
||||
.br
|
||||
.B dch\-repeat \-\-devel\-release <\fIRELEASE\fR>
|
||||
.br
|
||||
.B dch\-repeat \-\-pocket <\fIPOCKET\fR>
|
||||
.br
|
||||
.B dch\-repeat \-h
|
||||
|
||||
.SH DESCRIPTION
|
||||
\fBdch\-repeat\fR is used to repeat a changelog into an older release.
|
||||
It expects that \-\-build\-tree is laid out with each Ubuntu release as a
|
||||
separate directory ("feisty", "edgy", etc).
|
||||
.PP
|
||||
For example, if gimp had a security update prepared for Feisty in
|
||||
$TREE/feisty/gimp\-2.2.13, running \fBdch\-repeat\fR in
|
||||
$TREE/edgy/gimp\-2.2.13 would pull in the latest changelog from the Feisty
|
||||
build.
|
||||
|
||||
.SH OPTIONS
|
||||
Listed below are the command line options for \fBdch\-repeat\fR:
|
||||
.TP
|
||||
.B \-h or \-\-help
|
||||
Display a help message and exit.
|
||||
.TP
|
||||
.B \-\-build\-tree PATH
|
||||
Base of build trees. Default is /scratch/ubuntu/build.
|
||||
.TP
|
||||
.B \-s or \-\-source\-release RELEASE
|
||||
Which release to take changelog from.
|
||||
.TP
|
||||
.B \-\-target\-release RELEASE
|
||||
Which release to build into.
|
||||
.TP
|
||||
.B \-\-devel\-release RELEASE
|
||||
Which release is the development release.
|
||||
.TP
|
||||
.B \-\-pocket POCKET
|
||||
Which pocket to use.
|
||||
|
||||
.SH AUTHOR
|
||||
\fBdch-repeat\fR was written by Kees Cook <kees@ubuntu.com>.
|
||||
This manual page was written by Jonathan Patrick Davies <jpds@ubuntu.com>.
|
||||
.PP
|
||||
Both are released under the GNU General Public License, version 2.
|
||||
|
||||
.SH SEE ALSO
|
||||
.BR dch(1).
|
59
doc/get-build-deps.1
Normal file
59
doc/get-build-deps.1
Normal file
@ -0,0 +1,59 @@
|
||||
.TH GET\-BUILD\-DEPS 1 "October 27, 2007" "ubuntu-dev-tools"
|
||||
|
||||
.SH NAME
|
||||
get\-build\-deps \- install build dependencies for one or more packages
|
||||
|
||||
.SH SYNOPSIS
|
||||
\fBget\-build\-deps\fP [\fIpackage name\fR]
|
||||
|
||||
.SH DESCRIPTION
|
||||
\fBget\-build\-deps\fP is a script to install the build dependencies for
|
||||
either a local source package or one or more packages from the repositories.
|
||||
.PP
|
||||
In order to obtain all missing build dependencies for a package on
|
||||
which source you are currently working, just run this script without
|
||||
any argument, and it'll read its debian/control file to determine the
|
||||
missing build dependencies.
|
||||
.PP
|
||||
Alternatively, you can call it with a list of space-separated package
|
||||
names, or the name of a single file which contains the package names
|
||||
each on a line. Then it will install the missing dependencies for those
|
||||
packages using "apt-get build-dep".
|
||||
|
||||
.SH EXAMPLES
|
||||
.TP
|
||||
get\-build\-deps
|
||||
Looks for a debian/control file in the current working directory and
|
||||
installs the dependencies listed there.
|
||||
.TP
|
||||
get\-build\-deps geany
|
||||
Installs the build dependencies for the version of \fBgeany\fP that's
|
||||
in the repositories.
|
||||
.TP
|
||||
get\-build\-deps geany epiphany-browser rhythmbox
|
||||
Same as the previous example but also with the dependencies for
|
||||
.B epiphany-browser
|
||||
and
|
||||
.BR rhythmbox .
|
||||
.TP
|
||||
get\-build\-deps ./package_list.txt
|
||||
Reads the file
|
||||
.B package_list.txt
|
||||
(relative to the current working directory),
|
||||
where each line contains the name of a package, and installs the
|
||||
dependencies for the versions of all those that are in the repositories.
|
||||
|
||||
.SH KNOWN BUGS AND LIMITATIONS
|
||||
When it's being used to install the missing dependencies for a local
|
||||
source package (i.e., no arguments are passed to it) it doesn't check
|
||||
for the dependencies to match the indicated versions, but just installs
|
||||
the newest one available in the repositories.
|
||||
|
||||
.SH SEE ALSO
|
||||
.BR dpkg-checkbuilddeps (1),
|
||||
.BR apt-get (8)
|
||||
|
||||
.SH AUTHORS
|
||||
\fBget\-build\-deps\fP and this manual page have been written by Siegfried-Angel
|
||||
Gevatter Pujals <rainct@ubuntu.com>. They are released under the GNU General Public
|
||||
License, version 3 or later.
|
@ -1,18 +0,0 @@
|
||||
.TH grab\-merge 1 "March 26, 2009" "ubuntu-dev-tools"
|
||||
|
||||
.SH NAME
|
||||
grab\-merge \- grabs a merge's files from merges.ubuntu.com.
|
||||
|
||||
.SH SYNOPSIS
|
||||
\fBgrab\-merge\fP <\fIpackage name\fP>
|
||||
|
||||
.SH DESCRIPTION
|
||||
\fBgrab\-merge\fP is a script that downloads a merge's packaging files and report
|
||||
from merges.ubuntu.com. Placing them in a new directory for working from.
|
||||
|
||||
.SH AUTHORS
|
||||
\fBgrab\-merge\fP was written by Scott James Remnant <scott@ubuntu.com> and
|
||||
this manpage by Jonathan Davies <jpds@ubuntu.com>.
|
||||
.PP
|
||||
Both are released under the GNU General Public License, version 2 or
|
||||
later.
|
@ -1,26 +0,0 @@
|
||||
.TH grep\-merges 1 "December 15, 2010" "ubuntu-dev-tools"
|
||||
.SH NAME
|
||||
grep\-merges \- search for outstanding merges from Debian
|
||||
.SH SYNOPSIS
|
||||
.B grep\-merges
|
||||
.RI [ string ]
|
||||
.SH DESCRIPTION
|
||||
.B grep\-merges
|
||||
searches merges.ubuntu.com for pending merges from Debian.
|
||||
If a
|
||||
.I string
|
||||
is given, it will list all merges whose source package name, last changelog
|
||||
author, or last uploader contain that string.
|
||||
Otherwise, it will list all merges.
|
||||
.SH EXAMPLES
|
||||
.nf
|
||||
$ grep\-merges cjwatson
|
||||
tzsetup Colin Watson <cjwatson@ubuntu.com>
|
||||
console-setup Colin Watson <cjwatson@ubuntu.com>
|
||||
.fi
|
||||
.SH AUTHOR
|
||||
.B grep\-merges
|
||||
and this manual page were written by Colin Watson <cjwatson@ubuntu.com>.
|
||||
.PP
|
||||
Both are released under the terms of the GNU General Public License, version
|
||||
3 or (at your option) any later version.
|
@ -1,60 +0,0 @@
|
||||
.TH import\-bug\-from\-debian "1" "September 21 2010" "ubuntu-dev-tools"
|
||||
.SH NAME
|
||||
import\-bug\-from\-debian \- Import bugs from Debian's BTS, and file
|
||||
them against Ubuntu in LP.
|
||||
|
||||
.SH SYNOPSIS
|
||||
.B import\-bug\-from\-debian \fR[\fIoptions\fR] \fIbug\fR...
|
||||
.br
|
||||
.B import\-bug\-from\-debian \-h
|
||||
|
||||
.SH DESCRIPTION
|
||||
\fBimport\-bug\-from\-debian\fR clones bugs from Debian's BTS into
|
||||
Launchpad. Each \fIbug\fR listed on the command line has its initial
|
||||
report re-filed against the same source package in Ubuntu.
|
||||
The Ubuntu bug is linked back to its Debian counterpart.
|
||||
|
||||
Each \fIbug\fR may be provided either as a bug number or URL.
|
||||
|
||||
.SH OPTIONS
|
||||
.TP
|
||||
.BR \-b ", " \-\-browserless
|
||||
Don't open the bug in a browser at the end.
|
||||
.TP
|
||||
.BR \-h ", " \-\-help
|
||||
Display a help message and exit.
|
||||
.TP
|
||||
.B \-l \fIINSTANCE\fR, \fB\-\-lpinstance\fR=\fIINSTANCE\fR
|
||||
Use the specified instance of Launchpad (e.g. "staging"), instead of
|
||||
the default of "production".
|
||||
.TP
|
||||
.B \-p \fIPACKAGE\fR, \fB\-\-package\fR=\fIPACKAGE\fR
|
||||
Launchpad package to file bug against, if not the same source package
|
||||
name as Debian.
|
||||
Useful for importing removal bugs filed against \fBftp.debian.org\fR.
|
||||
.TP
|
||||
.B \-\-no\-conf
|
||||
Do not read any configuration files, or configuration from environment
|
||||
variables.
|
||||
.SH ENVIRONMENT
|
||||
All of the \fBCONFIGURATION VARIABLES\fR below are also supported as
|
||||
environment variables.
|
||||
Variables in the environment take precedence to those in configuration
|
||||
files.
|
||||
.SH CONFIGURATION VARIABLES
|
||||
The following variables can be set in the environment or in
|
||||
.BR ubuntu\-dev\-tools (5)
|
||||
configuration files.
|
||||
In each case, the script\-specific variable takes precedence over the
|
||||
package\-wide variable.
|
||||
.TP
|
||||
.BR IMPORT_BUG_FROM_DEBIAN_LPINSTANCE ", " UBUNTUTOOLS_LPINSTANCE
|
||||
The default value for \fB--lpinstance\fR.
|
||||
.SH SEE ALSO
|
||||
.BR ubuntu\-dev\-tools (5)
|
||||
.SH AUTHORS
|
||||
\fBimport\-bug\-from\-debian\fR was written by James Westby
|
||||
<james.westby@ubuntu.com>,
|
||||
and this manual page was written by Stefano Rivera <stefanor@ubuntu.com>.
|
||||
.PP
|
||||
Both are released under the terms of the GNU General Public License, version 2.
|
@ -1,54 +0,0 @@
|
||||
.TH lp-bitesize "1" "May 9 2010" "ubuntu-dev-tools"
|
||||
.SH NAME
|
||||
lp-bitesize \- Add \fBbitesize\fR tag to bugs and add a comment.
|
||||
|
||||
.SH SYNOPSIS
|
||||
.B lp-bitesize \fR<\fIbug number\fR>
|
||||
.br
|
||||
.B lp-bitesize \-\-help
|
||||
|
||||
.SH DESCRIPTION
|
||||
\fBlp-bitesize\fR adds a bitesize tag to the bug, if it's not there yet. It
|
||||
also adds a comment to the bug indicating that you are willing to help with
|
||||
fixing it.
|
||||
It checks for permission to operate on a given bug first,
|
||||
then perform required tasks on Launchpad.
|
||||
|
||||
.SH OPTIONS
|
||||
Listed below are the command line options for \fBlp-bitesize\fR:
|
||||
.TP
|
||||
.BR \-h ", " \-\-help
|
||||
Display a help message and exit.
|
||||
.TP
|
||||
.B \-l \fIINSTANCE\fR, \fB\-\-lpinstance\fR=\fIINSTANCE\fR
|
||||
Use the specified instance of Launchpad (e.g. "staging"), instead of
|
||||
the default of "production".
|
||||
.TP
|
||||
.B \-\-no\-conf
|
||||
Do not read any configuration files, or configuration from environment
|
||||
variables.
|
||||
|
||||
.SH ENVIRONMENT
|
||||
All of the \fBCONFIGURATION VARIABLES\fR below are also supported as
|
||||
environment variables.
|
||||
Variables in the environment take precedence to those in configuration
|
||||
files.
|
||||
|
||||
.SH CONFIGURATION VARIABLES
|
||||
The following variables can be set in the environment or in
|
||||
.BR ubuntu\-dev\-tools (5)
|
||||
configuration files.
|
||||
In each case, the script\-specific variable takes precedence over the
|
||||
package\-wide variable.
|
||||
.TP
|
||||
.BR BITESIZE_LPINSTANCE ", " UBUNTUTOOLS_LPINSTANCE
|
||||
The default value for \fB--lpinstance\fR.
|
||||
|
||||
.SH SEE ALSO
|
||||
.BR ubuntu\-dev\-tools (5)
|
||||
|
||||
.SH AUTHORS
|
||||
\fBlp-bitesize\fR and this manual page were written by Daniel Holbach
|
||||
<daniel.holbach@canonical.com>.
|
||||
.PP
|
||||
Both are released under the terms of the GNU General Public License, version 3.
|
@ -1,20 +0,0 @@
|
||||
.TH merge-changelog 1 "February 15, 2010" "ubuntu-dev-tools"
|
||||
|
||||
.SH NAME
|
||||
merge\-changelog \- merges two changelogs with a common base
|
||||
|
||||
.SH SYNOPSIS
|
||||
\fBmerge\-changelog\fP <\fIleft changelog\fP> <\fIright changelog\fP>
|
||||
|
||||
.SH DESCRIPTION
|
||||
\fBmerge\-changelog\fP takes two changelogs that once shared a common source,
|
||||
merges them back together, and prints the merged result to stdout. This
|
||||
is useful if you need to manually merge a ubuntu package with a new
|
||||
Debian release of the package.
|
||||
|
||||
.SH AUTHORS
|
||||
\fBmerge\-changelog\fP was written by Scott James Remnant <scott@ubuntu.com>
|
||||
and Bryce Harrington <bryce@ubuntu.com>. This manpage was written by Ryan
|
||||
Kavanagh <ryanakca@kubuntu.org>.
|
||||
.PP
|
||||
Both are released under the GNU General Public License, version 3.
|
224
doc/mk-sbuild.1
224
doc/mk-sbuild.1
@ -1,224 +0,0 @@
|
||||
.TH MK\-SBUILD "1" "09 February 2010" "ubuntu-dev-tools"
|
||||
|
||||
.SH NAME
|
||||
mk\-sbuild \- creates chroots via schroot and sbuild
|
||||
|
||||
.SH SYNOPSIS
|
||||
\fBmk\-sbuild\fR [\fIoptions\fR...] <\fIrelease\fR>
|
||||
|
||||
.SH DESCRIPTION
|
||||
\fBmk\-sbuild\fR creates chroots via schroot and sbuild.
|
||||
|
||||
.SH OPTIONS
|
||||
Listed below are the command line options for mk\-sbuild:
|
||||
.TP
|
||||
.B \-\-arch\fR=\fIARCH
|
||||
What architecture to select (defaults to the native architecture).
|
||||
.TP
|
||||
.B \-\-target\fR=\fRARCH
|
||||
Set up the chroot as a cross-building environment targeting the specified
|
||||
architecture.
|
||||
.TP
|
||||
.B \-\-name\fR=\fINAME
|
||||
Base name for the schroot (arch is appended).
|
||||
.TP
|
||||
.B \-\-personality\fR=\fIPERSONALITY
|
||||
What personality to use (defaults to match \fB\-\-arch\fR).
|
||||
.TP
|
||||
.B \-\-debug
|
||||
Turn on script debugging.
|
||||
.TP
|
||||
.B \-\-skip\-updates
|
||||
Do not include the \fB\-updates\fR pocket in the installed
|
||||
\fBsources.list\fR.
|
||||
.TP
|
||||
.B \-\-skip\-proposed
|
||||
Do not include the \fB\-proposed\fR pocket in the installed
|
||||
\fBsources.list\fR.
|
||||
.TP
|
||||
.B \-\-source\-template\fR=\fIFILE
|
||||
Use \fIFILE\fR as the \fBsources.list\fR template (defaults to
|
||||
\fI$HOME\fB/.mk\-sbuild.sources\fR).
|
||||
.TP
|
||||
.B \-\-debootstrap\-mirror\fR=\fIURL
|
||||
Use \fIURL\fR as the debootstrap source (defaults to
|
||||
\fBhttp://ports.ubuntu.com\fR where appropriate, official Ubuntu
|
||||
repositories for the supported architectures).
|
||||
.TP
|
||||
.B \-\-debootstrap\-include\fR=\fIalpha,beta
|
||||
Pass along a comma separated list of packages to debootstrap's
|
||||
\fB\-\-include\fR argument. See \fBdebootstrap\fR (8) for more details.
|
||||
.TP
|
||||
.B \-\-debootstrap\-exclude\fR=\fIalpha,beta
|
||||
Pass along a comma separated list of packages to debootstrap's
|
||||
\fB\-\-exclude\fR argument.
|
||||
\fBWARNING:\fR be careful using this option as you can end up
|
||||
excluding essential package. See \fBdebootstrap \fR(8) for more details.
|
||||
.TP
|
||||
.B \-\-debootstrap\-keyring\fR=\fIkeyring
|
||||
Pass along the path to a gpg keyring file to debootsrap's
|
||||
\fB\-\-keyring\fR argument. See \fBdebootstrap\fR (8) for more details.
|
||||
.TP
|
||||
.B \-\-debootstrap\-no\-check\-gpg
|
||||
Disable checking gpg signatures of downloaded Release files by using
|
||||
debootstrap's \fB\-\-no\-check\-gpg\fR option. See \fBdebootstrap\fR (8)
|
||||
for more details.
|
||||
.TP
|
||||
.B \-\-debootstrap\-proxy\fR=\fIPROXY
|
||||
Use \fIPROXY\fR as apt proxy.
|
||||
.TP
|
||||
.B \-\-eatmydata
|
||||
Install and use eatmydata (default)
|
||||
.TP
|
||||
.B \-\-skip\-eatmydata
|
||||
Don't install and use eatmydata
|
||||
.TP
|
||||
.B \-\-distro\fR=\fIDISTRO
|
||||
Enable distro-specific logic.
|
||||
When not provided, the distribution is determined from \fIrelease\fR.
|
||||
Currently known distros: "\fBdebian\fR" and "\fBubuntu\fR".
|
||||
.TP
|
||||
.B \-\-vg\fR=\fIVOLUME_GROUP
|
||||
Specify a volume group, and subsequently use a default \fBSCHROOT_TYPE\fR of
|
||||
"\fBlvm-snapshot\fR" rather than "\fBdirectory\fR" (via overlayfs or
|
||||
aufs) mounts.
|
||||
.TP
|
||||
.B \-\-zfs-dataset=\fIDATASET
|
||||
Specify a zfs dataset, and subsequently use a default \fBSCHROOT_TYPE\fR of
|
||||
"\fBzfs-snapshot\fR" rather than "\fBdirectory\fR" (via overlayfs or
|
||||
aufs) mounts.
|
||||
.TP
|
||||
.B \-\-type\fR=\fISHROOT_TYPE
|
||||
Specify a \fBSCHROOT_TYPE\fR. Supported values are "\fBdirectory\fR"
|
||||
(default if \fB\-\-vg\fR not specified), "\fBlvm-snapshot\fR" (default
|
||||
if \fB\-\-vg\fR specified), "\fBbtrfs-snapshot\fR", "\fBzfs-snapshot\fR"
|
||||
and "\fBfile\fR".
|
||||
.TP
|
||||
.B \-\-ccache
|
||||
Enable usage of \fBccache\fR by default. See \fBccache\fR (1) for
|
||||
more details.
|
||||
.TP
|
||||
.B \-\-ccache-dir=\fIPATH
|
||||
Use \fBPATH\fR as schroot ccache directory. This directory can be
|
||||
safely shared by multiple schroots, but they will all use the same
|
||||
\fBCCACHE_MAXSIZE\fR.
|
||||
Defaults to /var/cache/ccache-sbuild.
|
||||
See \fBccache\fR (1) for more details.
|
||||
.TP
|
||||
.B \-\-ccache-size=\fISIZE
|
||||
Sets \fBSIZE\fR as the schroot \fBCCACHE_DIR\fR max-size used by ccache.
|
||||
See \fBccache\fR (1) for more details.
|
||||
|
||||
.SH ENVIRONMENT VARIABLES
|
||||
.TP
|
||||
.B LV_SIZE
|
||||
Size of source LVs (defaults to 5G).
|
||||
.TP
|
||||
.B SNAPSHOT_SIZE
|
||||
Size of snapshot LVs (defaults to 4G).
|
||||
.TP
|
||||
.B SCHROOT_CONF_SUFFIX
|
||||
Lines to append to schroot entries.
|
||||
.TP
|
||||
.B SCHROOT_PROFILE
|
||||
Profile to use with schroot. (defaults to sbuild)
|
||||
.TP
|
||||
.B SKIP_UPDATES
|
||||
Do not include the \fB\-updates\fR pocket (same as
|
||||
\fB\-\-skip\-updates\fR)
|
||||
.TP
|
||||
.B SKIP_PROPOSED
|
||||
Do not include the \fB\-proposed\fR pocket (same as
|
||||
\fB\-\-skip\-proposed\fR)
|
||||
.TP
|
||||
.B DEBOOTSTRAP_MIRROR
|
||||
Mirror location (same as \fB\-\-debootstrap-mirror\fR)
|
||||
.TP
|
||||
.B DEBOOTSTRAP_INCLUDE
|
||||
Comma separated list of packages to include when bootstrapping (same as
|
||||
\fB\-\-debootstrap-include\fR)
|
||||
.TP
|
||||
.B DEBOOTSTRAP_EXCLUDE
|
||||
Comma separated list of packages to exclude when bootstrapping (same as
|
||||
\fB\-\-debootstrap-exclude\fR; see warning above)
|
||||
.TP
|
||||
.B DEBOOTSTRAP_KEYRING
|
||||
Keyring file to use for checking gpg signatures of retrieved release files
|
||||
(same as \fB\-\-debootstrap\-keyring\fR)
|
||||
.TP
|
||||
.B DEBOOTSTRAP_NO_CHECK_GPG
|
||||
Disable gpg verification of retrieved release files (same as
|
||||
\fB\-\-debootstrap\-no\-check\-gpg\fR)
|
||||
.TP
|
||||
.B DEBOOTSTRAP_PROXY
|
||||
Proxy to use for apt. (same as
|
||||
\fB\-\-debootstrap\-proxy\fR)
|
||||
.TP
|
||||
.B EATMYDATA
|
||||
Enable or disable eatmydata usage, see \fB\-\-eatmydata\fR
|
||||
and \fB\-\-skip\-eatmydata\fR
|
||||
.TP
|
||||
.B SOURCE_CHROOTS_DIR
|
||||
Use \fBSOURCE_CHROOTS_DIR\fR as home of schroot source directories.
|
||||
(default \fB/var/lib/schroot/chroots\fR)
|
||||
.TP
|
||||
.B SOURCE_CHROOTS_TGZ
|
||||
Use \fBSOURCE_CHROOTS_TGZ\fR as home of schroot source tarballs.
|
||||
(default \fB/var/lib/schroot/tarballs\fR)
|
||||
.TP
|
||||
.B CHROOT_SNAPSHOT_DIR
|
||||
Use \fBCHROOT_SNAPSHOT_DIR\fR as home of mounted btrfs snapshots.
|
||||
(default \fB/var/lib/schroot/snapshots\fR)
|
||||
.TP
|
||||
.B CCACHE
|
||||
Enable \fBccache\fR (1) by default.
|
||||
(defaults to \fB0\fR)
|
||||
.TP
|
||||
.B CCACHE_DIR
|
||||
Use \fBCCACHE_DIR\fR as the \fBccache\fR (1) directory.
|
||||
(default \fB/var/cache/ccache-sbuild\fR)
|
||||
.TP
|
||||
.B CCACHE_SIZE
|
||||
Use \fBCCACHE_SIZE\fR as the \fBccache\fR (1) max-size.
|
||||
(defaults to \fB4G\fR)
|
||||
|
||||
|
||||
.SH FILES
|
||||
.TP
|
||||
.IB $HOME /.mk\-sbuild.rc
|
||||
Sourced for environment variables (defined above).
|
||||
.TP
|
||||
.IB $HOME /.mk\-sbuild.sources\fR[\fB. $DISTRO\fR]
|
||||
Can contain a customized \fBsources.list\fR.
|
||||
It will be read when creating the schroot.
|
||||
If a file with "\fB.ubuntu\fR" or "\fB.debian\fR" is found (as
|
||||
appropriate) it will use used instead.
|
||||
See \fBsources.list\fR (5) for more details on the format.
|
||||
.TP
|
||||
.IB $HOME /.mk\-sbuild.schroot.conf\fR[\fB. $SCHROOT_TYPE\fR]
|
||||
Can contain a customized configuration section to be inserted into
|
||||
\fB/etc/schroot/schroot.conf\fR.
|
||||
If a file with "\fB.lvm-snapshot\fR", "\fB.directory\fR", "\fB.file\fR",
|
||||
or "\fBbtrfs-snapshot\fR" is found (as appropriate) that file will use used instead.
|
||||
See \fBschroot.conf\fR (5) for more details on the format.
|
||||
.SH USING THE CHROOTS
|
||||
.TP
|
||||
To CHANGE the golden image: \fBsudo schroot \-c \fI${SCHROOT_NAME}\fB\-source \-u root\fR
|
||||
.TP
|
||||
To ENTER an image snapshot: \fBschroot \-c \fI$SCHROOT_NAME\fR
|
||||
.TP
|
||||
To BUILD within a snapshot: \fBsbuild \-A \-d \fI$SCHROOT_NAME $PACKAGE\fB*.dsc\fR
|
||||
.TP
|
||||
for example, to update the packages in a \fBsid\-amd64\fR golden image:
|
||||
\fBschroot \-c sid\-amd64\-source \-u root -- sh \-c "apt-get \-qq update && apt-get \-qy upgrade && apt-get clean" </dev/null\fR
|
||||
|
||||
.SH SEE ALSO
|
||||
.BR sbuild\-setup (7),
|
||||
.BR sources.list (5),
|
||||
.BR schroot.conf (5),
|
||||
.B https://help.ubuntu.com/community/SbuildLVMHowto
|
||||
|
||||
.SH AUTHOR
|
||||
\fBmk\-sbuild\fR was written by Kees Cook <kees@ubuntu.com>.
|
||||
This man page was written by Ryan Kavanagh <ryanakca@kubuntu.org>.
|
||||
Both are released under the GNU General Public License, version 3 or later.
|
@ -1,53 +1,49 @@
|
||||
.TH PBUILDER\-DIST\-SIMPLE 1 "February 25, 2008" "ubuntu\-dev\-tools"
|
||||
.TH PBUILDER\-DIST 1 "February 25, 2008" "ubuntu-dev-tools"
|
||||
|
||||
.SH NAME
|
||||
pbuilder\-dist\-simple \- simple multi\-release pbuilder wrapper
|
||||
pbuilder\-dist\-simple \- simple multi-distribution pbuilder wrapper
|
||||
|
||||
.SH SYNOPSIS
|
||||
\fBpbuilder\-\fI<dist>\fR\fP \fIoperation\fR [\fI...\fR]
|
||||
|
||||
.SH DESCRIPTION
|
||||
\fBpbuilder\-dist\-simple\fP is a wrapper that makes it easy to use
|
||||
pbuilder with chroots for many different Ubuntu distributions.
|
||||
If you need more features than \fBpbuilder\-dist\-simple\fP provides, have a
|
||||
look at
|
||||
.BR pbuilder\-dist (1).
|
||||
\fBpbuilder\-dist\fP is a wrapper that makes it easy to use pbuilder with
|
||||
chroots for many different Ubuntu/Debian distributions. If you need more
|
||||
features than \fBpbuilder\-dist\-simple\fP provides, have a look at
|
||||
\fBpbuilder\-dist\fP.
|
||||
|
||||
.SH USAGE
|
||||
Create one symlink to \fBpbuilder\-dist\-simple\fP for each distribution
|
||||
for which you want a build environment, naming them like "pbuilder\-lucid",
|
||||
"pbuilder\-natty", etc.
|
||||
for which you want a build environment, naming them like "pbuilder-hardy",
|
||||
"pbuilder-gutsy", etc.
|
||||
.PP
|
||||
Replace \fIoperation\fP with the action you want \fBpbuilder\-dist\-simple\fP
|
||||
to do (create, update, build, clean, login or execute).
|
||||
|
||||
.SH EXAMPLES
|
||||
.TP
|
||||
pbuilder\-natty create
|
||||
Creates a \fBpbuilder\fP environment for Ubuntu Natty.
|
||||
pbuilder\-gutsy create
|
||||
Creates a \fBpbuilder\fP environment for Ubuntu Gutsy.
|
||||
.TP
|
||||
pbuilder\-lucid update
|
||||
Updates an existing Ubuntu Lucid environment.
|
||||
pbuilder\-sid update
|
||||
Updates an existing Debian Sid environment.
|
||||
.TP
|
||||
pbuilder\-lucid build ./sample_1.0\-0ubuntu1.dsc
|
||||
Builds the specified package on an already existing Ubuntu Lucid environment.
|
||||
pbuilder\-hardy build ./sample_1.0\-0ubuntu1.dsc
|
||||
Builds the specified package on an already existing Ubuntu Hardy environment.
|
||||
|
||||
.SH FILES
|
||||
By default, \fBpbuilder\-dist\-simple\fP will store all the files it
|
||||
generates in \fB~/pbuilder/\fP.
|
||||
This can be changed by modifying the BASE_DIR value on the top of the script
|
||||
to any other directory you want.
|
||||
generates in \fB~/pbuilder/\fP. This can be changed by modifying the
|
||||
BASE_DIR value on the top of the script to any other directory you want.
|
||||
If the directory doesn't exit, it will be created at runtime.
|
||||
|
||||
.SH SEE ALSO
|
||||
.BR pbuilder (1),
|
||||
.BR pbuilderrc (5),
|
||||
.BR pbuilder\-dist (1)
|
||||
\fBpbuilder\fR, \fBpbuilderrc\fR
|
||||
|
||||
.SH AUTHORS
|
||||
\fBpbuilder\-dist\fP was originally written by Jamin W. Collins
|
||||
<jcollins@asgardsrealm.net> and Jordan Mantha <mantha@ubuntu.com>, and
|
||||
this manpage by Siegfried\-A. Gevatter <rainct@ubuntu.com>.
|
||||
this manpage by Siegfried-A. Gevatter <rainct@ubuntu.com>.
|
||||
.PP
|
||||
Both are released under the GNU General Public License, version 2 or
|
||||
later.
|
||||
|
@ -1,27 +1,19 @@
|
||||
.TH PBUILDER\-DIST 1 "January 10, 2008" "ubuntu-dev-tools"
|
||||
.TH PBUILDER\-DIST 1 "August 16, 2007" "ubuntu-dev-tools"
|
||||
|
||||
.SH NAME
|
||||
pbuilder\-dist, cowbuilder\-dist \- multi-distribution pbuilder/cowbuilder wrapper
|
||||
pbuilder\-dist \- multi-distribution pbuilder wrapper
|
||||
|
||||
.SH SYNOPSIS
|
||||
\fBpbuilder\-dist\fP \fIdistribution\fR [\fIarchitecture\fR] \fIoperation\fR
|
||||
[\fBoptions\fP] [\fI...\fR]
|
||||
|
||||
\fBcowbuilder\-dist\fP \fIdistribution\fR [\fIarchitecture\fR] \fIoperation\fR
|
||||
[\fBoptions\fP] [\fI...\fR]
|
||||
\fBpbuilder\-dist\fP \fIdistribution\fR [\fBi386\fP|\fBamd64\fP] [\fBmainonly\fP|\fBallcomp\fP]
|
||||
[\fBwithlog\fP|\fBnolog\fP] \fIoperation\fR [\fI...\fR]
|
||||
|
||||
.SH DESCRIPTION
|
||||
\fBpbuilder\-dist\fP is a wrapper that makes it easy to use pbuilder with many different
|
||||
versions of Ubuntu and/or Debian.
|
||||
.PP
|
||||
It is common to symlink this script in order to give it many names in the form of
|
||||
\fBpbuilder\-\fIdistribution\fP\fR or \fBpbuilder\-\fIdistribution\fR\-\fIarchitecture\fP\fR,
|
||||
like for example \fBpbuilder\-feisty\fP, \fBpbuilder\-sid\fP, \fBpbuilder\-gutsy\-i386\fP, etc.
|
||||
.PP
|
||||
The same applies to \fBcowbuilder\-dist\fP, which uses cowbuilder. The main
|
||||
difference between both is that pbuilder compresses the created chroot as a
|
||||
tarball, thus using less disc space but needing to uncompress (and possibly
|
||||
compress) its contents again on each run, and cowbuilder doesn't do this.
|
||||
\fBpbuilder\-\fIdistribution\fP\fR (\fBpbuilder\-\fIdistribution\fR\-\fIarchitecture\fP\fR on amd64
|
||||
systems), like for example \fBpbuilder\-feisty\fP, \fBpbuilder\-sid\fP, \fBpbuilder\-gutsy\-i386\fP, etc.
|
||||
|
||||
.SH USAGE
|
||||
There are many arguments listed on the synopsis; each of them, if used, has to be used exactly in
|
||||
@ -33,68 +25,48 @@ the name also contains \-\fIarchitecture\fR.
|
||||
\fBdistribution\fP
|
||||
Replace this with the codename of the version of Ubuntu or Debian you want to use.
|
||||
.TP
|
||||
\fBarchitecture\fP
|
||||
This optional parameter will attempt to construct a chroot in a foreign
|
||||
architecture.
|
||||
For some architecture pairs (e.g. i386 on an amd64 install), the chroot
|
||||
will be created natively.
|
||||
For others (e.g. arm64 on an amd64 install), qemu\-user\-static will be
|
||||
used.
|
||||
Note that some combinations (e.g. amd64 on an i386 install) require
|
||||
special separate kernel handling, and may break in unexpected ways.
|
||||
\fBi386\fP / \fBamd64\fP
|
||||
Only available on amd64 systems.
|
||||
This is optional; default is \fBamd64\fP.
|
||||
If \fBi386\fP is specified, an i386 environment will be used.
|
||||
.TP
|
||||
\fBmainonly\fP / \fBallcomp\fP
|
||||
This is optional; default is \fBallcomp\fP.
|
||||
If you specify \fBmainonly\fP, only packages from the main (in Debian) or
|
||||
main and restricted (in Ubuntu) components will be used.
|
||||
With the latter one, all official components will be enabled.
|
||||
This only has effect when creating a new environment.
|
||||
.TP
|
||||
\fBwithlog\fP / \fBnolog\fP
|
||||
This is optional; default is \fBnolog\fP.
|
||||
When \fBwithlog\fP is used, \fBpbuilder\fP will save the output produced by
|
||||
the current action in a dot-file called \fB.lastlog\fP in its base directory
|
||||
(see the FILES section).
|
||||
If this file already exists, it will be overwritten.
|
||||
.TP
|
||||
\fBoperation\fP
|
||||
Replace this with the action you want \fBpbuilder\fP to do (create, update,
|
||||
build, clean, login or execute).
|
||||
If you don't specify any action, but the next argument is a .dsc file, it
|
||||
will assume that it should build.
|
||||
Replace this with the action you want \fBpbuilder\fP to do (create, update, build, clean, login
|
||||
or execute). If you don't specify any action, but the next argument is a .dsc file, it will
|
||||
assume that it should build.
|
||||
Check its manpage for more details.
|
||||
.TP
|
||||
\fB[...]\fP
|
||||
.br
|
||||
Replace this with other parameters, if needed.
|
||||
For example, if \fBbuild\fP is the option, you will need to also specify
|
||||
a .dsc file. As a special feature, if you specify a .dsc file you can
|
||||
skip the \fBbuild\fP option and this script will automatically assume that
|
||||
building is the action you want to do.
|
||||
|
||||
.SH OPTIONS
|
||||
.TP
|
||||
\fB\-\-main\-only\fP (deprecated: \fBmainonly\fP)
|
||||
If you specify this option, only packages from the \fImain\fP (in Debian) or
|
||||
\fImain\fP and \fIrestricted\fP (in Ubuntu) components will be used. By
|
||||
default, all official components are enabled. This only has effect when
|
||||
creating a new environment.
|
||||
.TP
|
||||
\fB\-\-debug\-echo\fP
|
||||
The generated \fBpbuilder\fP/\fBcowbuilder\fP command will be printed to the
|
||||
standard output instead of being executed. This is useful for debugging.
|
||||
.TP
|
||||
\fB\-\-buildresult\fP \fBDIRECTORY\fP (pbuilder\-dist only)
|
||||
If this option is specified, the resultant files of the \fBpbuilder\fP build
|
||||
are placed in \fBDIRECTORY\fP.
|
||||
.TP
|
||||
\fB\-\-release\-only\fP
|
||||
Only use the release pocket.
|
||||
Default for development releases.
|
||||
.TP
|
||||
\fB\-\-security\-only\fP
|
||||
Only use the release and security pockets.
|
||||
Suitable environment for preparing security updates.
|
||||
.TP
|
||||
\fB\-\-updates\-only\fP
|
||||
Only use the release, security, and updates pocket.
|
||||
Not the proposed\-updates pocket.
|
||||
.TP
|
||||
\fB\-\-backports\fP
|
||||
Also use the backports archive..
|
||||
a .dsc file.
|
||||
.PP
|
||||
The default value of all optional parameters (except the architecture) can be changed by
|
||||
editing the first lines of the script. You can also change the base directory using the
|
||||
global variable $PBUILDFOLDER.
|
||||
.PP
|
||||
|
||||
.SH EXAMPLES
|
||||
.TP
|
||||
pbuilder\-dist gutsy create
|
||||
Creates a \fBpbuilder\fP environment for Ubuntu Gutsy, with all components enabled.
|
||||
.TP
|
||||
pbuilder\-sid \-\-main\-only create
|
||||
pbuilder\-sid mainonly create
|
||||
Creates a \fBpbuilder\fP environment for Debian Sid, with only the main component.
|
||||
.TP
|
||||
pbuilder\-feisty build ./sample_1.0\-0ubuntu1.dsc
|
||||
@ -105,54 +77,36 @@ Same as above, but stores \fBpbuilder\fP's output on a file.
|
||||
.TP
|
||||
pbuilder\-etch i386 update
|
||||
Updates an existing i386-architecture Debian Etch environment on an amd64 system.
|
||||
.TP
|
||||
cowbuilder-experimental create
|
||||
Creates a \fBcowbuilder\fP environment for Debian Experimental.
|
||||
|
||||
.SH FILES AND ENVIRONMENT VARIABLES
|
||||
By default, \fBpbuilder\-dist\fP will store all the files it generates in
|
||||
\fB~/pbuilder/\fP. This can be changed by setting the \fBPBUILDFOLDER\fP
|
||||
environment variable. If the directory doesn't exist, it will be created on
|
||||
the run.
|
||||
.PP
|
||||
A file with the log of the last operation, called last_operation.log, will be
|
||||
saved in the results subdirectory of each build environment.
|
||||
.PP
|
||||
The default authentication method is \fBsudo\fP. You can change this by
|
||||
setting the \fBPBUILDAUTH\fP variable.
|
||||
.PP
|
||||
By default, \fBpbuilder\-dist\fP use the master Debian and Ubuntu mirrors.
|
||||
The pbuilder \fBMIRRORSITE\fP and \fBOTHERMIRROR\fP variables are
|
||||
supported, as are the standard ubuntu\-dev\-tools variables:
|
||||
\fBUBUNTUTOOLS_DEBIAN_MIRROR\fP, \fBPBUILDER_DIST_DEBIAN_MIRROR\fP,
|
||||
\fBUBUNTUTOOLS_DEBSEC_MIRROR\fP, \fBPBUILDER_DIST_DEBSEC_MIRROR\fP,
|
||||
\fBUBUNTUTOOLS_UBUNTU_MIRROR\fP, \fBPBUILDER_DIST_UBUNTU\fP,
|
||||
\fBUBUNTUTOOLS_UBUNTU_PORTS_MIRROR\fP, and
|
||||
\fBPBUILDER_DIST_UBUNTU_PORTS_MIRROR\fP.
|
||||
See \fBubuntu\-dev\-tools\fP (5) for details.
|
||||
.PP
|
||||
You may also want to know that \fBpbuilder\-dist\fP exports \fBDIST\fP and
|
||||
\fBARCH\fP environment variables to the invoked process, containing the name
|
||||
of the distribution and the architecture targeted by the current build. You
|
||||
can make use of them, for example, in \fBpbuilderrc\fP.
|
||||
.SH FILES
|
||||
By default, \fBpbuilder\-dist\fP will store all the files it generates in \fB~/pbuilder/\fP.
|
||||
This can be changed by modifying the BASE_DIR value on the top of the script
|
||||
to any other directory you want, or by using the $PBUILDFOLDER global variable.
|
||||
If it doesn't exist, it will be created on the run.
|
||||
|
||||
.SH BUGS
|
||||
If you experience any problem with this script contact me on rainct@ubuntu.com
|
||||
or file a bug at https://bugs.launchpad.net/ubuntu/+source/ubuntu\-dev\-tools.
|
||||
.PP
|
||||
There are no known bugs at the moment.
|
||||
If you experience any problem with this script contact me on
|
||||
rainct@ubuntu.com.
|
||||
Please ensure first that the problem is really this script and not an issue
|
||||
with \fBpbuilder\fP or \fBcowbuilder\fP themselves.
|
||||
|
||||
.SH SEE ALSO
|
||||
.BR pbuilder (1),
|
||||
.BR pbuilderrc (5),
|
||||
.BR cowbuilder (1),
|
||||
.BR ubuntu\-dev\-tools (5).
|
||||
with \fBpbuilder\fP.
|
||||
|
||||
.SH AUTHORS
|
||||
\fBpbuilder\-dist\fP and this manual page were written by Siegfried-A. Gevatter
|
||||
<rainct@ubuntu.com>, with contributions from Iain Lane
|
||||
<iain@orangesquash.org.uk>, Emmet Hikory <persia@ubuntu.com> and others.
|
||||
\fBpbuilder\-dist\fP was originally written by Jamin W. Collins <jcollins@asgardsrealm.net> and
|
||||
Jordan Mantha <mantha@ubuntu.com>.
|
||||
.PP
|
||||
On August 2007 it was mostly rewritten, and extended, by Siegfried-Angel Gevatter Pujals
|
||||
<rainct@ubuntu.com>.
|
||||
|
||||
\fBpbuilder\-dist\fP is released under the GNU General Public License, version
|
||||
2 or later.
|
||||
.SH SEE ALSO
|
||||
\fBpbuilder\fR, \fBpbuilderrc\fR
|
||||
|
||||
.SH COPYRIGHT
|
||||
This manual page was written by Siegfried-Angel Gevatter Pujals (RainCT)
|
||||
<rainct@ubuntu.com> for YOU.
|
||||
Permission is granted to copy, distribute and/or modify this document
|
||||
under the terms of the GNU General Public License,
|
||||
Version 2 or any later version published by the Free Software Foundation.
|
||||
.PP
|
||||
On Debian based systems, the complete text of the GNU General Public
|
||||
License can be found in \fB/usr/share/common\-licenses/GPL\fP.
|
||||
|
@ -1,44 +0,0 @@
|
||||
.\" Copyright (C) 2023, Canonical Ltd.
|
||||
.\"
|
||||
.\" This program is free software; you can redistribute it and/or
|
||||
.\" modify it under the terms of the GNU General Public License, version 3.
|
||||
.\"
|
||||
.\" This program is distributed in the hope that it will be useful,
|
||||
.\" but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
.\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
.\" General Public License for more details.
|
||||
.\"
|
||||
.\" You should have received a copy of the GNU General Public License
|
||||
.\" along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
.TH pm\-helper 1 "June 2023" ubuntu\-dev\-tools
|
||||
|
||||
.SH NAME
|
||||
pm\-helper \- helper to guide a developer through proposed\-migration work
|
||||
|
||||
.SH SYNOPSIS
|
||||
.B pm\-helper \fR[\fIoptions\fR] [\fIpackage\fR]
|
||||
|
||||
.SH DESCRIPTION
|
||||
Claim a package from proposed\-migration to work on and get additional
|
||||
information (such as the state of the package in Debian) that may be helpful
|
||||
in unblocking it.
|
||||
.PP
|
||||
This tool is incomplete and under development.
|
||||
|
||||
.SH OPTIONS
|
||||
.TP
|
||||
.B \-l \fIINSTANCE\fR, \fB\-\-launchpad\fR=\fIINSTANCE\fR
|
||||
Use the specified instance of Launchpad (e.g. "staging"), instead of
|
||||
the default of "production".
|
||||
.TP
|
||||
.B \-v\fR, \fB--verbose\fR
|
||||
be more verbose
|
||||
.TP
|
||||
\fB\-h\fR, \fB\-\-help\fR
|
||||
Display a help message and exit
|
||||
|
||||
.SH AUTHORS
|
||||
\fBpm\-helper\fR and this manpage were written by Steve Langasek
|
||||
<steve.langasek@ubuntu.com>.
|
||||
.PP
|
||||
Both are released under the GPLv3 license.
|
@ -1 +0,0 @@
|
||||
pull-pkg.1
|
@ -1,91 +0,0 @@
|
||||
.\" Copyright (C) 2010, Stefano Rivera <stefanor@ubuntu.com>
|
||||
.\"
|
||||
.\" Permission to use, copy, modify, and/or distribute this software for any
|
||||
.\" purpose with or without fee is hereby granted, provided that the above
|
||||
.\" copyright notice and this permission notice appear in all copies.
|
||||
.\"
|
||||
.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
||||
.\" REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
||||
.\" AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
||||
.\" INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
||||
.\" LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
||||
.\" OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
||||
.\" PERFORMANCE OF THIS SOFTWARE.
|
||||
.TH PULL-DEBIAN-DEBDIFF "1" "December 2010" "ubuntu-dev-tools"
|
||||
.SH NAME
|
||||
\fBpull-debian-debdiff\fR \- find, download, and generate a debdiff
|
||||
|
||||
.SH SYNOPSIS
|
||||
\fBpull-debian-debdiff\fR [\fIoptions\fR] <\fIpackage\fR>
|
||||
<\fIversion\fR> [\fIdistance\fR]
|
||||
|
||||
.SH DESCRIPTION
|
||||
\fBpull-debian-debdiff\fR attempts to find and download a specific
|
||||
version of a Debian package and its immediate parent to generate a
|
||||
debdiff.
|
||||
|
||||
.SH OPTIONS
|
||||
.TP
|
||||
.I package
|
||||
The source package to download and diff.
|
||||
.TP
|
||||
.I version
|
||||
The most recent of the two versions you want to diff.
|
||||
.TP
|
||||
.I distance
|
||||
If specified (default \fB1\fR), the debdiff is against that many
|
||||
versions previous.
|
||||
.TP
|
||||
.BR \-h ", " \-\-help
|
||||
Display the usage instructions and exit.
|
||||
.TP
|
||||
.BR \-f ", " \-\-fetch
|
||||
Simply download the specified version and exit.
|
||||
.TP
|
||||
.B \-d \fIDEBIAN_MIRROR\fR, \fB\-\-debian\-mirror\fR=\fIDEBIAN_MIRROR\fR
|
||||
Use the specified mirror.
|
||||
Should be in the form \fBhttp://ftp.debian.org/debian\fR.
|
||||
If the package isn't found on this mirror, \fBpull\-debian\-source\fR
|
||||
will fall back to the default mirror.
|
||||
.TP
|
||||
.B \-s \fIDEBSEC_MIRROR\fR, \fB\-\-debsec\-mirror\fR=\fIDEBSEC_MIRROR\fR
|
||||
Use the specified Debian security mirror.
|
||||
Should be in the form \fBhttp://security.debian.org\fR.
|
||||
If the package isn't found on this mirror, \fBpull\-debian\-source\fR
|
||||
will fall back to the default mirror.
|
||||
.TP
|
||||
.B \-\-no\-conf
|
||||
Do not read any configuration files, or configuration from environment
|
||||
variables.
|
||||
|
||||
.SH ENVIRONMENT
|
||||
All of the \fBCONFIGURATION VARIABLES\fR below are also supported as
|
||||
environment variables.
|
||||
Variables in the environment take precedence to those in configuration
|
||||
files.
|
||||
|
||||
.SH CONFIGURATION VARIABLES
|
||||
The following variables can be set in the environment or in
|
||||
.BR ubuntu\-dev\-tools (5)
|
||||
configuration files.
|
||||
In each case, the script\-specific variable takes precedence over the
|
||||
package\-wide variable.
|
||||
.TP
|
||||
.BR PULL_DEBIAN_DEBDIFF_DEBIAN_MIRROR ", " UBUNTUTOOLS_DEBIAN_MIRROR
|
||||
The default value for \fB\-\-debian\-mirror\fR.
|
||||
.TP
|
||||
.BR PULL_DEBIAN_DEBDIFF_DEBSEC_MIRROR ", " UBUNTUTOOLS_DEBSEC_MIRROR
|
||||
The default value for \fB\-\-debsec\-mirror\fR.
|
||||
|
||||
.SH SEE ALSO
|
||||
.BR debdiff (1),
|
||||
.BR dget (1),
|
||||
.BR pull\-debian\-source (1),
|
||||
.BR ubuntu\-dev\-tools (5)
|
||||
|
||||
.SH AUTHORS
|
||||
\fBpull-debian-debdiff\fR was written by Stefano Rivera
|
||||
<stefanor@ubuntu.com>, a clone of a tool by Kees Cook <kees@ubuntu.com>.
|
||||
|
||||
This manual page was written by Stefano Rivera, based on the original by
|
||||
Andrew Starr\-Bochicchio <a.starr.b@gmail.com>.
|
@ -1 +0,0 @@
|
||||
pull-pkg.1
|
@ -1 +0,0 @@
|
||||
pull-pkg.1
|
@ -1 +0,0 @@
|
||||
pull-pkg.1
|
@ -1 +0,0 @@
|
||||
pull-pkg.1
|
@ -1 +0,0 @@
|
||||
pull-pkg.1
|
@ -1 +0,0 @@
|
||||
pull-pkg.1
|
@ -1 +0,0 @@
|
||||
pull-pkg.1
|
147
doc/pull-pkg.1
147
doc/pull-pkg.1
@ -1,147 +0,0 @@
|
||||
.TH PULL\-PKG "1" "28 August 2017" "ubuntu-dev-tools"
|
||||
|
||||
.SH NAME
|
||||
pull\-pkg \- download a package for Debian, Ubuntu, UCA, or a PPA
|
||||
|
||||
.SH SYNOPSIS
|
||||
.B pull\-pkg \fR[\fIoptions\fR]\fR <\fIpackage name\fR>
|
||||
[\fIrelease\fR|\fIversion\fR]
|
||||
|
||||
.SH DESCRIPTION
|
||||
\fBpull\-pkg\fR downloads the specified \fIversion\fR of
|
||||
<\fIpackage name\fR>, or the latest version from the
|
||||
specified \fIrelease\fR. To request a version from
|
||||
a particular pocket say \fIrelease\fB\-\fIpocket\fR (with a magic
|
||||
\fB\-release\fR for only the release pocket). If no \fIpocket\fR is
|
||||
specified, all pockets will be searched except -backports.
|
||||
If no \fIversion\fR or \fIrelease\fR is specified, the latest version in
|
||||
the development release will be downloaded.
|
||||
|
||||
There are convenience scripts that set pull type and distribution
|
||||
appropriately: these are
|
||||
\fBpull\-lp\-source\fR, \fBpull\-lp\-debs\fR, \fBpull\-lp\-ddebs\fR,
|
||||
and \fBpull\-lp\-udebs\fR, which all pull Ubuntu packages;
|
||||
\fBpull\-debian\-source\fR, \fBpull\-debian\-debs\fR, \fBpull\-debian\-ddebs\fR,
|
||||
and \fBpull\-debian\-udebs\fR, which all pull Debian packages;
|
||||
\fBpull\-uca\-source\fR, \fBpull\-uca\-debs\fR, \fBpull\-uca\-ddebs\fR,
|
||||
and \fBpull\-uca\-udebs\fR, which all pull Ubuntu Cloud Archive packages;
|
||||
and \fBpull\-ppa\-source\fR, \fBpull\-ppa\-debs\fR, \fBpull\-ppa\-ddebs\fR,
|
||||
and \fBpull\-ppa\-udebs\fR, which all pull from a specified Personal Package
|
||||
Archive on Launchpad. Each script pulls the file type in its name, i.e.
|
||||
\fIsource\fR, \fIdebs\fR, \fIddebs\fR, or \fIudebs\fR.
|
||||
|
||||
.SH OPTIONS
|
||||
Listed below are the command line options for pull\-pkg:
|
||||
.TP
|
||||
.I package name
|
||||
This is name of the package to downloaded.
|
||||
You can use either the source package name, or binary package name.
|
||||
.TP
|
||||
.I version
|
||||
This is the version of the package to downloaded.
|
||||
.TP
|
||||
.I release
|
||||
This is the release to downloaded from.
|
||||
For debian, you can use either the release name like \fBjessie\fR
|
||||
or \fBsid\fR, or you can use the special release names \fBunstable\fR,
|
||||
\fBstable\fR, or \fBtesting\fR.
|
||||
For ubuntu, you can use either the release name like \fBxenial\fR
|
||||
or the release-pocket like \fBxenial-proposed\fR.
|
||||
For ubuntu cloud archive (uca) you can use either the uca release
|
||||
name like \fBmitaka\fR or the ubuntu and uca release names like
|
||||
\fBtrusty-mitaka\fR. Defaults to the current development release.
|
||||
.TP
|
||||
.BR \-h ", " \-\-help
|
||||
Display a help message and exit.
|
||||
.TP
|
||||
.BR \-v ", " \-\-verbose
|
||||
Be verbose about what is being done.
|
||||
.TP
|
||||
.BR \-d ", " \-\-download\-only
|
||||
Do not extract the source package (applies only to source packages).
|
||||
.TP
|
||||
.B \-m \fIMIRROR\fR, \fB\-\-mirror\fR=\fIMIRROR\fR
|
||||
Use the specified mirror server.
|
||||
Should be in the form \fBhttp://archive.ubuntu.com/ubuntu\fR or
|
||||
\fBhttp://deb.debian.org/debian\fR. If not specified or if the
|
||||
package is not found on the specified mirror, this will fall
|
||||
back to the default mirror(s) and/or mirror(s) from environment
|
||||
variables, and then will fall back to Launchpad or Debian Snapshot.
|
||||
This can be specified multiple times to try multiple mirrors.
|
||||
.TP
|
||||
.B \-\-no\-conf
|
||||
Do not use mirrors from the default configuration, or from
|
||||
any environment variables.
|
||||
.TP
|
||||
.B \-a \fIARCH\fR, \fB\-\-arch\fR=\fIARCH\fR
|
||||
Get binary packages from the \fIARCH\fR architecture.
|
||||
Defaults to the local architecture, if it can be deteected.
|
||||
.TP
|
||||
.B \-p \fIPULL\fR, \fB\-\-pull\fR=\fIPULL\fR
|
||||
What to pull: \fBsource\fR, \fBdebs\fR, \fBddebs\fR, \fBudebs\fR,
|
||||
or \fBlist\fR. The \fBlist\fR action only lists all a package's
|
||||
source and binary files, but does not actually download any.
|
||||
Defaults to \fBsource\fR.
|
||||
.TP
|
||||
.B \-D \fIDISTRO\fR, \fB\-\-distro\fR=\fIDISTRO\fR
|
||||
Pull from: \fBdebian\fR, \fBuca\fR, \fBubuntu\fR, or a \fBppa\fR.
|
||||
\fBlp\fR can be used instead of \fBubuntu\fR.
|
||||
Any string containing \fBcloud\fR can be used instead of \fBuca\fR.
|
||||
If pulling from a ppa, you must specify the PPA. Defaults to \fBubuntu\fR.
|
||||
.TP
|
||||
.B \-\-ppa\fR=ppa:\fIUSER/NAME\fR
|
||||
Applies only when \fBdistro\fR is \fIppa\fR. Can be provided either as
|
||||
a value to the \fB\-\-ppa\fR option parameter, or as a plain option
|
||||
(like \fIrelease\fR or \fIversion\fR). When specified as a plain option,
|
||||
the form must be \fBppa:USER/NAME\fR; when specified as a value to the
|
||||
\fB\-\-ppa\fR option parameter, the leading \fBppa:\fR is optional.
|
||||
|
||||
.SH ENVIRONMENT
|
||||
All of the \fBCONFIGURATION VARIABLES\fR below are also supported as
|
||||
environment variables.
|
||||
Variables in the environment take precedence to those in configuration
|
||||
files.
|
||||
|
||||
.SH CONFIGURATION VARIABLES
|
||||
The following variables can be set in the environment or in
|
||||
.BR ubuntu\-dev\-tools (5)
|
||||
configuration files.
|
||||
In each case, the script\-specific variable takes precedence over the
|
||||
package\-wide variable.
|
||||
.TP
|
||||
.BR UBUNTUTOOLS_UBUNTU_MIRROR
|
||||
The default mirror.
|
||||
.TP
|
||||
.BR PULL_PKG_UBUNTU_MIRROR
|
||||
The default mirror when using the \fBpull\-pkg\fR script.
|
||||
.TP
|
||||
.BR PULL_[LP|DEBIAN|PPA|UCA]_[SOURCE|DEBS|DDEBS|UDEBS]_MIRROR
|
||||
The default mirror when using the associated script.
|
||||
|
||||
.SH SEE ALSO
|
||||
.BR dget (1),
|
||||
.BR pull\-lp\-source (1),
|
||||
.BR pull\-lp\-debs (1),
|
||||
.BR pull\-lp\-ddebs (1),
|
||||
.BR pull\-lp\-udebs (1),
|
||||
.BR pull\-debian\-source (1),
|
||||
.BR pull\-debian\-debs (1),
|
||||
.BR pull\-debian\-ddebs (1),
|
||||
.BR pull\-debian\-udebs (1),
|
||||
.BR pull\-ppa\-source (1),
|
||||
.BR pull\-ppa\-debs (1),
|
||||
.BR pull\-ppa\-ddebs (1),
|
||||
.BR pull\-ppa\-udebs (1),
|
||||
.BR pull\-uca\-source (1),
|
||||
.BR pull\-uca\-debs (1),
|
||||
.BR pull\-uca\-ddebs (1),
|
||||
.BR pull\-uca\-udebs (1),
|
||||
.BR pull\-debian\-debdiff (1),
|
||||
.BR ubuntu\-dev\-tools (5)
|
||||
|
||||
.SH AUTHOR
|
||||
.PP
|
||||
\fBpull\-pkg\fR was written by Dan Streetman <ddstreet@canonical.com>,
|
||||
based on the original \fBpull\-lp\-source\fR; it and this manual page
|
||||
were written by Iain Lane <iain@orangesquash.org.uk>.
|
||||
All are released under the GNU General Public License, version 3 or later.
|
@ -1 +0,0 @@
|
||||
pull-pkg.1
|
@ -1 +0,0 @@
|
||||
pull-pkg.1
|
@ -1 +0,0 @@
|
||||
pull-pkg.1
|
@ -1 +0,0 @@
|
||||
pull-pkg.1
|
@ -1 +0,0 @@
|
||||
pull-pkg.1
|
@ -1 +0,0 @@
|
||||
pull-pkg.1
|
@ -1 +0,0 @@
|
||||
pull-pkg.1
|
@ -1 +0,0 @@
|
||||
pull-pkg.1
|
@ -1,57 +0,0 @@
|
||||
.\" Copyright (C) 2011, Stefano Rivera <stefanor@ubuntu.com>
|
||||
.\"
|
||||
.\" Permission to use, copy, modify, and/or distribute this software for any
|
||||
.\" purpose with or without fee is hereby granted, provided that the above
|
||||
.\" copyright notice and this permission notice appear in all copies.
|
||||
.\"
|
||||
.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
||||
.\" REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
||||
.\" AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
||||
.\" INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
||||
.\" LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
||||
.\" OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
||||
.\" PERFORMANCE OF THIS SOFTWARE.
|
||||
.TH requestbackport 1 "November 2011" ubuntu\-dev\-tools
|
||||
|
||||
.SH NAME
|
||||
requestbackport \- File a backport request bug
|
||||
|
||||
.SH SYNOPSIS
|
||||
.B requestbackport \fR[\fIoptions\fR] \fIpackage\fR
|
||||
|
||||
.SH DESCRIPTION
|
||||
Determine the intermediate releases that \fIpackage\fR needs to be
|
||||
backported to, list all reverse\-dependencies, and file the backporting
|
||||
request.
|
||||
\fBrequestbackport\fR will include a testing checklist in the bug.
|
||||
|
||||
.SH OPTIONS
|
||||
.TP
|
||||
\fB\-d\fR \fIDEST\fR, \fB\-\-destination\fR=\fIDEST\fR
|
||||
Backport to \fIDEST\fR release and necessary intermediate
|
||||
releases. Default: current stable release.
|
||||
.TP
|
||||
\fB\-s\fR \fISOURCE\fR, \fB\-\-source\fR=\fISOURCE\fR
|
||||
Backport from \fISOURCE\fR release.
|
||||
Default: current development release.
|
||||
.TP
|
||||
\fB\-l\fR \fIINSTANCE\fR, \fB\-\-lpinstance\fR=\fIINSTANCE\fR
|
||||
Launchpad instance to connect to.
|
||||
Default: \fBproduction\fR.
|
||||
.TP
|
||||
\fB\-\-no\-conf\fR
|
||||
Don't read config files or environment variables
|
||||
.TP
|
||||
\fB\-h\fR, \fB\-\-help\fR
|
||||
Display a help message and exit.
|
||||
|
||||
.SH SEE ALSO
|
||||
.BR backportpackage (1),
|
||||
.BR reverse\-depends (1),
|
||||
.BR https://wiki.ubuntu.com/UbuntuBackports .
|
||||
|
||||
.SH AUTHORS
|
||||
\fBrequestbackport\fR and this manpage were written by Stefano Rivera
|
||||
<stefanor@ubuntu.com>.
|
||||
.PP
|
||||
Both are released under the terms of the ISC License.
|
@ -2,84 +2,47 @@
|
||||
.SH NAME
|
||||
requestsync \- helper to file sync requests for Ubuntu
|
||||
.SH SYNOPSIS
|
||||
.B requestsync\fR [\fB\-d \fIdistro\fR] [\fB\-nse\fR] [\fB\-k \fIkeyid\fR] <\fBsource package\fR> [\fBtarget release\fR] [\fIbase version\fR]
|
||||
.br
|
||||
.B requestsync \-\-lp\fR [\fB\-nse\fR] <\fBsource package\fR> <\fBtarget release\fR> [\fIbase version\fR]
|
||||
.br
|
||||
.B requestsync\fR [\fB\-ns\fR] [\fB\-k \fIkeyid\fR] <\fBsource package\fR> <\fBtarget release\fR> [\fIbase version\fR]
|
||||
|
||||
.B requestsync \-\-lp\fR [\fB\-ns\fR] <\fBsource package\fR> <\fBtarget release\fR> [\fIbase version\fR]
|
||||
|
||||
.B requestsync \-h
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBrequestsync\fR looks at the versions of <source package> in Debian and
|
||||
Ubuntu and prompts for an explanation of why the Ubuntu changes (if there
|
||||
are any) should be dropped.
|
||||
The changelog entry is then downloaded from packages.debian.org, and the
|
||||
sync request bug is filed in launchpad.
|
||||
Alternatively, the sync request can be filed by GPG\-signed email (option
|
||||
\fB\-\-email\fR).
|
||||
|
||||
.PP
|
||||
\fBrequestsync\fR checks if you have the permissions to request the sync from
|
||||
the archive administrators directly by checking if you have upload permissions
|
||||
for that package through package set permissions or component permissions. If
|
||||
you don't have upload permissions, the script will subscribe the necessary
|
||||
team with approval rights to the bug report for you.
|
||||
|
||||
This check is only performed if \fBrequestsync\fR is allowed to use the LP API
|
||||
(not email submission). In the other case \fBrequestsync\fR relies on that you
|
||||
answer the question about upload permissions honestly to determine if a team
|
||||
with approval rights is to be subscribed to the bug.
|
||||
|
||||
If you have permission to upload the package directly, then you may prefer
|
||||
to use \fBsyncpackage\fR instead to copy the package using the Launchpad
|
||||
API. At some future point, \fBrequestsync\fR will be changed to do this
|
||||
automatically.
|
||||
|
||||
.PP
|
||||
\fBrequestsync\fR uses launchpadlib authentication to file its requests.
|
||||
|
||||
The changelog entry is then downloaded from packages.debian.org. If the sync
|
||||
request is being filed per email (default), a prompt for your GPG passphrase
|
||||
follows so that it can sign the mail and send it off to Launchpad.
|
||||
Alternatively a sync request can be filed directly using the launchpadbugs
|
||||
python module (option \fB\-\-lp\fR). \fBrequestsync\fR falls back to mail
|
||||
the sync request if submitting using the launchpadbugs module fails.
|
||||
.SH OPTIONS
|
||||
.PP
|
||||
Listed below are the command line options for requestsync:
|
||||
.TP
|
||||
.B \-h
|
||||
Display a help message and exit.
|
||||
.TP
|
||||
.B \-d
|
||||
Specifies which Debian distribution a package should be synced from.
|
||||
Default is \fIunstable\fR.
|
||||
.TP
|
||||
.B \-n
|
||||
Specifies that the package is a new package, and requestsync should not
|
||||
attempt to look it up in Ubuntu since it will not exist.
|
||||
.TP
|
||||
.B \-k \fI<keyid>\fR
|
||||
Specifies your GPG key.
|
||||
This is only used if the sync request is mailed to Launchpad.
|
||||
.TP
|
||||
.B \-\-email
|
||||
Use GPG\-signed email to file the bug, rather than launchpadlib.
|
||||
.TP
|
||||
.B \-s
|
||||
Specifies that you require sponsorship.
|
||||
You need this option if you don't have upload permissions for that package.
|
||||
This disables the upload permissions check described above.
|
||||
You need this option if you are not a member of ubuntu-dev for universe or
|
||||
multiverse, or ubuntu-core-dev for main or restricted.
|
||||
.TP
|
||||
.B \-C
|
||||
Allow changelog to be manually filled in when missing.
|
||||
\fBrequestsync\fR gets Debian changelogs from packages.debian.org, which
|
||||
isn't in sync with the Debian archive.
|
||||
To request a sync before the changelog is available, pass this option,
|
||||
and provide the changelog entries yourself.
|
||||
.B \-k \fI<keyid>\fR
|
||||
Specifies your GPG key.
|
||||
Can also be set with the line `\fIexport GPGKEY=<keyid>\fR' in
|
||||
.IR $HOME/.bashrc .
|
||||
This is only used if the sync request is mailed to Launchpad.
|
||||
.TP
|
||||
.B \-e
|
||||
Use this flag after FeatureFreeze for non-bug fix syncs. \fBrequestsync\fR will
|
||||
subscribe ubuntu-release team instead of sponsorship team.
|
||||
.TP
|
||||
.B \-l \fIINSTANCE\fR, \fB\-\-lpinstance\fR=\fIINSTANCE\fR
|
||||
Use the specified instance of Launchpad (e.g. "staging"), instead of
|
||||
the default of "production".
|
||||
.TP
|
||||
.B \-\-no\-conf
|
||||
Do not read any configuration files, or configuration from environment
|
||||
variables.
|
||||
.B \-\-lp
|
||||
Use the launchpadbugs python module (packaged as python-launchpad-bugs) to
|
||||
file the sync request in Launchpad.
|
||||
.TP
|
||||
.B <source package>
|
||||
This is the source package that you would like to be synced from Debian.
|
||||
@ -87,55 +50,18 @@ This is the source package that you would like to be synced from Debian.
|
||||
.B <target release>
|
||||
This is the release that you would like the source package to be synced
|
||||
into.
|
||||
This should always be the latest development release of Ubuntu.
|
||||
This should always be the latest development release of Ubuntu, i.e.: hardy.
|
||||
.TP
|
||||
.B [base version]
|
||||
In some cases, the base version (where the Ubuntu package started differing
|
||||
from the Debian package) cannot be automatically determined.
|
||||
Specify this option in this case.
|
||||
|
||||
.SH ENVIRONMENT
|
||||
\fBrequestsync\fR uses the following variables which should be set in your
|
||||
shell's configuration by adding \fIexport VARIABLE=\fR lines, where VARIABLE is
|
||||
one of the following:
|
||||
.TP
|
||||
.BR UBUMAIL ", " DEBEMAIL
|
||||
Specifies which email should be used when sending to Launchpad.
|
||||
.P
|
||||
All of the \fBCONFIGURATION VARIABLES\fR below are also supported as
|
||||
environment variables.
|
||||
Variables in the environment take precedence to those in configuration
|
||||
files.
|
||||
|
||||
.SH CONFIGURATION VARIABLES
|
||||
.TP
|
||||
.B REQUESTSYNC_SMTP_SERVER
|
||||
Set which SMTP server to use when sending mail.
|
||||
If unspecified this defaults to launchpad's SMTP servers (the
|
||||
eventual destination).
|
||||
.TP
|
||||
.B REQUESTSYNC_SMTP_PORT
|
||||
Sets which port of the SMTP server to use. Default is 25.
|
||||
.TP
|
||||
.BR REQUESTSYNC_SMTP_USER " and " REQUESTSYNC_SMTP_PASS
|
||||
Sets the username and password to use when authenticating to the SMTP server.
|
||||
.TP
|
||||
.BR REQUESTSYNC_USE_LPAPI
|
||||
Setting this to \fIno\fR is equivalent to running with \fB--email\fR.
|
||||
.TP
|
||||
.BR REQUESTSYNC_LPINSTANCE ", " UBUNTUTOOLS_LPINSTANCE
|
||||
The default value for \fB--lpinstance\fR.
|
||||
.TP
|
||||
.BR REQUESTSYNC_KEYID ", " UBUNTUTOOLS_KEYID
|
||||
The default value for \fB-k\fR.
|
||||
|
||||
.SH SEE ALSO
|
||||
.BR rmadison (1),
|
||||
.BR syncpackage (1),
|
||||
.BR ubuntu\-dev\-tools (5)
|
||||
|
||||
.SH AUTHOR
|
||||
.B requestsync
|
||||
and this manual page were written by the Ubuntu MOTU Team.
|
||||
.PP
|
||||
Both are released under the GNU General Public License, version 2.
|
||||
This manual page was pieced together by Steve Kowalik.
|
||||
|
||||
It was then updated by Ryan Kavanagh and Michael Bienia to reflect
|
||||
additional features.
|
||||
.SH SEE ALSO
|
||||
.PP
|
||||
.BR rmadison (1)
|
||||
|
39
doc/reverse-build-depends.1
Normal file
39
doc/reverse-build-depends.1
Normal file
@ -0,0 +1,39 @@
|
||||
.\" Title: reverse-build-depends
|
||||
.\" Author: Siegfried-Angel Gevatter Pujals
|
||||
.\" Contact details: rainct@ubuntu.com
|
||||
|
||||
.TH REVERSE\-BUILD\-DEPENDS 1 "January 17, 2008" "ubuntu-dev-tools"
|
||||
|
||||
.SH NAME
|
||||
reverse\-build\-depends \- find a package's reverse build dependencies
|
||||
|
||||
.SH SYNOPSIS
|
||||
\fBreverse\-build\-depends\fP [\fB\-c\fP|\fB\-s\fP] <\fIpackage name\fR>
|
||||
|
||||
.SH DESCRIPTION
|
||||
\fBreverse\-build\-depends\fP is a little script that prints a list of
|
||||
all those Debian package that have a build dependency upon the package
|
||||
you indicate, that is, they search for its reverse build dependencies.
|
||||
|
||||
.SH OPTIONS
|
||||
.TP
|
||||
\fB\-c\fP
|
||||
This option will disable normal output and print only the number of
|
||||
reverse dependencies instead.
|
||||
.TP
|
||||
\fB\-s\fP
|
||||
If you prefer to see all build dependencies in a single line, use this
|
||||
option. Otherwise, each one will be printed on its own line.
|
||||
|
||||
.SH KNOWN BUGS AND LIMITATIONS
|
||||
Note that to use \fBreverse\-build\-depends\fP it is required for the source repositories
|
||||
(deb-src lines) to be enabled in your sources.list.
|
||||
|
||||
.SH SEE ALSO
|
||||
\fBgrep\-dctrl\fR, \fBapt\-cache\fR
|
||||
|
||||
.SH COPYRIGHT
|
||||
\fBreverse\-build\-depends\fP and this manual page were written by
|
||||
Siegfried-Angel Gevatter Pujals <rainct@ubuntu.com> for YOU. Both are
|
||||
released under the terms of the GNU General Public License (version 2
|
||||
or later).
|
@ -1,81 +0,0 @@
|
||||
.\" Copyright (C) 2011, Stefano Rivera <stefanor@ubuntu.com>
|
||||
.\"
|
||||
.\" Permission to use, copy, modify, and/or distribute this software for any
|
||||
.\" purpose with or without fee is hereby granted, provided that the above
|
||||
.\" copyright notice and this permission notice appear in all copies.
|
||||
.\"
|
||||
.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
||||
.\" REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
||||
.\" AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
||||
.\" INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
||||
.\" LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
||||
.\" OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
||||
.\" PERFORMANCE OF THIS SOFTWARE.
|
||||
.TH reverse\-depends 1 "November 2011" ubuntu\-dev\-tools
|
||||
|
||||
.SH NAME
|
||||
reverse\-depends \- List the reverse\-dependencies (or
|
||||
build\-dependencies) of a package
|
||||
|
||||
.SH SYNOPSIS
|
||||
.B reverse\-depends \fR[\fIoptions\fR] \fIpackage
|
||||
|
||||
.SH DESCRIPTION
|
||||
List reverse\-dependencies (or build\-dependencies) of \fIpackage\fR.
|
||||
If the package name is prefixed with \fBsrc:\fR then the
|
||||
reverse\-dependencies of all the binary packages that the specified
|
||||
source package builds will be listed.
|
||||
|
||||
.SH OPTIONS
|
||||
.TP
|
||||
\fB\-r\fR \fIRELEASE\fR, \fB\-\-release\fR=\fIRELEASE\fR
|
||||
Query dependencies in \fIRELEASE\fR.
|
||||
Default: current development release.
|
||||
.TP
|
||||
\fB\-R\fR, \fB\-\-without\-recommends\fR
|
||||
Only consider Depends relationships, not Recommends.
|
||||
.TP
|
||||
\fB\-s\fR, \fB\-\-with\-suggests\fR
|
||||
Also consider Suggests relationships.
|
||||
.TP
|
||||
\fB\-b\fR, \fB\-\-build\-depends\fR
|
||||
Query build dependencies.
|
||||
Synonym for \fB\-\-arch\fR=\fIsource\fR.
|
||||
.TP
|
||||
\fB\-a\fR \fIARCH\fR, \fB\-\-arch\fR=\fIARCH\fR
|
||||
Query dependencies in \fIARCH\fR.
|
||||
Besides valid architecture names, the special values \fBany\fR and
|
||||
\fBsource\fR may be used.
|
||||
\fBany\fR displays all reverse dependencies, the union across all
|
||||
architecture.
|
||||
\fBsource\fR displays build dependencies.
|
||||
Default: \fBany\fR.
|
||||
.TP
|
||||
\fB\-c\fR \fICOMPONENT\fR, \fB\-\-component\fR=\fICOMPONENT\fR
|
||||
Only consider reverse\-dependencies in \fICOMPONENT\fR. Can
|
||||
be specified multiple times.
|
||||
Default: all components.
|
||||
.TP
|
||||
\fB\-l\fR, \fB\-\-list\fR
|
||||
Display a simple, machine\-readable list.
|
||||
.TP
|
||||
\fB\-u\fR \fIURL\fR, \fB\-\-service\-url\fR=\fIURL\fR
|
||||
Reverse Dependencies web\-service \fIURL\fR.
|
||||
Default: UbuntuWire's service at
|
||||
\fBhttp://qa.ubuntuwire.org/rdepends/\fR.
|
||||
.TP
|
||||
\fB\-h\fR, \fB\-\-help\fR
|
||||
Display a help message and exit
|
||||
|
||||
.SH EXAMPLES
|
||||
All reverse dependencies of source package bash:
|
||||
.IP
|
||||
.nf
|
||||
.B reverse\-depends src:bash
|
||||
.fi
|
||||
|
||||
.SH AUTHORS
|
||||
\fBreverse\-depends\fR and this manpage were written by Stefano Rivera
|
||||
<stefanor@ubuntu.com>.
|
||||
.PP
|
||||
Both are released under the terms of the ISC License.
|
@ -1,15 +0,0 @@
|
||||
.TH running\-autopkgtests "1" "18 January 2024" "ubuntu-dev-tools"
|
||||
.SH NAME
|
||||
running\-autopkgtests \- dumps a list of currently running autopkgtests
|
||||
|
||||
.SH SYNOPSIS
|
||||
.B running\-autopkgtests
|
||||
|
||||
.SH DESCRIPTION
|
||||
Dumps a list of currently running and queued tests in Autopkgtest.
|
||||
Pass --running to only see running tests, or --queued to only see
|
||||
queued tests. Passing both will print both, which is the default behavior.
|
||||
|
||||
.SH AUTHOR
|
||||
.B running\-autopkgtests
|
||||
was written by Chris Peterson <chris.peterson@canonical.com>.
|
@ -1,60 +0,0 @@
|
||||
.\" Copyright (C) 2011, Stefano Rivera <stefanor@ubuntu.com>
|
||||
.\"
|
||||
.\" Permission to use, copy, modify, and/or distribute this software for any
|
||||
.\" purpose with or without fee is hereby granted, provided that the above
|
||||
.\" copyright notice and this permission notice appear in all copies.
|
||||
.\"
|
||||
.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
||||
.\" REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
||||
.\" AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
||||
.\" INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
||||
.\" LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
||||
.\" OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
||||
.\" PERFORMANCE OF THIS SOFTWARE.
|
||||
.TH seeded\-in\-ubuntu 1 "December 2011" ubuntu\-dev\-tools
|
||||
|
||||
.SH NAME
|
||||
seeded\-in\-ubuntu \- Determine whether a package is safe to upload
|
||||
during a freeze
|
||||
|
||||
.SH SYNOPSIS
|
||||
.B seeded\-in\-ubuntu \fR[\fIoptions\fR] \fIpackage\fR...
|
||||
|
||||
.SH DESCRIPTION
|
||||
Lists all the current daily images containing the specified packages.
|
||||
Or whether the package is part of the supported seed.
|
||||
.PP
|
||||
If it isn't on an image, it should be safe to upload.
|
||||
During the final freeze, one should avoid packages in the supported seed
|
||||
too.
|
||||
.PP
|
||||
An index of the current manifests is downloaded from UbuntuWire.
|
||||
|
||||
.SH OPTIONS
|
||||
.TP
|
||||
\fB\-b\fR, \fB\-\-binary\fR
|
||||
The packages specified are binary packages.
|
||||
This is faster than source packages, as otherwise we must query LP to
|
||||
determine the binary packages that every specified source package
|
||||
builds.
|
||||
.TP
|
||||
\fB\-u\fR \fIURL\fR, \fB\-\-data\-url\fR=\fIURL\fR
|
||||
URL for index of seeded packages.
|
||||
Default: UbuntuWire's service at
|
||||
\fBhttp://qa.ubuntuwire.org/ubuntu-seeded-packages/seeded.json.gz\fR.
|
||||
.TP
|
||||
\fB\-h\fR, \fB\-\-help\fR
|
||||
Display a help message and exit
|
||||
|
||||
.SH EXAMPLES
|
||||
All the images that contain unity:
|
||||
.IP
|
||||
.nf
|
||||
.B seeded\-in\-ubuntu -b unity
|
||||
.fi
|
||||
|
||||
.SH AUTHORS
|
||||
\fBseeded\-in\-ubuntu\fR and this manpage were written by Stefano Rivera
|
||||
<stefanor@ubuntu.com>.
|
||||
.PP
|
||||
Both are released under the terms of the ISC License.
|
@ -1,22 +0,0 @@
|
||||
.TH PULL-DEBIAN-DEBDIFF "1" "June 2010" "ubuntu-dev-tools"
|
||||
.SH NAME
|
||||
\fBsetup-packaging-environment\fR \- helps one to get started with Ubuntu development
|
||||
|
||||
.SH SYNOPSIS
|
||||
\fBsetup-packaging-environment\fR
|
||||
|
||||
.SH DESCRIPTION
|
||||
\fBsetup-packaging-environment\fR aims to make it more straightforward for new
|
||||
contributors to get their Ubuntu installation ready for packaging work. It
|
||||
ensures that all four components from Ubuntu's official repositories are enabled
|
||||
along with their corresponding source repositories. It also installs a minimal
|
||||
set of packages needed for Ubuntu packaging work (ubuntu-dev-tools, devscripts,
|
||||
debhelper, patchutils, pbuilder, and build-essential). Finally, it assists
|
||||
in defining the DEBEMAIL and DEBFULLNAME environment variables.
|
||||
|
||||
.SH AUTHORS
|
||||
\fBsetup-packaging-environment\fR was written by Siegfried-A. Gevatter <rainct@ubuntu.com>.
|
||||
|
||||
This manual page was written by Andrew Starr-Bochicchio <a.starr.b@gmail.com>.
|
||||
.PP
|
||||
Both are released under the terms of the GNU General Public License, version 3 or later.
|
@ -1,166 +0,0 @@
|
||||
.TH sponsor\-patch "1" "September 21 2010" "ubuntu-dev-tools"
|
||||
.SH NAME
|
||||
sponsor\-patch \- Prepare, test\-build, and sponsor an upload.
|
||||
|
||||
.SH SYNOPSIS
|
||||
.B sponsor\-patch \fR[\fIoptions\fR] \fIbug
|
||||
.br
|
||||
.B sponsor\-patch \-h
|
||||
|
||||
.SH DESCRIPTION
|
||||
\fBsponsor\-patch\fR downloads the patch or Bazaar branch linked to an
|
||||
Ubuntu bug, applies it, generates a review diff, (optionally) test
|
||||
builds it, runs
|
||||
.BR lintian (1)
|
||||
and, after review and confirmation, can upload it.
|
||||
|
||||
\fBsponsor\-patch\fR can be used for sponsoring patches, syncs and
|
||||
merges from Debian, SRUs, and creating debdiffs from patches.
|
||||
If \fIbug\fR has multiple patches or branches linked, it will prompt the
|
||||
user to select one.
|
||||
The same applies to bug tasks.
|
||||
If the attached patch is not a debdiff,
|
||||
.BR edit-patch (1)
|
||||
is used to apply it.
|
||||
|
||||
.nr step 1 1
|
||||
Some obvious checks are performed, in particular:
|
||||
.IP \n[step]. 4
|
||||
.BR update\-maintainer (1)
|
||||
is run on the source package to ensure that the \fBMaintainer\fR field
|
||||
meets the Ubuntu policy.
|
||||
.IP \n+[step].
|
||||
The version number must be greater than the current version in the
|
||||
archive.
|
||||
The \fBchanges\fR file is also correctly generated to list all changes
|
||||
since the current version in the archive.
|
||||
.IP \n+[step].
|
||||
The changelog must automatically close the sponsorship bug.
|
||||
.IP \n+[step].
|
||||
The changelog target must be valid.
|
||||
.IP \n+[step].
|
||||
The changelog timestamp is touched.
|
||||
|
||||
.PP
|
||||
Should any checks (or the build) fail, the user has an option to edit
|
||||
the patched source and try building it again.
|
||||
.PP
|
||||
Unless a working directory is specified, the sources and patches will be
|
||||
downloaded into a temporary directory in \fB/tmp\fR, which is removed once the
|
||||
script finishes running.
|
||||
The output of the build tool will be placed in \fIworkdir\fR/\fBbuildresult/\fR.
|
||||
|
||||
.PP
|
||||
One of \fB\-\-upload\fR, \fB\-\-workdir\fR, or \fB--sponsor\fR must be
|
||||
specified.
|
||||
|
||||
.SH OPTIONS
|
||||
.TP
|
||||
.BR \-b ", " \-\-build
|
||||
Build the package with the specified builder. Note for \fBpbuilder\fR(8) and
|
||||
\fBcowbuilder\fR(8) users:
|
||||
This assumes the common configuration, where the \fBARCH\fR and \fBDIST\fR
|
||||
environment is read by \fBpbuilderrc\fR(5) to select the correct base image.
|
||||
.TP
|
||||
.B \-B \fIBUILDER\fR, \fB\-\-builder\fR=\fIBUILDER
|
||||
Use the specify builder to build the package.
|
||||
Supported are \fBcowbuilder\fR(8), \fBcowbuilder-dist\fR(1), \fBpbuilder\fR(8),
|
||||
\fBpbuilder-dist\fR(1), and \fBsbuild\fR(1).
|
||||
The default is \fBpbuilder\fR(8).
|
||||
.TP
|
||||
.BR \-e ", " \-\-edit
|
||||
Launch a sub-shell to allow editing of the patched source before
|
||||
building.
|
||||
.TP
|
||||
.BR \-h ", " \-\-help
|
||||
Display a help message and exit.
|
||||
.TP
|
||||
.B \-k \fIKEY\fR, \fB\-\-key\fR=\fIKEY
|
||||
Specify a key ID for signing the upload.
|
||||
.TP
|
||||
.B \-l \fIINSTANCE\fR, \fB\-\-lpinstance\fR=\fIINSTANCE\fR
|
||||
Use the specified instance of Launchpad (e.g. "staging"), instead of
|
||||
the default of "production".
|
||||
.TP
|
||||
.B \-\-no\-conf
|
||||
Do not read any configuration files, or configuration from environment
|
||||
variables.
|
||||
.TP
|
||||
.BR \-s ", " \-\-sponsor
|
||||
Shortcut for sponsored uploads. Equivalent to \fB\-b \-u ubuntu\fR.
|
||||
.TP
|
||||
.B \-u \fIDEST\fR, \fB\-\-upload\fR=\fIDEST
|
||||
Upload to \fIDEST\fR with \fBdput\fR(1) (after confirmation).
|
||||
.TP
|
||||
.BR \-U ", " \-\-update
|
||||
Update the build environment before attempting to build.
|
||||
.TP
|
||||
.BR \-v ", " \-\-verbose
|
||||
Print more information.
|
||||
.TP
|
||||
.B \-w \fIDIR\fR, \fB\-\-workdir\fR=\fIDIR
|
||||
Use the specified working directory, creating it if necessary.
|
||||
If \fIWORKDIR\fR is not specified, a temporary directory is created, which is
|
||||
deleted before \fIsponsor-patch\fR exits.
|
||||
|
||||
.SH ENVIRONMENT
|
||||
All of the \fBCONFIGURATION VARIABLES\fR below are also supported as environment
|
||||
variables.
|
||||
Variables in the environment take precedence to those in configuration files.
|
||||
|
||||
.SH CONFIGURATION VARIABLES
|
||||
The following variables can be set in the environment or in
|
||||
.BR ubuntu\-dev\-tools (5)
|
||||
configuration files.
|
||||
In each case, the script\-specific variable takes precedence over the
|
||||
package\-wide variable.
|
||||
.TP
|
||||
.BR SPONSOR_PATCH_BUILDER ", " UBUNTUTOOLS_BUILDER
|
||||
The default value for \fB\-\-builder\fR.
|
||||
.TP
|
||||
.BR SPONSOR_PATCH_LPINSTANCE ", " UBUNTUTOOLS_LPINSTANCE
|
||||
The default value for \fB--lpinstance\fR.
|
||||
.TP
|
||||
.BR SPONSOR_PATCH_UPDATE_BUILDER ", " UBUNTUTOOLS_UPDATE_BUILDER
|
||||
The default value for \fB--update\fR.
|
||||
.TP
|
||||
.BR SPONSOR_PATCH_WORKDIR ", " UBUNTUTOOLS_WORKDIR
|
||||
The default value for \fB--workdir\fR.
|
||||
.TP
|
||||
.BR SPONSOR_PATCH_KEYID ", " UBUNTUTOOLS_KEYID
|
||||
The default value for \fB--key\fR.
|
||||
|
||||
.SH EXAMPLES
|
||||
Test-building and sponsoring an upload of bug \fB1234\fR:
|
||||
.IP
|
||||
.nf
|
||||
.B sponsor\-patch -s 1234
|
||||
.fi
|
||||
|
||||
.PP
|
||||
Performing a test build of bug \fB1234\fR in your PPA:
|
||||
.IP
|
||||
.nf
|
||||
.B sponsor\-patch -u ppa:\fIuser\fR/\fIppa\fB 1234
|
||||
.fi
|
||||
|
||||
.SH SEE ALSO
|
||||
.BR bzr (1),
|
||||
.BR debchange (1),
|
||||
.BR debdiff (1),
|
||||
.BR dput (1),
|
||||
.BR edit-patch (1),
|
||||
.BR lintian (1),
|
||||
.BR cowbuilder (8),
|
||||
.BR cowbuilder-dist (1),
|
||||
.BR pbuilder (8),
|
||||
.BR pbuilder-dist (1),
|
||||
.BR sbuild (1),
|
||||
.BR ubuntu\-dev\-tools (5),
|
||||
.BR update\-maintainer (1)
|
||||
|
||||
.SH AUTHORS
|
||||
\fBsponsor\-patch\fR was written by Benjamin Drung <bdrung@ubuntu.com>,
|
||||
and this manual page was written by Stefano Rivera <stefanor@ubuntu.com>.
|
||||
.PP
|
||||
Both are released under the terms of the ISC License.
|
@ -26,5 +26,3 @@ By examining debian/changelog it will extract the information it needs to:
|
||||
.br
|
||||
.SH AUTHOR
|
||||
submittodebian and this man page were written by Soren Hansen <soren@ubuntu.com>.
|
||||
.PP
|
||||
Both are released under the GNU General Public License, version 2 or later.
|
||||
|
27
doc/suspicious-source.1
Normal file
27
doc/suspicious-source.1
Normal file
@ -0,0 +1,27 @@
|
||||
.TH SUSPICIOUS\-SOURCE 1 "September 14, 2007" "ubuntu-dev-tools"
|
||||
|
||||
.SH NAME
|
||||
suspicious\-source \- search for files that are not the GPL's
|
||||
"preferred form of modification"
|
||||
|
||||
.SH SYNOPSIS
|
||||
\fBsuspicious\-source\fP
|
||||
|
||||
.SH DESCRIPTION
|
||||
\fBsuspicious\-source\fP is a script that outputs a list of files which
|
||||
are not common source files. This should be run in the root of a source
|
||||
tree to find files which might not be the "preferred form of modification"
|
||||
that the GPL and other licenses require.
|
||||
.PP
|
||||
Neither the files inside version control system directories (like
|
||||
".bzr/" or "CVS/"), nor those inside "debian/" are considered.
|
||||
|
||||
.SH SEE ALSO
|
||||
.BR find (1)
|
||||
|
||||
.SH AUTHORS
|
||||
\fBsuspicious\-source\fP and this manpage have been written by
|
||||
Siegfried-Angel Gevatter Pujals <rainct@ubuntu.com>, based upon a
|
||||
script with the same name from Martin Pitt <martin.pitt@ubuntu.com>.
|
||||
.PP
|
||||
Both are released under the GNU General Public License, version 3 or later.
|
@ -1,154 +0,0 @@
|
||||
.TH SYNCPACKAGE "1" "June 2010" "ubuntu-dev-tools"
|
||||
.SH NAME
|
||||
syncpackage \- copy source packages from Debian to Ubuntu
|
||||
.\"
|
||||
.SH SYNOPSIS
|
||||
.B syncpackage
|
||||
[\fIoptions\fR] \fI<.dsc URL/path or package name(s)>\fR
|
||||
.\"
|
||||
.SH DESCRIPTION
|
||||
\fBsyncpackage\fR causes one or more source package(s) to be copied from Debian
|
||||
to Ubuntu.
|
||||
.PP
|
||||
\fBsyncpackage\fR allows you to upload files with the same checksums of the
|
||||
Debian ones, as the common script used by Ubuntu archive administrators does,
|
||||
this way you can preserve source files integrity between the two distributions.
|
||||
.PP
|
||||
\fBsyncpackage\fR will detect source tarballs with mismatching
|
||||
checksums, and can perform fake syncs.
|
||||
.\"
|
||||
.SH WARNING
|
||||
The use of \fBsyncpackage \-\-no\-lp\fR, which generates a changes file to
|
||||
be directly uploaded to the Ubuntu primary archive or a PPA, is discouraged
|
||||
by the Ubuntu Archive Administrators, as it introduces an unnecessary window
|
||||
for error.
|
||||
This only exists for backward compatibility, for unusual corner cases
|
||||
(such as fakesyncs), and for uploads to archives other than the Ubuntu
|
||||
primary archive.
|
||||
Omitting this option will cause Launchpad to perform the sync request
|
||||
directly, which is the preferred method for uploads to the Ubuntu primary
|
||||
archive.
|
||||
.\"
|
||||
.SH OPTIONS
|
||||
.TP
|
||||
\fB\-h\fR, \fB\-\-help\fR
|
||||
Show help message and exit
|
||||
.TP
|
||||
\fB\-d\fI DIST\fR, \fB\-\-distribution\fR=\fIDIST\fR
|
||||
Debian distribution to sync from. Default is \fIunstable\fR.
|
||||
.TP
|
||||
\fB\-r\fI RELEASE\fR, \fB\-\-release\fR=\fIRELEASE\fR
|
||||
Specify target Ubuntu release. Default: current development release.
|
||||
.TP
|
||||
\fB\-V\fI DEBVERSION\fR, \fB\-\-debian\-version\fR=\fIDEBVERSION\fR
|
||||
Specify the version to sync from.
|
||||
.TP
|
||||
\fB\-c\fI COMPONENT\fR, \fB\-\-component\fR=\fICOMPONENT\fR
|
||||
Specify the component to sync from.
|
||||
.TP
|
||||
\fB\-b\fI BUG\fR, \fB\-\-bug\fR=\fIBUG\fR
|
||||
Mark a Launchpad bug as being fixed by this upload.
|
||||
.TP
|
||||
\fB\-s\fI USERNAME\fR, \fB\-\-sponsor\fR=\fIUSERNAME\fR
|
||||
Sponsor the sync for \fIUSERNAME\fR (a Launchpad username).
|
||||
.TP
|
||||
\fB\-v\fR, \fB\-\-verbose\fR
|
||||
Display more progress information.
|
||||
.TP
|
||||
\fB\-F\fR, \fB\-\-fakesync\fR
|
||||
Perform a fakesync, to work around a tarball mismatch between Debian and
|
||||
Ubuntu.
|
||||
This option ignores blocklisting, and performs a local sync.
|
||||
It implies \fB\-\-no\-lp\fR, and will leave a signed \fB.changes\fR file
|
||||
for you to upload.
|
||||
.TP
|
||||
\fB\-f\fR, \fB\-\-force\fR
|
||||
Force sync over the top of Ubuntu changes.
|
||||
.TP
|
||||
.B \-\-no\-conf
|
||||
Do not read any configuration files, or configuration from environment
|
||||
variables.
|
||||
.TP
|
||||
\fB\-l\fI INSTANCE\fR, \fB\-\-lpinstance\fR=\fIINSTANCE\fR
|
||||
Launchpad instance to connect to (default: production).
|
||||
.TP
|
||||
.B \-\-simulate
|
||||
Show what would be done, but don't actually do it.
|
||||
.\"
|
||||
.SH LOCAL SYNC PREPARATION OPTIONS
|
||||
.TP
|
||||
Options that only apply when using \fB\-\-no\-lp\fR:
|
||||
.TP
|
||||
.B \-\-no\-lp
|
||||
Construct sync locally, rather than letting Launchpad copy the package
|
||||
directly.
|
||||
It will leave a signed \fB.changes\fR file for you to upload.
|
||||
See the \fBWARNING\fR above.
|
||||
.TP
|
||||
\fB\-n\fI UPLOADER_NAME\fR, \fB\-\-uploader\-name\fR=\fIUPLOADER_NAME\fR
|
||||
Use UPLOADER_NAME as the name of the maintainer for this upload instead
|
||||
of evaluating DEBFULLNAME and UBUMAIL.
|
||||
This option may only be used in \fB\-\-no\-lp\fR mode.
|
||||
.TP
|
||||
\fB\-e\fI UPLOADER_EMAIL\fR, \fB\-\-uploader\-email\fR=\fIUPLOADER_EMAIL\fR
|
||||
Use UPLOADER_EMAIL as the email address of the maintainer for this
|
||||
upload instead of evaluating DEBEMAIL and UBUMAIL.
|
||||
This option may only be used in \fB\-\-no\-lp\fR mode.
|
||||
.TP
|
||||
\fB\-k\fI KEYID\fR, \fB\-\-key\fR=\fIKEYID\fR
|
||||
Specify the key ID to be used for signing.
|
||||
.TP
|
||||
\fB\-\-dont-sign\fR
|
||||
Do not sign the upload.
|
||||
.TP
|
||||
.B \-d \fIDEBIAN_MIRROR\fR, \fB\-\-debian\-mirror\fR=\fIDEBIAN_MIRROR\fR
|
||||
Use the specified mirror.
|
||||
Should be in the form \fBhttp://ftp.debian.org/debian\fR.
|
||||
If the package isn't found on this mirror, \fBsyncpackage\fR will fall
|
||||
back to the default mirror.
|
||||
.TP
|
||||
.B \-s \fIUBUNTU_MIRROR\fR, \fB\-\-debsec\-mirror\fR=\fIUBUNTU_MIRROR\fR
|
||||
Use the specified Debian security mirror.
|
||||
Should be in the form \fBhttp://archive.ubuntu.com/ubuntu\fR.
|
||||
If the package isn't found on this mirror, \fBsyncpackage\fR will fall
|
||||
back to the default mirror.
|
||||
.\"
|
||||
.SH ENVIRONMENT
|
||||
.TP
|
||||
.BR DEBFULLNAME ", " DEBEMAIL ", " UBUMAIL
|
||||
Used to determine the uploader (if not supplied as options).
|
||||
See
|
||||
.BR ubuntu\-dev\-tools (5)
|
||||
for details.
|
||||
.P
|
||||
All of the \fBCONFIGURATION VARIABLES\fR below are also supported as
|
||||
environment variables.
|
||||
Variables in the environment take precedence to those in configuration
|
||||
files.
|
||||
.\"
|
||||
.SH CONFIGURATION VARIABLES
|
||||
The following variables can be set in the environment or in
|
||||
.BR ubuntu\-dev\-tools (5)
|
||||
configuration files.
|
||||
In each case, the script\-specific variable takes precedence over the
|
||||
package\-wide variable.
|
||||
.TP
|
||||
.BR SYNCPACKAGE_DEBIAN_MIRROR ", " UBUNTUTOOLS_DEBIAN_MIRROR
|
||||
The default value for \fB\-\-debian\-mirror\fR.
|
||||
.TP
|
||||
.BR SYNCPACKAGE_UBUNTU_MIRROR ", " UBUNTUTOOLS_DEBSEC_MIRROR
|
||||
The default value for \fB\-\-ubuntu\-mirror\fR.
|
||||
.TP
|
||||
.BR SYNCPACKAGE_KEYID ", " UBUNTUTOOLS_KEYID
|
||||
The default value for \fB\-\-key\fR.
|
||||
.\"
|
||||
.SH SEE ALSO
|
||||
.BR requestsync (1),
|
||||
.BR ubuntu\-dev\-tools (5)
|
||||
.\"
|
||||
.SH AUTHOR
|
||||
\fBsyncpackage\fR was written by Martin Pitt <martin.pitt@canonical.com> and Benjamin Drung <bdrung@ubuntu.com>.
|
||||
.PP
|
||||
This manual page was written by Luca Falavigna <dktrkranz@ubuntu.com>
|
||||
.PP
|
||||
Both are released under GNU General Public License, version 3.
|
@ -1,78 +0,0 @@
|
||||
.TH UBUNTU-BUILD "1" "Mar 2024" "ubuntu-dev-tools"
|
||||
.SH NAME
|
||||
ubuntu-build \- command-line interface to Launchpad build operations
|
||||
|
||||
.SH SYNOPSIS
|
||||
.nf
|
||||
\fBubuntu-build\fR <srcpackage> <release> <operation>
|
||||
\fBubuntu-build\fR --batch [--retry] [--rescore \fIPRIORITY\fR] [--arch \fIARCH\fR [...]]
|
||||
[--series \fISERIES\fR] [--state \fIBUILD-STATE\fR]
|
||||
[-A \fIARCHIVE\fR] [pkg]...
|
||||
.fi
|
||||
|
||||
.SH DESCRIPTION
|
||||
\fBubuntu-build\fR provides a command line interface to the Launchpad build
|
||||
operations.
|
||||
|
||||
.SH OPERATIONS
|
||||
Listed below are the available operations for \fBubuntu-build\fR:
|
||||
.TP
|
||||
.B status
|
||||
Outputs the build status of the package on Launchpad on all architectures.
|
||||
.TP
|
||||
.B retry
|
||||
Requests that the package has another attempt at rebuilding from source.
|
||||
This will only work if the package has \fIFailed to build\fR on Launchpad.
|
||||
.TP
|
||||
.B rescore
|
||||
Requests that the package's build priority be raised in the build queue.
|
||||
Only members of the Launchpad build administrators may issue this operation,
|
||||
and it may only be performed on packages which \fINeed building\fR.
|
||||
|
||||
.SH OPTIONS
|
||||
Listed below are the command line options for \fBubuntu-build\fR:
|
||||
.TP
|
||||
.B \-h or \-\-help
|
||||
Display a help message and exit.
|
||||
.TP
|
||||
Retry and rescore options:
|
||||
.IP
|
||||
These options may only be used with the 'retry' and 'rescore'
|
||||
operations.
|
||||
.IP
|
||||
\fB\-a\fR ARCHITECTURE, \fB\-\-arch\fR=\fIARCHITECTURE\fR
|
||||
Rebuild or rescore a specific architecture. Valid
|
||||
architectures are:
|
||||
armhf, arm64, amd64, i386, powerpc, ppc64el, riscv64, s390x.
|
||||
.TP
|
||||
Batch processing:
|
||||
.IP
|
||||
These options and parameter ordering is only available in \fB\-\-batch\fR
|
||||
mode. Usage: ubuntu\-build \fB\-\-batch\fR [options] <package>...
|
||||
.IP
|
||||
\fB\-\-batch\fR
|
||||
Enable batch mode
|
||||
.IP
|
||||
\fB\-\-series\fR=\fISERIES\fR
|
||||
Selects the Ubuntu series to operate on (default:
|
||||
current development series)
|
||||
.IP
|
||||
\fB\-\-retry\fR
|
||||
Retry builds (give\-back).
|
||||
.IP
|
||||
\fB\-\-rescore\fR=\fIPRIORITY\fR
|
||||
Rescore builds to <priority>.
|
||||
.IP
|
||||
\fB\-\-arch\fR=\fIARCHITECTURE\fR
|
||||
Affect only 'architecture' (can be used several
|
||||
times). Valid architectures are:
|
||||
arm64, amd64, i386, powerpc, ppc64el, riscv64, s390x.
|
||||
.IP
|
||||
\fB\-A=\fIARCHIVE\fR
|
||||
Act on the named archive (ppa) instead of on the main Ubuntu archive.
|
||||
|
||||
.SH AUTHORS
|
||||
\fBubuntu-build\fR was written by Martin Pitt <martin.pitt@canonical.com>, and
|
||||
this manual page was written by Jonathan Patrick Davies <jpds@ubuntu.com>.
|
||||
.PP
|
||||
Both are released under the terms of the GNU General Public License, version 3.
|
@ -1,110 +0,0 @@
|
||||
.\" Copyright (C) 2010, Stefano Rivera <stefanor@ubuntu.com>
|
||||
.\"
|
||||
.\" Permission to use, copy, modify, and/or distribute this software for any
|
||||
.\" purpose with or without fee is hereby granted, provided that the above
|
||||
.\" copyright notice and this permission notice appear in all copies.
|
||||
.\"
|
||||
.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
||||
.\" REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
||||
.\" AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
||||
.\" INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
||||
.\" LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
||||
.\" OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
||||
.\" PERFORMANCE OF THIS SOFTWARE.
|
||||
.TH ubuntu\-dev\-tools "5" "December 19 2010" "ubuntu\-dev\-tools"
|
||||
.SH NAME
|
||||
ubuntu\-dev\-tools \- Configuration for the ubuntu\-dev\-tools package.
|
||||
|
||||
.SH DESCRIPTION
|
||||
The \fBubuntu\-dev\-tools\fR package is similar in scope to the
|
||||
.BR devscripts (1)
|
||||
package, providing a collection of scripts which may be of use
|
||||
to Ubuntu and Debian developers or others wishing to build Debian packages.
|
||||
|
||||
Some of these scripts have options which may be configured on a
|
||||
system\-wide and per\-user basis.
|
||||
These options are configured in
|
||||
.BR devscripts.conf (5).
|
||||
|
||||
All variables are described in the script's manpages. Package\-wide
|
||||
variables begin with "\fIUBUNTUTOOLS\fR" and are listed below.
|
||||
|
||||
Every script which reads the configuration files can be forced to ignore
|
||||
them by using the \fB\-\-no\-conf\fR command\-line option.
|
||||
|
||||
.SH ENVIRONMENT
|
||||
All \fBubuntu\-dev\-tools\fR configuration variables can be set (and
|
||||
overridden) by setting them in the environment (unlike
|
||||
\fBdevscripts\fR).
|
||||
|
||||
In addition, several scripts use the following environment variables:
|
||||
|
||||
.TP
|
||||
.B UBUMAIL
|
||||
Overrides \fBDEBEMAIL\fR and \fBDEBFULLNAME\fR when the target is
|
||||
clearly Ubuntu.
|
||||
Can either contain an e-mail address or \fBFull Name
|
||||
<email@example.org>\fR.
|
||||
|
||||
.TP
|
||||
.BR DEBEMAIL ", " DEBFULLNAME
|
||||
As in
|
||||
.BR devscripts (1).
|
||||
|
||||
.SH PACKAGE\-WIDE VARIABLES
|
||||
The currently recognised package\-wide variables are:
|
||||
.TP
|
||||
.B UBUNTUTOOLS_BUILDER
|
||||
This specifies the preferred test\-builder, one of
|
||||
.BR pbuilder " (default), " sbuild ", " pbuilder\-dist .
|
||||
.TP
|
||||
.B UBUNTUTOOLS_DEBIAN_MIRROR
|
||||
The preferred Debian archive mirror.
|
||||
Should be of the form \fBhttp://ftp.debian.org/debian\fR (no trailing
|
||||
slash).
|
||||
If not specified, the master will be used.
|
||||
.TP
|
||||
.B UBUNTUTOOLS_DEBSEC_MIRROR
|
||||
The preferred Debian security archive mirror.
|
||||
Should be of the form \fBhttp://security.debian.org\fR (no trailing
|
||||
slash).
|
||||
If not specified, the master will be used.
|
||||
.TP
|
||||
.B UBUNTUTOOLS_UBUNTU_MIRROR
|
||||
The preferred Ubuntu archive mirror.
|
||||
Should be of the form \fBhttp://archive.ubuntu.com/ubuntu\fR (no
|
||||
trailing slash).
|
||||
If not specified, the master will be used.
|
||||
.TP
|
||||
.B UBUNTUTOOLS_UBUNTU_PORTS_MIRROR
|
||||
The preferred Ubuntu archive mirror.
|
||||
Should be of the form \fBhttp://ports.ubuntu.com\fR (no
|
||||
trailing slash).
|
||||
If not specified, the master will be used.
|
||||
.TP
|
||||
.B UBUNTUTOOLS_LPINSTANCE
|
||||
The launchpad instance to communicate with. e.g. \fBproduction\fR
|
||||
(default) or \fBstaging\fR.
|
||||
.TP
|
||||
.B UBUNTUTOOLS_MIRROR_FALLBACK
|
||||
Whether or not to fall\-back to the master archive mirror.
|
||||
This is usually the desired behaviour, as mirrors can lag the masters.
|
||||
If on a private network with only a local mirror, you may want to set
|
||||
this to \fBno\fR.
|
||||
.RB "One of " yes " (default) or " no .
|
||||
.TP
|
||||
.B UBUNTUTOOLS_UPDATE_BUILDER
|
||||
Whether or not to update the test\-builder before each test build.
|
||||
.RB "One of " yes " or " no " (default).
|
||||
.TP
|
||||
.B UBUNTUTOOLS_WORKDIR
|
||||
The directory to use for preparing source packages etc.
|
||||
When unset, defaults to a directory in \fI/tmp/\fR named after the
|
||||
script.
|
||||
|
||||
.SH SEE ALSO
|
||||
.BR devscripts (1),
|
||||
.BR devscripts.conf (5)
|
||||
|
||||
.SH AUTHORS
|
||||
This manpage was written by Stefano Rivera <stefanor@ubuntu.com>.
|
@ -1,16 +0,0 @@
|
||||
.TH UBUNTU_ISO "1" "June 2010" "ubuntu-dev-tools"
|
||||
.SH NAME
|
||||
\fBubuntu-iso\fR \- tool to examine Ubuntu CD (ISO) installation media
|
||||
|
||||
.SH SYNOPSIS
|
||||
\fBubuntu-iso\fR <path to ISO>
|
||||
|
||||
.SH DESCRIPTION
|
||||
When given a path to an ISO, \fBubuntu-iso\fR will determine whether it is an Ubuntu ISO or not. If it is, it will extract and display the version information.
|
||||
|
||||
.SH AUTHORS
|
||||
\fBubuntu-iso\fR was written by Matt Zimmerman <mdz@ubuntu.com>.
|
||||
|
||||
This manual page was written by Andrew Starr-Bochicchio <a.starr.b@gmail.com>.
|
||||
.PP
|
||||
Both are released under the terms of the GNU General Public License, version 2.
|
@ -1,60 +0,0 @@
|
||||
.\" Copyright (C) 2011, Stefano Rivera <stefanor@ubuntu.com>
|
||||
.\"
|
||||
.\" Permission to use, copy, modify, and/or distribute this software for any
|
||||
.\" purpose with or without fee is hereby granted, provided that the above
|
||||
.\" copyright notice and this permission notice appear in all copies.
|
||||
.\"
|
||||
.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
||||
.\" REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
||||
.\" AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
||||
.\" INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
||||
.\" LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
||||
.\" OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
||||
.\" PERFORMANCE OF THIS SOFTWARE.
|
||||
.TH ubuntu\-upload\-permission 1 "November 2011" ubuntu\-dev\-tools
|
||||
|
||||
.SH NAME
|
||||
ubuntu\-upload\-permission \- Query upload rights and (optionally) list
|
||||
the people and teams with upload rights for a package
|
||||
|
||||
.SH SYNOPSIS
|
||||
.B ubuntu\-upload\-permission \fR[\fIoptions\fR] \fIpackage
|
||||
|
||||
.SH DESCRIPTION
|
||||
\fBubuntu\-upload\-permission\fR checks if the user has upload
|
||||
permissions for \fIpackage\fR.
|
||||
If the \fB\-\-list\-uploaders\fR option is provided, all the people and
|
||||
teams that do have upload rights for \fIpackage\fR will be listed.
|
||||
|
||||
.SH OPTIONS
|
||||
.TP
|
||||
\fB\-r\fR \fIRELEASE\fR, \fB\-\-release\fR=\fIRELEASE\fR
|
||||
Query permissions in \fIRELEASE\fR.
|
||||
Default: current development release.
|
||||
.TP
|
||||
\fB\-a\fR, \fB\-\-list\-uploaders\fR
|
||||
List all the people and teams who have upload rights for \fIpackage\fR.
|
||||
.TP
|
||||
\fB\-t\fR, \fB\-\-list\-team\-members\fR
|
||||
List all the members of every team with rights. (Implies
|
||||
\fB\-\-list\-uploaders\fR)
|
||||
.TP
|
||||
\fB\-h\fR, \fB\-\-help\fR
|
||||
Display a help message and exit
|
||||
|
||||
.SH EXIT STATUS
|
||||
.TP
|
||||
.B 0
|
||||
You have the necessary upload rights.
|
||||
.TP
|
||||
.B 1
|
||||
You don't have the necessary upload rights.
|
||||
.TP
|
||||
.B 2
|
||||
There was an error.
|
||||
|
||||
.SH AUTHORS
|
||||
\fBubuntu\-upload\-permission\fR and this manpage were written by
|
||||
Stefano Rivera <stefanor@ubuntu.com>.
|
||||
.PP
|
||||
Both are released under the terms of the ISC License.
|
@ -1,47 +1,34 @@
|
||||
.\" Copyright (c) 2008, Siegfried-Angel Gevatter Pujals <rainct@ubuntu.com>
|
||||
.\" 2010, Benjamin Drung <bdrung@ubuntu.com>
|
||||
.\"
|
||||
.\" Permission to use, copy, modify, and/or distribute this software for any
|
||||
.\" purpose with or without fee is hereby granted, provided that the above
|
||||
.\" copyright notice and this permission notice appear in all copies.
|
||||
.\"
|
||||
.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
.\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
.\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
.\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
.\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
.\"
|
||||
.TH UPDATE\-MAINTAINER "1" "December 2010" "ubuntu-dev-tools"
|
||||
.TH UPDATE\-MAINTAINER "1" "February 17, 2008" "ubuntu-dev-tools"
|
||||
|
||||
.SH NAME
|
||||
update\-maintainer \- change the Maintainer field in a Debian source package
|
||||
update\-maintainer \- change Maintainer field in a Debian source package
|
||||
|
||||
.SH SYNOPSIS
|
||||
.B update\-maintainer
|
||||
[\fIoptions\fR]
|
||||
.B update\-maintainer [\fI\-\-path=<PATH>\fR] [\fI\-\-section=<SECTION>\fR] [\fI\-\-nochangelog\fR]
|
||||
|
||||
.SH DESCRIPTION
|
||||
\fBupdate\-maintainer\fP updates the Maintainer field in the source of
|
||||
an Ubuntu package to match the DebianMaintainerField specification.
|
||||
.PP
|
||||
See https://wiki.ubuntu.com/DebianMaintainerField for more information.
|
||||
|
||||
.SH OPTIONS
|
||||
.TP
|
||||
\fB\-d \fIPATH\fR, \fB\-\-debian\-directory\fR=\fIPATH\fR
|
||||
location of the \fIdebian\fR directory (default: \fB./debian\fR)
|
||||
\fB\-\-path=<PATH>\fP
|
||||
This option allows you to specify the path to the source directory.
|
||||
.TP
|
||||
\fB\-h\fR, \fB\-\-help\fR
|
||||
show a help message and exit
|
||||
\fB\-\-section=<SECTION>\fP
|
||||
Manually specify the section of the package. This is necessary if the
|
||||
package is not yet in the archive or if you don't have an Internet
|
||||
connection available when you run \fBupdate\-maintainer\fP.
|
||||
.TP
|
||||
\fB\-q\fR, \fB\-\-quiet\fR
|
||||
print no informational messages
|
||||
|
||||
.SH SEE ALSO
|
||||
See https://wiki.ubuntu.com/DebianMaintainerField for more information.
|
||||
\fB\-\-nochangelog\fP, \fB\-\-no\-changelog\fP
|
||||
By default, \fBupdate\-maintainer\fP adds an entry to the changelog
|
||||
explaining that it changed the Maintainer field. If you don't want
|
||||
that to happen, use this option.
|
||||
|
||||
.SH AUTHOR
|
||||
\fBupdate-maintainer\fP has been written by Benjamin Drung <bdrung@ubuntu.com>
|
||||
\fBupdate-maintainer\fP has been written by Albin Tonnerre <lut1n.tne@gmail.com>
|
||||
and this manual page by Siegfried-Angel Gevatter Pujals <rainct@ubuntu.com>.
|
||||
.PP
|
||||
Both are released under the ISC license.
|
||||
Both are released under the GNU General Public License, version 2.
|
||||
|
@ -1,62 +0,0 @@
|
||||
#!/usr/bin/python3
|
||||
#
|
||||
# Copyright (C) 2011, Stefano Rivera <stefanor@ubuntu.com>
|
||||
#
|
||||
# Permission to use, copy, modify, and/or distribute this software for any
|
||||
# purpose with or without fee is hereby granted, provided that the above
|
||||
# copyright notice and this permission notice appear in all copies.
|
||||
#
|
||||
# THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
# WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
# MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
# ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
# WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
# ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
#
|
||||
#
|
||||
# Wraps sensisible-editor in checks for remaining boilerplate.
|
||||
# Configured through environment variables:
|
||||
# UDT_EDIT_WRAPPER_EDITOR: The user's usual $EDITOR
|
||||
# UDT_EDIT_WRAPPER_VISUAL: The user's usual $VISUAL
|
||||
# UDT_EDIT_WRAPPER_TEMPLATE_RE: An extra boilerplate-detecting regex.
|
||||
# UDT_EDIT_WRAPPER_FILE_DESCRIPTION: The type of file being edited.
|
||||
|
||||
# pylint: disable=invalid-name
|
||||
# pylint: enable=invalid-name
|
||||
|
||||
import argparse
|
||||
import os
|
||||
import re
|
||||
|
||||
from ubuntutools.question import EditFile
|
||||
|
||||
|
||||
def main():
|
||||
parser = argparse.ArgumentParser(usage="%(prog)s [options] filename")
|
||||
parser.add_argument("filename", help=argparse.SUPPRESS)
|
||||
args = parser.parse_args()
|
||||
if not os.path.isfile(args.filename):
|
||||
parser.error(f"File {args.filename} does not exist")
|
||||
|
||||
if "UDT_EDIT_WRAPPER_EDITOR" in os.environ:
|
||||
os.environ["EDITOR"] = os.environ["UDT_EDIT_WRAPPER_EDITOR"]
|
||||
else:
|
||||
del os.environ["EDITOR"]
|
||||
|
||||
if "UDT_EDIT_WRAPPER_VISUAL" in os.environ:
|
||||
os.environ["VISUAL"] = os.environ["UDT_EDIT_WRAPPER_VISUAL"]
|
||||
else:
|
||||
del os.environ["VISUAL"]
|
||||
|
||||
placeholders = []
|
||||
if "UDT_EDIT_WRAPPER_TEMPLATE_RE" in os.environ:
|
||||
placeholders.append(re.compile(os.environ["UDT_EDIT_WRAPPER_TEMPLATE_RE"]))
|
||||
|
||||
description = os.environ.get("UDT_EDIT_WRAPPER_FILE_DESCRIPTION", "file")
|
||||
|
||||
EditFile(args.filename, description, placeholders).edit()
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
16
examples/massfile.instructions
Normal file
16
examples/massfile.instructions
Normal file
@ -0,0 +1,16 @@
|
||||
subject: [UNMETDEPS] $pack has unmet dependencies
|
||||
assignee:
|
||||
subscribers: motu
|
||||
tags: unmetdeps
|
||||
buglist-url: http://bugs.launchpad.net/ubuntu/+bugs?field.tag=unmetdeps
|
||||
text:
|
||||
A run of
|
||||
.
|
||||
LC_ALL=C apt-cache -i unmet | grep ^Package | cut -d' ' -f2 | grep
|
||||
-v dbgsym | sort -u | xargs apt-cache showsrc | grep ^Directory |
|
||||
sed 's/Package\:\ //g' | grep verse | cut -d'/' -f4
|
||||
indicates that the source package $pack has binary packages that are not
|
||||
installable (on AMD64) at the moment.
|
||||
.
|
||||
Please have a look and make sure it's installable again.
|
||||
|
2
examples/massfile.list
Normal file
2
examples/massfile.list
Normal file
@ -0,0 +1,2 @@
|
||||
z88dk
|
||||
zope-quotafolder
|
70
get-branches
Executable file
70
get-branches
Executable file
@ -0,0 +1,70 @@
|
||||
#!/usr/bin/python
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright 2007 (C) Canonical Ltd.
|
||||
# Created by Daniel Holbach <daniel.holbach@ubuntu.com>
|
||||
# License: GPLv3
|
||||
#
|
||||
# This script is used to checkout or branch all the Bazaar branches
|
||||
# in a Launchpad team.
|
||||
|
||||
import urllib2
|
||||
import sys
|
||||
import re
|
||||
import os
|
||||
|
||||
def main():
|
||||
usage = "Usage: get-branches <directory> <team> [checkout|branch]"
|
||||
if len(sys.argv) < 3:
|
||||
print >> sys.stderr, usage
|
||||
sys.exit(1)
|
||||
|
||||
directory = os.path.abspath(sys.argv[1]))
|
||||
team = sys.argv[2]
|
||||
operation_type = "branch"
|
||||
if len(sys.argv) == 4:
|
||||
operation_type = sys.argv[3]
|
||||
|
||||
pwd = os.getcwd()
|
||||
try:
|
||||
os.chdir(directory)
|
||||
except:
|
||||
print >> sys.stderr, "Directory '%s' not found." % directory
|
||||
sys.exit(1)
|
||||
|
||||
try:
|
||||
os.makedirs(team)
|
||||
except:
|
||||
pass
|
||||
os.chdir(team)
|
||||
|
||||
sock = urllib2.urlopen("http://code.launchpad.net/~%s" % team)
|
||||
branch_list_page = sock.read()
|
||||
sock.close()
|
||||
branch_page_urls_regex = r'.*<a href="/(~%s/.*)".*' % team
|
||||
branch_page_urls = re.findall(branch_page_urls_regex, branch_list_page)
|
||||
for url in branch_page_urls:
|
||||
sock = urllib2.urlopen("http://code.launchpad.net/%s" % url)
|
||||
branch_page = sock.read()
|
||||
sock.close()
|
||||
branch_url_regex = r'<th>Hosted on Launchpad:</th>.*\n.*<td>(.*)</td>'
|
||||
branch_url = re.findall(branch_url_regex, branch_page)
|
||||
print branch_url[0]
|
||||
if branch_url[0]:
|
||||
product = branch_url[0].split("/")[-2]
|
||||
branch_nick = branch_url[0].split("/")[-1]
|
||||
if not os.path.exists(product):
|
||||
os.makedirs(product)
|
||||
os.chdir(product)
|
||||
if not os.path.exists(branch_nick):
|
||||
os.system("bzr %s %s" % (operation_type, branch_url[0]))
|
||||
else:
|
||||
os.chdir(branch_nick)
|
||||
os.system("bzr merge --pull --remember")
|
||||
os.chdir(os.path.join(directory, team))
|
||||
|
||||
os.chdir(pwd)
|
||||
sys.exit(0)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
79
get-build-deps
Executable file
79
get-build-deps
Executable file
@ -0,0 +1,79 @@
|
||||
#!/bin/bash
|
||||
# Copyright 2007 (C) Siegfried-A. Gevatter <rainct@ubuntu.com>
|
||||
# License: GPLv3 or later
|
||||
#
|
||||
# If you don't pass it any argument, this script will check if
|
||||
# there's a control (debian/control) file somewhere in the current
|
||||
# directory, and if it's so, it'll install the build dependencies
|
||||
# listed there.
|
||||
#
|
||||
# If it gets a single argument, and it's the name of a file, it will
|
||||
# read it, supposing that each line contains the name of a package,
|
||||
# and install the build dependencies for all those.
|
||||
#
|
||||
# Otherwise, if there is more than one argument, or the given argument
|
||||
# isn't the name of an existing file, it will suppose that the each
|
||||
# argument is the name of a package, and install the dependencies for
|
||||
# all of them.
|
||||
|
||||
if [ $# -eq 0 ]
|
||||
then
|
||||
#########################################################
|
||||
# Install the dependencies for the source package the
|
||||
# user is working on.
|
||||
|
||||
if [ -f ../debian/control ]; then
|
||||
cd ..
|
||||
elif [ ! -f ./debian/control ]; then
|
||||
echo "\
|
||||
Couldn't find file debian/control. You have to be inside the \
|
||||
source directory of a Debian package or pass the name of the \
|
||||
package(s) whose build dependencies you want to install in order \
|
||||
to use this script."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
filepath="`pwd`/debian/control"
|
||||
missing_dependencies=$(dpkg-checkbuilddeps 2>&1)
|
||||
|
||||
if [ -z "$missing_dependencies" ]; then
|
||||
echo "The build dependencies described in «$filepath» are already satisfied."
|
||||
exit 0
|
||||
fi
|
||||
|
||||
echo "Installing the build dependencies described in «$filepath»..."
|
||||
|
||||
if [ -x /usr/lib/pbuilder/pbuilder-satisfydepends ]
|
||||
then
|
||||
sudo /usr/lib/pbuilder/pbuilder-satisfydepends
|
||||
else
|
||||
echo "Warning: «pbuilder» isn\'t installed, falling back to «dpkg-checkbuilddeps»."
|
||||
sudo aptitude install $(echo $missing_dependencies | awk -F: '{ print $3 }' | sed 's/([^)]*)//g' | sed 's/|\s[^\s]*//g')
|
||||
#' <--- Fix to avoid Geanys markup breaking
|
||||
fi
|
||||
exit 0
|
||||
elif [ $# -eq 1 ]
|
||||
then
|
||||
#########################################################
|
||||
# Check if the given argument is a file name, else
|
||||
# continue after the if.
|
||||
if [ -f $1 ]
|
||||
then
|
||||
packages=''
|
||||
echo "Installing the build dependencies for the following packages:"
|
||||
while read line
|
||||
do
|
||||
echo $line
|
||||
packages="$packages $line"
|
||||
done < $1
|
||||
echo
|
||||
sudo apt-get build-dep $packages
|
||||
exit 0
|
||||
fi
|
||||
fi
|
||||
|
||||
#########################################################
|
||||
# All arguments should be package names, install
|
||||
# their build dependencies.
|
||||
|
||||
sudo apt-get build-dep $*
|
37
grab-attachments
Executable file
37
grab-attachments
Executable file
@ -0,0 +1,37 @@
|
||||
#!/usr/bin/python
|
||||
#
|
||||
# Copyright 2007, Canonical, Daniel Holbach
|
||||
#
|
||||
# GPL 3
|
||||
#
|
||||
|
||||
import os
|
||||
import sys
|
||||
import urllib
|
||||
import launchpadbugs.connector as Connector
|
||||
|
||||
USAGE = "grab-attachments <bug numbers>"
|
||||
|
||||
def main():
|
||||
if len(sys.argv) == 1:
|
||||
print >> sys.stderr, USAGE
|
||||
sys.exit(1)
|
||||
|
||||
if sys.argv[1] in ["--help", "-h"]:
|
||||
print USAGE
|
||||
sys.exit(0)
|
||||
Bug = Connector.ConnectBug(method="Text")
|
||||
for arg in sys.argv[1:]:
|
||||
try:
|
||||
number = int(arg)
|
||||
except:
|
||||
print >> sys.stderr, "'%s' is not a valid bug number." % arg
|
||||
sys.exit(1)
|
||||
b = Bug(number)
|
||||
for a in b.attachments:
|
||||
filename = os.path.join(os.getcwd(), a.url.split("/")[-1])
|
||||
urllib.urlretrieve(a.url, filename)
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
|
124
grab-merge
124
grab-merge
@ -1,124 +0,0 @@
|
||||
#!/bin/sh
|
||||
# grab-merge - grab a merge
|
||||
#
|
||||
# Copyright © 2008 Canonical Ltd.
|
||||
# Author: Scott James Remnant <scott@ubuntu.com>.
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of version 3 of the GNU General Public License as
|
||||
# published by the Free Software Foundation.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
# Uncomment if you have an account on casey
|
||||
#RSYNC=y
|
||||
|
||||
# Uncomment if you know that this deletes all the files in the CWD
|
||||
#EXPERT=y
|
||||
|
||||
# Or uncomment if you want to use named subdirectories
|
||||
SUBDIR=y
|
||||
|
||||
set -e
|
||||
|
||||
MERGE=$1
|
||||
|
||||
if [ -z "$1" -o "$1" = "-h" -o "$1" = "--help" ]; then
|
||||
echo "Usage: $0 <package name>"
|
||||
echo ""
|
||||
echo "grab-merge downloads a merge's packaging files and report from"
|
||||
echo "merges.ubuntu.com, placing them into a new subdirectory for working"
|
||||
echo "from."
|
||||
|
||||
exit 0
|
||||
fi
|
||||
|
||||
if [ "$SUBDIR" = "y" ]; then
|
||||
[ -d "$MERGE" ] || { mkdir $MERGE; CREATED_DIR=1; }
|
||||
cd $MERGE
|
||||
fi
|
||||
|
||||
if [ "$EXPERT" != "y" ] && [ -n "$(ls)" ]; then
|
||||
echo -n "Are you sure you want to delete all the files in $(pwd) [yN]? "
|
||||
read ANSWER
|
||||
[ "$ANSWER" = "y" ] || exit 1
|
||||
fi
|
||||
|
||||
if [ "${MERGE#lib}" != "${MERGE}" ]; then
|
||||
HASH=${MERGE%${MERGE#????}}
|
||||
else
|
||||
HASH=${MERGE%${MERGE#?}}
|
||||
fi
|
||||
|
||||
if [ "$RSYNC" = "y" ]; then
|
||||
URL="merges.ubuntu.com:/srv/patches.ubuntu.com/merges/$HASH/$MERGE/"
|
||||
rsync --verbose --archive --progress --compress --delete \
|
||||
"$URL" . || { echo "Error while rsyncing $URL"; exit 1; }
|
||||
else
|
||||
rm -rf --one-file-system *
|
||||
wget -nv https://merges.ubuntu.com/$HASH/$MERGE/REPORT || {
|
||||
echo "Package not found on merges.ubuntu.com."
|
||||
[ "$CREATED_DIR" != "1" ] || { cd ..; rmdir $MERGE; }
|
||||
exit 1
|
||||
}
|
||||
|
||||
for NAME in $(sed -n -e "/^ /p" REPORT); do
|
||||
if [ ! -f "$NAME" ]; then
|
||||
echo "Getting $NAME..."
|
||||
URL="https://merges.ubuntu.com/$HASH/$MERGE/$NAME"
|
||||
wget -q "$URL" || { echo "Error downloading $URL"; exit 1; }
|
||||
fi
|
||||
done
|
||||
fi
|
||||
echo
|
||||
|
||||
if grep "^generated: " REPORT >/dev/null; then
|
||||
VERSION=$(sed -n -e "/^generated:/s/^generated: *//p" REPORT)
|
||||
DEB_VENDOR=Ubuntu dpkg-source -x ${MERGE}_${VERSION#*:}.dsc
|
||||
echo
|
||||
else
|
||||
TARBALL=$(sed -n -e "/\.src\.tar\.gz$/p" REPORT)
|
||||
|
||||
echo unpacking $TARBALL
|
||||
tar xf $TARBALL
|
||||
echo
|
||||
fi
|
||||
|
||||
if grep "^ C" REPORT; then
|
||||
echo
|
||||
fi
|
||||
|
||||
echo "#!/bin/sh" > merge-genchanges
|
||||
echo "exec $(sed -n -e '/^ $ /s/^ $ //p' REPORT) \"\$@\"" \
|
||||
>> merge-genchanges
|
||||
chmod +x merge-genchanges
|
||||
|
||||
echo "#!/bin/sh" > merge-buildpackage
|
||||
echo "exec $(sed -n -e '/^ $ /s/^ $ dpkg-genchanges/dpkg-buildpackage/p' REPORT) \"\$@\"" \
|
||||
>> merge-buildpackage
|
||||
chmod +x merge-buildpackage
|
||||
|
||||
echo "#!/bin/sh" > merge-debuild
|
||||
echo "exec $(sed -n -e '/^ $ /s/^ $ dpkg-genchanges/debuild/p' REPORT) \"\$@\"" \
|
||||
>> merge-debuild
|
||||
chmod +x merge-debuild
|
||||
|
||||
echo "Run ../merge-genchanges , ../merge-buildpackage or ../merge-debuild when done"
|
||||
|
||||
if grep "^Vcs-" *.dsc >/dev/null; then
|
||||
echo
|
||||
echo "*** WARNING ***"
|
||||
echo
|
||||
echo "It looks like this package is maintained in revision control:"
|
||||
echo
|
||||
grep "^Vcs-" *.dsc
|
||||
echo
|
||||
echo "You almost certainly don't want to continue without investigating."
|
||||
exit 1
|
||||
fi
|
88
grep-merges
88
grep-merges
@ -1,88 +0,0 @@
|
||||
#! /usr/bin/python3
|
||||
#
|
||||
# grep-merges - search for pending merges from Debian
|
||||
#
|
||||
# Copyright (C) 2010 Canonical Ltd.
|
||||
# Authors:
|
||||
# - Colin Watson <cjwatson@ubuntu.com>
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation, either version 3 of the License, or
|
||||
# (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
# pylint: disable=invalid-name
|
||||
# pylint: enable=invalid-name
|
||||
|
||||
import argparse
|
||||
import json
|
||||
import sys
|
||||
|
||||
from httplib2 import Http, HttpLib2Error
|
||||
|
||||
import ubuntutools.misc
|
||||
from ubuntutools import getLogger
|
||||
|
||||
Logger = getLogger()
|
||||
|
||||
|
||||
def main():
|
||||
parser = argparse.ArgumentParser(
|
||||
usage="%(prog)s [options] [string]",
|
||||
description="List pending merges from Debian matching string",
|
||||
)
|
||||
parser.add_argument("string", nargs="?", help=argparse.SUPPRESS)
|
||||
args = parser.parse_args()
|
||||
|
||||
ubuntutools.misc.require_utf8()
|
||||
|
||||
for component in (
|
||||
"main",
|
||||
"main-manual",
|
||||
"restricted",
|
||||
"restricted-manual",
|
||||
"universe",
|
||||
"universe-manual",
|
||||
"multiverse",
|
||||
"multiverse-manual",
|
||||
):
|
||||
url = f"https://merges.ubuntu.com/{component}.json"
|
||||
try:
|
||||
headers, page = Http().request(url)
|
||||
except HttpLib2Error as e:
|
||||
Logger.exception(e)
|
||||
sys.exit(1)
|
||||
if headers.status != 200:
|
||||
Logger.error("%s: %s %s", url, headers.status, headers.reason)
|
||||
sys.exit(1)
|
||||
|
||||
for merge in json.loads(page):
|
||||
package = merge["source_package"]
|
||||
author, uploader = "", ""
|
||||
if merge.get("user"):
|
||||
author = merge["user"]
|
||||
if merge.get("uploader"):
|
||||
uploader = f"({merge['uploader']})"
|
||||
teams = merge.get("teams", [])
|
||||
|
||||
pretty_uploader = f"{author} {uploader}"
|
||||
if (
|
||||
args.string is None
|
||||
or args.string in package
|
||||
or args.string in author
|
||||
or args.string in uploader
|
||||
or args.string in teams
|
||||
):
|
||||
Logger.info("%s\t%s", package, pretty_uploader)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
86
hugdaylist
Executable file
86
hugdaylist
Executable file
@ -0,0 +1,86 @@
|
||||
#!/usr/bin/python
|
||||
# -*- coding: utf-8 -*-
|
||||
#
|
||||
# Copyright 2007, Canonical, Daniel Holbach
|
||||
#
|
||||
# GPL 3
|
||||
#
|
||||
# hugdaylist <url>
|
||||
# - produces lists like https://wiki.ubuntu.com/UbuntuBugDay/20070912?action=raw
|
||||
#
|
||||
# hugdaylist -n <howmany> <url>
|
||||
# - will only list <howmany> URLs
|
||||
#
|
||||
|
||||
import re
|
||||
import os
|
||||
import sys
|
||||
import string
|
||||
|
||||
try:
|
||||
import launchpadbugs.connector as Connector
|
||||
BugList = Connector.ConnectBugList()
|
||||
Bug = Connector.ConnectBug(method="Text")
|
||||
except:
|
||||
print >> sys.stderr, \
|
||||
"You need python-launchpad-bugs (>= 0.2.25) installed to use hugdaylist."
|
||||
sys.exit(1)
|
||||
|
||||
|
||||
USAGE = "hugdaylist [-n <howmany>] <URL>"
|
||||
|
||||
def check_args():
|
||||
howmany = -1
|
||||
url = ""
|
||||
|
||||
if len(sys.argv) < 2:
|
||||
print >> sys.stderr, USAGE
|
||||
sys.exit(1)
|
||||
|
||||
if sys.argv[1] == "-n":
|
||||
howmany = int(sys.argv[2])
|
||||
if len(sys.argv) < 4:
|
||||
print USAGE
|
||||
sys.exit(1)
|
||||
url = sys.argv[3]
|
||||
else:
|
||||
url = sys.argv[1]
|
||||
|
||||
return (howmany, url)
|
||||
|
||||
def filter_unsolved(b):
|
||||
bug = Bug(int(b))
|
||||
return filter(lambda a: a.status != 'Fix Committed' and \
|
||||
(a.assignee in ['motu','desktop-bugs'] or \
|
||||
not a.assignee), bug.infotable) and \
|
||||
'ubuntu-main-sponsors' not in [str(s) for s in bug.subscribers] and \
|
||||
'ubuntu-universe-sponsors' not in [str(s) for s in bug.subscribers]
|
||||
|
||||
def main():
|
||||
(howmany, url) = check_args()
|
||||
|
||||
bl = BugList(url)
|
||||
l = filter(filter_unsolved, bl)
|
||||
|
||||
if not l:
|
||||
print "BugList of %s is empty." % url
|
||||
sys.exit(0)
|
||||
if howmany == -1:
|
||||
howmany = len(l)
|
||||
|
||||
print """
|
||||
## ||<rowbgcolor="#CCFFCC"> This task is done || somebody || ||
|
||||
## ||<rowbgcolor="#FFFFCC"> This task is assigned || somebody || <status> ||
|
||||
## ||<rowbgcolor="#FFEBBB"> This task isn't || ... || ||
|
||||
## ||<rowbgcolor="#FFCCCC"> This task is blocked on something || somebody || <explanation> ||
|
||||
|
||||
|| Bug || Subject || Triager ||"""
|
||||
|
||||
for i in list(l)[:howmany]:
|
||||
print '||<rowbgcolor="#FFEBBB"> [%s %s] || %s || ||' % \
|
||||
(i.url, i.bugnumber, i.summary)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
|
@ -1,256 +0,0 @@
|
||||
#!/usr/bin/python3
|
||||
|
||||
# Copyright © 2009 James Westby <james.westby@ubuntu.com>,
|
||||
# 2010, 2011 Stefano Rivera <stefanor@ubuntu.com>
|
||||
#
|
||||
# ##################################################################
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License along
|
||||
# with this program; if not, write to the Free Software Foundation, Inc.,
|
||||
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
#
|
||||
# ##################################################################
|
||||
|
||||
# pylint: disable=invalid-name
|
||||
# pylint: enable=invalid-name
|
||||
|
||||
import argparse
|
||||
import logging
|
||||
import re
|
||||
import sys
|
||||
import webbrowser
|
||||
from collections.abc import Iterable
|
||||
from email.message import EmailMessage
|
||||
|
||||
import debianbts
|
||||
from launchpadlib.launchpad import Launchpad
|
||||
|
||||
from ubuntutools import getLogger
|
||||
from ubuntutools.config import UDTConfig
|
||||
|
||||
Logger = getLogger()
|
||||
ATTACHMENT_MAX_SIZE = 2000
|
||||
|
||||
|
||||
def parse_args() -> argparse.Namespace:
|
||||
parser = argparse.ArgumentParser()
|
||||
parser.add_argument(
|
||||
"-b",
|
||||
"--browserless",
|
||||
action="store_true",
|
||||
help="Don't open the bug in the browser at the end",
|
||||
)
|
||||
parser.add_argument(
|
||||
"-l",
|
||||
"--lpinstance",
|
||||
metavar="INSTANCE",
|
||||
help="LP instance to connect to (default: production)",
|
||||
)
|
||||
parser.add_argument(
|
||||
"-v", "--verbose", action="store_true", help="Print info about the bug being imported"
|
||||
)
|
||||
parser.add_argument(
|
||||
"-n",
|
||||
"--dry-run",
|
||||
action="store_true",
|
||||
help="Don't actually open a bug (also sets verbose)",
|
||||
)
|
||||
parser.add_argument(
|
||||
"-p", "--package", help="Launchpad package to file bug against (default: Same as Debian)"
|
||||
)
|
||||
parser.add_argument(
|
||||
"--no-conf", action="store_true", help="Don't read config files or environment variables."
|
||||
)
|
||||
parser.add_argument("bugs", nargs="+", help="Bug number(s) or URL(s)")
|
||||
return parser.parse_args()
|
||||
|
||||
|
||||
def get_bug_numbers(bug_list: Iterable[str]) -> list[int]:
|
||||
bug_re = re.compile(r"bug=(\d+)")
|
||||
|
||||
bug_nums = []
|
||||
|
||||
for bug_num in bug_list:
|
||||
if bug_num.startswith("http"):
|
||||
# bug URL
|
||||
match = bug_re.search(bug_num)
|
||||
if match is None:
|
||||
Logger.error("Can't determine bug number from %s", bug_num)
|
||||
sys.exit(1)
|
||||
bug_num = match.groups()[0]
|
||||
bug_num = bug_num.lstrip("#")
|
||||
bug_nums.append(int(bug_num))
|
||||
|
||||
return bug_nums
|
||||
|
||||
|
||||
def walk_multipart_message(message: EmailMessage) -> tuple[str, list[tuple[int, EmailMessage]]]:
|
||||
summary = ""
|
||||
attachments = []
|
||||
i = 1
|
||||
for part in message.walk():
|
||||
content_type = part.get_content_type()
|
||||
|
||||
if content_type.startswith("multipart/"):
|
||||
# we're already iterating on multipart items
|
||||
# let's just skip the multipart extra metadata
|
||||
continue
|
||||
if content_type == "application/pgp-signature":
|
||||
# we're not interested in importing pgp signatures
|
||||
continue
|
||||
|
||||
if part.is_attachment():
|
||||
attachments.append((i, part))
|
||||
elif content_type.startswith("image/"):
|
||||
# images here are not attachment, they are inline, but Launchpad can't handle that,
|
||||
# so let's add them as attachments
|
||||
summary += f"Message part #{i}\n"
|
||||
summary += f"[inline image '{part.get_filename()}']\n\n"
|
||||
attachments.append((i, part))
|
||||
elif content_type.startswith("text/html"):
|
||||
summary += f"Message part #{i}\n"
|
||||
summary += "[inline html]\n\n"
|
||||
attachments.append((i, part))
|
||||
elif content_type == "text/plain":
|
||||
summary += f"Message part #{i}\n"
|
||||
summary += part.get_content() + "\n"
|
||||
else:
|
||||
raise RuntimeError(
|
||||
f"""Unknown message part
|
||||
Your Debian bug is too weird to be imported in Launchpad, sorry.
|
||||
You can fix that by patching this script in ubuntu-dev-tools.
|
||||
Faulty message part:
|
||||
{part}"""
|
||||
)
|
||||
i += 1
|
||||
|
||||
return summary, attachments
|
||||
|
||||
|
||||
def process_bugs(
|
||||
bugs: Iterable[debianbts.Bugreport],
|
||||
launchpad: Launchpad,
|
||||
package: str,
|
||||
dry_run: bool = True,
|
||||
browserless: bool = False,
|
||||
) -> bool:
|
||||
debian = launchpad.distributions["debian"]
|
||||
ubuntu = launchpad.distributions["ubuntu"]
|
||||
lp_debbugs = launchpad.bug_trackers.getByName(name="debbugs")
|
||||
|
||||
err = False
|
||||
for bug in bugs:
|
||||
ubupackage = bug.source
|
||||
if package:
|
||||
ubupackage = package
|
||||
bug_num = bug.bug_num
|
||||
subject = bug.subject
|
||||
log = debianbts.get_bug_log(bug_num)
|
||||
message = log[0]["message"]
|
||||
assert isinstance(message, EmailMessage)
|
||||
attachments: list[tuple[int, EmailMessage]] = []
|
||||
if message.is_multipart():
|
||||
summary, attachments = walk_multipart_message(message)
|
||||
else:
|
||||
summary = str(message.get_payload())
|
||||
|
||||
target = ubuntu.getSourcePackage(name=ubupackage)
|
||||
if target is None:
|
||||
Logger.error(
|
||||
"Source package '%s' is not in Ubuntu. Please specify "
|
||||
"the destination source package with --package",
|
||||
ubupackage,
|
||||
)
|
||||
err = True
|
||||
continue
|
||||
|
||||
description = f"Imported from Debian bug http://bugs.debian.org/{bug_num}:\n\n{summary}"
|
||||
# LP limits descriptions to 50K chars
|
||||
description = (description[:49994] + " [...]") if len(description) > 50000 else description
|
||||
|
||||
Logger.debug("Target: %s", target)
|
||||
Logger.debug("Subject: %s", subject)
|
||||
Logger.debug("Description: ")
|
||||
Logger.debug(description)
|
||||
for i, attachment in attachments:
|
||||
Logger.debug("Attachment #%s (%s)", i, attachment.get_filename() or "inline")
|
||||
Logger.debug("Content:")
|
||||
if attachment.get_content_type() == "text/plain":
|
||||
content = attachment.get_content()
|
||||
if len(content) > ATTACHMENT_MAX_SIZE:
|
||||
content = (
|
||||
content[:ATTACHMENT_MAX_SIZE]
|
||||
+ f" [attachment cropped after {ATTACHMENT_MAX_SIZE} characters...]"
|
||||
)
|
||||
Logger.debug(content)
|
||||
else:
|
||||
Logger.debug("[data]")
|
||||
|
||||
if dry_run:
|
||||
Logger.info("Dry-Run: not creating Ubuntu bug.")
|
||||
continue
|
||||
|
||||
u_bug = launchpad.bugs.createBug(target=target, title=subject, description=description)
|
||||
for i, attachment in attachments:
|
||||
name = f"#{i}-{attachment.get_filename() or "inline"}"
|
||||
content = attachment.get_content()
|
||||
if isinstance(content, str):
|
||||
# Launchpad only wants bytes
|
||||
content = content.encode()
|
||||
u_bug.addAttachment(
|
||||
filename=name,
|
||||
data=content,
|
||||
comment=f"Imported from Debian bug http://bugs.debian.org/{bug_num}",
|
||||
)
|
||||
d_sp = debian.getSourcePackage(name=package)
|
||||
if d_sp is None and package:
|
||||
d_sp = debian.getSourcePackage(name=package)
|
||||
d_task = u_bug.addTask(target=d_sp)
|
||||
d_watch = u_bug.addWatch(remote_bug=bug_num, bug_tracker=lp_debbugs)
|
||||
d_task.bug_watch = d_watch
|
||||
d_task.lp_save()
|
||||
Logger.info("Opened %s", u_bug.web_link)
|
||||
if not browserless:
|
||||
webbrowser.open(u_bug.web_link)
|
||||
|
||||
return err
|
||||
|
||||
|
||||
def main() -> None:
|
||||
options = parse_args()
|
||||
|
||||
config = UDTConfig(options.no_conf)
|
||||
if options.lpinstance is None:
|
||||
options.lpinstance = config.get_value("LPINSTANCE")
|
||||
|
||||
if options.dry_run:
|
||||
launchpad = Launchpad.login_anonymously("ubuntu-dev-tools")
|
||||
options.verbose = True
|
||||
else:
|
||||
launchpad = Launchpad.login_with("ubuntu-dev-tools", options.lpinstance)
|
||||
|
||||
if options.verbose:
|
||||
Logger.setLevel(logging.DEBUG)
|
||||
|
||||
bugs = debianbts.get_status(get_bug_numbers(options.bugs))
|
||||
|
||||
if not bugs:
|
||||
Logger.error("Cannot find any of the listed bugs")
|
||||
sys.exit(1)
|
||||
|
||||
if process_bugs(bugs, launchpad, options.package, options.dry_run, options.browserless):
|
||||
sys.exit(1)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
105
lp-bitesize
105
lp-bitesize
@ -1,105 +0,0 @@
|
||||
#!/usr/bin/python3
|
||||
"""Add 'bitesize' tag to bugs and add a comment."""
|
||||
|
||||
# Copyright (c) 2011 Canonical Ltd.
|
||||
#
|
||||
# bitesize is free software; you can redistribute it and/or modify it
|
||||
# under the terms of the GNU General Public License as published by the
|
||||
# Free Software Foundation; either version 3, or (at your option) any
|
||||
# later version.
|
||||
#
|
||||
# bitesize is distributed in the hope that it will be useful, but
|
||||
# WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
# General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with bitesize; see the file COPYING. If not, write to the Free
|
||||
# Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
|
||||
# 02110-1301, USA.
|
||||
#
|
||||
# Authors:
|
||||
# Daniel Holbach <daniel.holbach@canonical.com>
|
||||
|
||||
import argparse
|
||||
import sys
|
||||
|
||||
from launchpadlib.errors import HTTPError
|
||||
from launchpadlib.launchpad import Launchpad
|
||||
|
||||
from ubuntutools import getLogger
|
||||
from ubuntutools.config import UDTConfig
|
||||
|
||||
Logger = getLogger()
|
||||
|
||||
|
||||
def error_out(msg, *args):
|
||||
Logger.error(msg, *args)
|
||||
sys.exit(1)
|
||||
|
||||
|
||||
def save_entry(entry):
|
||||
try:
|
||||
entry.lp_save()
|
||||
except HTTPError as error:
|
||||
error_out("%s", error.content)
|
||||
|
||||
|
||||
def tag_bug(bug):
|
||||
bug.tags = bug.tags + ["bitesize"] # LP: #254901 workaround
|
||||
save_entry(bug)
|
||||
|
||||
|
||||
def main():
|
||||
parser = argparse.ArgumentParser(usage="%(prog)s [options] <bug number>")
|
||||
parser.add_argument(
|
||||
"-l",
|
||||
"--lpinstance",
|
||||
metavar="INSTANCE",
|
||||
help="Launchpad instance to connect to (default: production)",
|
||||
dest="lpinstance",
|
||||
default=None,
|
||||
)
|
||||
parser.add_argument(
|
||||
"--no-conf",
|
||||
help="Don't read config files or environment variables.",
|
||||
dest="no_conf",
|
||||
default=False,
|
||||
action="store_true",
|
||||
)
|
||||
parser.add_argument("bug_number", help=argparse.SUPPRESS)
|
||||
args = parser.parse_args()
|
||||
config = UDTConfig(args.no_conf)
|
||||
if args.lpinstance is None:
|
||||
args.lpinstance = config.get_value("LPINSTANCE")
|
||||
|
||||
launchpad = Launchpad.login_with("ubuntu-dev-tools", args.lpinstance)
|
||||
if launchpad is None:
|
||||
error_out("Couldn't authenticate to Launchpad.")
|
||||
|
||||
# check that the new main bug isn't a duplicate
|
||||
try:
|
||||
bug = launchpad.bugs[args.bug_number]
|
||||
except HTTPError as error:
|
||||
if error.response.status == 401:
|
||||
error_out(
|
||||
"Don't have enough permissions to access bug %s. %s",
|
||||
args.bug_number,
|
||||
error.content,
|
||||
)
|
||||
else:
|
||||
raise
|
||||
if "bitesize" in bug.tags:
|
||||
error_out("Bug is already marked as 'bitesize'.")
|
||||
bug.newMessage(
|
||||
content="I'm marking this bug as 'bitesize' as it looks "
|
||||
"like an issue that is easy to fix and suitable "
|
||||
"for newcomers in Ubuntu development. If you need "
|
||||
"any help with fixing it, talk to me about it."
|
||||
)
|
||||
bug.subscribe(person=launchpad.me)
|
||||
tag_bug(launchpad.bugs[bug.id]) # fresh bug object, LP: #336866 workaround
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
125
massfile
Executable file
125
massfile
Executable file
@ -0,0 +1,125 @@
|
||||
#!/usr/bin/python
|
||||
# -*- coding: utf-8 -*-
|
||||
#
|
||||
# (C) Canonical, 2007, GPL v3
|
||||
|
||||
import os
|
||||
import sys
|
||||
import email
|
||||
import subprocess
|
||||
|
||||
import launchpadbugs.connector as Connector
|
||||
|
||||
|
||||
def read_config():
|
||||
instructions_file = open("instructions")
|
||||
instructions = email.message_from_file(instructions_file)
|
||||
instructions_file.close()
|
||||
instr = dict()
|
||||
|
||||
for field in "subject", "assignee", "subscribers", "tags", "text", \
|
||||
"buglist-url":
|
||||
instr[field] = instructions.get(field)
|
||||
|
||||
return instr
|
||||
|
||||
def read_list():
|
||||
pack_list = set()
|
||||
|
||||
listfile = open("list")
|
||||
for line in listfile.readlines():
|
||||
if line.strip()!="":
|
||||
pack_list.add(line.strip("\n"))
|
||||
|
||||
listfile.close()
|
||||
return pack_list
|
||||
|
||||
def file_bug():
|
||||
Bug = Connector.ConnectBug()
|
||||
Bug.authentication = os.path.expanduser("~/.lpcookie")
|
||||
|
||||
|
||||
def check_configfiles():
|
||||
result = True
|
||||
|
||||
bin_path = os.path.dirname(os.path.abspath(__file__))
|
||||
if bin_path == "/usr/bin":
|
||||
example_dir = "/usr/share/doc/ubuntu-dev-tools/examples"
|
||||
else:
|
||||
example_dir = "%s/examples" % bin_path
|
||||
|
||||
if not os.path.exists("instructions"):
|
||||
os.system("cp %s/massfile.instructions instructions" % example_dir)
|
||||
print >> sys.stderr, \
|
||||
"No 'instructions' file found. Copied template from %s." % \
|
||||
example_dir
|
||||
result = False
|
||||
|
||||
if not os.path.exists("list"):
|
||||
os.system("cp %s/massfile.list list" % example_dir)
|
||||
print >> sys.stderr, \
|
||||
"No 'list' file found. Copied template from %s." % example_dir
|
||||
result = False
|
||||
|
||||
return result
|
||||
|
||||
|
||||
def file_bug(config):
|
||||
Bug = Connector.ConnectBug()
|
||||
Bug.authentication = os.path.expanduser("~/.lpcookie")
|
||||
|
||||
try:
|
||||
summary = config["subject"].replace("$pack", config["sourcepackage"])
|
||||
description = config["text"].replace("$pack", config["sourcepackage"])
|
||||
|
||||
bug = Bug.New(product={"name": config["sourcepackage"],
|
||||
"target": "ubuntu"},
|
||||
summary=summary,
|
||||
description=description)
|
||||
print "Successfully filed bug %s: http://launchpad.net/bugs/%s" % \
|
||||
(bug.bugnumber, bug.bugnumber)
|
||||
for sub in config["subscribers"].split(","):
|
||||
if sub.strip("\n").strip():
|
||||
bug.subscribers.add(sub.strip("\n").strip())
|
||||
for tag in config["tags"].split(","):
|
||||
if tag.strip("\n").strip():
|
||||
bug.tags.append(tag.strip("\n").strip())
|
||||
bug.assignee = config["assignee"]
|
||||
bug.commit()
|
||||
except:
|
||||
"Bug for '%s' was not filed." % config["sourcepackage"]
|
||||
|
||||
def read_buglist(url):
|
||||
BugList = Connector.ConnectBugList()
|
||||
packages = set()
|
||||
|
||||
if url:
|
||||
buglist = BugList(url)
|
||||
for bug in buglist.bugs:
|
||||
packages.add(bug.sourcepackage)
|
||||
|
||||
return packages
|
||||
|
||||
|
||||
def main():
|
||||
if not check_configfiles():
|
||||
sys.exit(1)
|
||||
|
||||
if not os.path.exists(os.path.expanduser("~/.lpcookie")):
|
||||
print >> sys.stderr, \
|
||||
"Launchpad cookie not found in ~/.lpcookie."
|
||||
sys.exit(1)
|
||||
|
||||
config = read_config()
|
||||
pack_list = read_list()
|
||||
buglist = read_buglist(config["buglist-url"])
|
||||
|
||||
for pack in pack_list:
|
||||
if pack not in buglist:
|
||||
config["sourcepackage"] = pack
|
||||
file_bug(config)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
|
@ -1,94 +0,0 @@
|
||||
#!/usr/bin/python3
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright © 2008 Canonical Ltd.
|
||||
# Author: Scott James Remnant <scott at ubuntu.com>.
|
||||
# Hacked up by: Bryce Harrington <bryce at ubuntu.com>
|
||||
# Change merge_changelog to merge-changelog: Ryan Kavanagh
|
||||
# <ryanakca@kubuntu.org>
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of version 3 of the GNU General Public License as
|
||||
# published by the Free Software Foundation.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
# pylint: disable=invalid-name
|
||||
# pylint: enable=invalid-name
|
||||
|
||||
import sys
|
||||
|
||||
from debian.changelog import Changelog
|
||||
|
||||
from ubuntutools import getLogger
|
||||
|
||||
Logger = getLogger()
|
||||
|
||||
|
||||
def usage(exit_code=1):
|
||||
Logger.info(
|
||||
"""Usage: merge-changelog <left changelog> <right changelog>
|
||||
|
||||
merge-changelog takes two changelogs that once shared a common source,
|
||||
merges them back together, and prints the merged result to stdout. This
|
||||
is useful if you need to manually merge a ubuntu package with a new
|
||||
Debian release of the package.
|
||||
"""
|
||||
)
|
||||
sys.exit(exit_code)
|
||||
|
||||
|
||||
########################################################################
|
||||
# Changelog Management
|
||||
########################################################################
|
||||
|
||||
|
||||
def merge_changelog(left_changelog, right_changelog):
|
||||
"""Merge a changelog file."""
|
||||
|
||||
with open(left_changelog, encoding="utf-8") as f:
|
||||
left_cl = Changelog(f)
|
||||
with open(right_changelog, encoding="utf-8") as f:
|
||||
right_cl = Changelog(f)
|
||||
|
||||
left_versions = set(left_cl.versions)
|
||||
right_versions = set(right_cl.versions)
|
||||
left_blocks = iter(left_cl)
|
||||
right_blocks = iter(right_cl)
|
||||
|
||||
clist = sorted(left_versions | right_versions, reverse=True)
|
||||
remaining = len(clist)
|
||||
for version in clist:
|
||||
remaining -= 1
|
||||
if version in left_versions:
|
||||
block = next(left_blocks)
|
||||
if version in right_versions:
|
||||
next(right_blocks)
|
||||
else:
|
||||
block = next(right_blocks)
|
||||
|
||||
assert block.version == version
|
||||
|
||||
Logger.info("%s%s", str(block).strip(), "\n" if remaining else "")
|
||||
|
||||
|
||||
def main():
|
||||
if len(sys.argv) > 1 and sys.argv[1] in ("-h", "--help"):
|
||||
usage(0)
|
||||
if len(sys.argv) != 3:
|
||||
usage(1)
|
||||
|
||||
left_changelog = sys.argv[1]
|
||||
right_changelog = sys.argv[2]
|
||||
|
||||
merge_changelog(left_changelog, right_changelog)
|
||||
sys.exit(0)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
286
mk-sbuild-lv
Executable file
286
mk-sbuild-lv
Executable file
@ -0,0 +1,286 @@
|
||||
#!/bin/bash
|
||||
# Copyright 2006-2007 (C) Canonical Ltd.
|
||||
# Created by Kees Cook <kees@ubuntu.com>
|
||||
# License: GPLv2
|
||||
#
|
||||
# This script creates LVM snapshot chroots via schroot and sbuild.
|
||||
# Much love to "man sbuild-setup", https://wiki.ubuntu.com/PbuilderHowto,
|
||||
# and https://help.ubuntu.com/community/SbuildLVMHowto.
|
||||
#
|
||||
# It assumes that sbuild has not be installed and configured before.
|
||||
#
|
||||
# If using schroot earlier than 1.1.4-1, it's a good idea to apply the
|
||||
# process-cleaning patch to /etc/schroot/setup.d/10mount. Without this, any
|
||||
# processes left running from the build (like cron, dbus, etc) will stop
|
||||
# schroot from umounting and shutting down cleanly:
|
||||
# http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=391319
|
||||
#
|
||||
# If using sbuild 0.50 or earlier, and you intend to use the "arch" argument
|
||||
# to do i386 builds on amd64, you will need to patch "sbuild" to correctly
|
||||
# detect the chroot architecture:
|
||||
# http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=392992
|
||||
#
|
||||
# Version: 0.12
|
||||
|
||||
set -e
|
||||
|
||||
# Make sure we've got a regular user
|
||||
if [ -w /etc/passwd ]; then
|
||||
echo "Please run this script as a regular user, not root." >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Perform once-only things to initially set up for using sbuild+schroot+lvm
|
||||
if [ ! -w /var/lib/sbuild ]; then
|
||||
# Load all the packages you'll need to do work
|
||||
sudo apt-get install sbuild schroot debootstrap lvm2
|
||||
# Make sure LVM tools that operate on the snapshots have needed module
|
||||
sudo modprobe dm_snapshot
|
||||
sudo bash -c "grep ^dm_snapshot /etc/modules >/dev/null || echo dm_snapshot >> /etc/modules"
|
||||
# Add self to the sbuild group
|
||||
sudo adduser "$USER" sbuild
|
||||
|
||||
# Create some default build/log areas
|
||||
mkdir -p ~/ubuntu/build ~/ubuntu/logs
|
||||
# Prepare a usable default .sbuildrc
|
||||
if [ ! -e ~/.sbuildrc ]; then
|
||||
cat > ~/.sbuildrc <<EOM
|
||||
# *** VERIFY AND UPDATE \$mailto and \$maintainer_name BELOW ***
|
||||
|
||||
# Mail address where logs are sent to (mandatory, no default!)
|
||||
\$mailto = '$USER';
|
||||
|
||||
# Name to use as override in .changes files for the Maintainer: field
|
||||
# (mandatory, no default!).
|
||||
\$maintainer_name='$USER <$USER@localhost>';
|
||||
|
||||
# Directory for chroot symlinks and sbuild logs. Defaults to the
|
||||
# current directory if unspecified.
|
||||
#\$build_dir='$HOME/ubuntu/build';
|
||||
|
||||
# Directory for writing build logs to
|
||||
\$log_dir="$HOME/ubuntu/logs";
|
||||
|
||||
# don't remove this, Perl needs it:
|
||||
1;
|
||||
EOM
|
||||
sensible-editor ~/.sbuildrc
|
||||
else
|
||||
echo "Your ~/.sbuildrc already exists -- leaving it as-is."
|
||||
fi
|
||||
|
||||
echo '***********************************************'
|
||||
echo '* Before continuing, you MUST restart your *'
|
||||
echo '* session to gain "sbuild" group permissions! *'
|
||||
echo '***********************************************'
|
||||
exit 0
|
||||
fi
|
||||
|
||||
if ! id | fgrep -q '(sbuild)'; then
|
||||
echo "You must be a member of the 'sbuild' group." >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
function usage()
|
||||
{
|
||||
echo "Usage: $0 [OPTIONS] VG Release" >&2
|
||||
echo "Options:"
|
||||
echo " --arch=ARCH What architecture to select"
|
||||
echo " --name=NAME Base name for the schroot (arch is appended)"
|
||||
echo " --personality=PERSONALITY What personality to use (defaults to match --arch)"
|
||||
echo " --debug Turn on script debugging"
|
||||
echo " --source-template=FILE Use FILE as the sources.list template"
|
||||
echo " --debootstrap-mirror=URL Use URL as the debootstrap source"
|
||||
exit 1
|
||||
}
|
||||
|
||||
|
||||
if [ -z "$1" ]; then
|
||||
usage
|
||||
fi
|
||||
OPTS=`getopt -o '' --long "help,debug,arch:,name:,source-template:,debootstrap-mirror:,personality:" -- "$@"`
|
||||
eval set -- "$OPTS"
|
||||
|
||||
name=""
|
||||
while :; do
|
||||
case "$1" in
|
||||
--debug)
|
||||
set -x
|
||||
shift
|
||||
;;
|
||||
--arch)
|
||||
# By default, use the native architecture.
|
||||
arch_opt="--arch $2"
|
||||
arch_suffix="-$2"
|
||||
if [ -z "$personality" -a "$2" = "i386" ]
|
||||
then
|
||||
personality="linux32"
|
||||
fi
|
||||
shift 2
|
||||
;;
|
||||
--personality)
|
||||
personality="$2"
|
||||
shift 2
|
||||
;;
|
||||
--name)
|
||||
name="$2"
|
||||
shift 2
|
||||
;;
|
||||
--source-template)
|
||||
TEMPLATE_SOURCES="$2"
|
||||
shift 2
|
||||
if [ ! -r $TEMPLATE_SOURCES ]; then
|
||||
echo "W: Template file $TEMPLATE_SOURCES is not readable"
|
||||
echo "W: Continuing with default sources!"
|
||||
fi
|
||||
;;
|
||||
--debootstrap-mirror)
|
||||
DEBOOTSTRAP_MIRROR="$2"
|
||||
shift 2
|
||||
;;
|
||||
--)
|
||||
shift
|
||||
break
|
||||
;;
|
||||
--help|*)
|
||||
usage
|
||||
;;
|
||||
esac
|
||||
done
|
||||
|
||||
# To build the LV, we need to know which volume group to use, and which
|
||||
# release of Ubuntu to debootstrap
|
||||
VG="$1"
|
||||
RELEASE="$2"
|
||||
if [ -z "$VG" ] || [ -z "$RELEASE" ]; then
|
||||
usage
|
||||
fi
|
||||
|
||||
# By default, name the schroot the same as the release
|
||||
if [ -z "$name" ]; then
|
||||
name="$RELEASE"
|
||||
fi
|
||||
|
||||
# Set up some variables for use in the paths and names
|
||||
CHROOT_LV="${name}_chroot${arch_suffix}"
|
||||
CHROOT_PATH="/dev/$VG/$CHROOT_LV"
|
||||
CHROOT_NAME="${name}${arch_suffix}"
|
||||
|
||||
# Does the specified VG exist? (vgdisplay doesn't set error codes...)
|
||||
if [ `sudo vgdisplay -c "$VG" | wc -l` -eq 0 ]; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Is the specified release known to debootstrap?
|
||||
if [ ! -r "/usr/share/debootstrap/scripts/$RELEASE" ]; then
|
||||
echo "Specified release not known to debootstrap" >&2
|
||||
exit 1
|
||||
else
|
||||
variant_opt="--variant=buildd"
|
||||
fi
|
||||
|
||||
# Allocate the "golden" chroot LV
|
||||
sudo lvcreate -n "$CHROOT_LV" -L 5G "$VG"
|
||||
sudo mkfs -t ext3 "$CHROOT_PATH"
|
||||
|
||||
# Mount and debootstrap the chroot
|
||||
MNT=`mktemp -d -t schroot-XXXXXX`
|
||||
sudo mount "$CHROOT_PATH" "$MNT"
|
||||
sudo debootstrap $arch_opt $variant_opt "$RELEASE" "$MNT" "${DEBOOTSTRAP_MIRROR:-http://archive.ubuntu.com/ubuntu}"
|
||||
# Update the package sources
|
||||
TEMP_SOURCES=`mktemp -t sources-XXXXXX`
|
||||
if [ -z "$TEMPLATE_SOURCES" ]; then
|
||||
TEMPLATE_SOURCES=~/.mk-sbuild-lv.sources
|
||||
fi
|
||||
if [ -r "$TEMPLATE_SOURCES" ]; then
|
||||
cat "$TEMPLATE_SOURCES" > "$TEMP_SOURCES"
|
||||
else
|
||||
cat > "$TEMP_SOURCES" <<EOM
|
||||
deb http://archive.ubuntu.com/ubuntu RELEASE main restricted universe multiverse
|
||||
deb-src http://archive.ubuntu.com/ubuntu RELEASE main restricted universe multiverse
|
||||
deb http://archive.ubuntu.com/ubuntu RELEASE-updates main restricted universe multiverse
|
||||
deb-src http://archive.ubuntu.com/ubuntu RELEASE-updates main restricted universe multiverse
|
||||
deb http://security.ubuntu.com/ubuntu RELEASE-security main restricted universe multiverse
|
||||
deb-src http://security.ubuntu.com/ubuntu RELEASE-security main restricted universe multiverse
|
||||
EOM
|
||||
fi
|
||||
cat "$TEMP_SOURCES" | sed -e "s|RELEASE|$RELEASE|g" | \
|
||||
sudo bash -c "cat > $MNT/etc/apt/sources.list"
|
||||
rm -f "$TEMP_SOURCES"
|
||||
# Copy the timezone (comment this out if you want to leave the chroot at UTC)
|
||||
sudo cp /etc/localtime /etc/timezone "$MNT"/etc/
|
||||
# Create an LVM-snapshot-based schroot entry for this LV
|
||||
TEMP_SCHROOTCONF=`mktemp -t schrootconf-XXXXXX`
|
||||
TEMPLATE_SCHROOTCONF=~/.mk-sbuild-lv.schroot.conf
|
||||
if [ -r "$TEMPLATE_SCHROOTCONF" ]; then
|
||||
cat "$TEMPLATE_SCHROOTCONF" > "$TEMP_SCHROOTCONF"
|
||||
else
|
||||
cat > "$TEMP_SCHROOTCONF" <<EOM
|
||||
|
||||
[CHROOT_NAME]
|
||||
type=lvm-snapshot
|
||||
description=CHROOT_NAME
|
||||
priority=3
|
||||
groups=sbuild,root,admin
|
||||
root-groups=root,sbuild,admin
|
||||
source-groups=sbuild,root,admin
|
||||
source-root-groups=root,sbuild,admin
|
||||
device=CHROOT_PATH
|
||||
mount-options=-o noatime
|
||||
lvm-snapshot-options=--size 4G
|
||||
run-setup-scripts=true
|
||||
run-exec-scripts=true
|
||||
EOM
|
||||
fi
|
||||
if [ ! -z "$personality" ]; then
|
||||
echo "personality=$personality" >> "$TEMP_SCHROOTCONF"
|
||||
fi
|
||||
cat "$TEMP_SCHROOTCONF" | sed \
|
||||
-e "s|CHROOT_NAME|$CHROOT_NAME|g" \
|
||||
-e "s|CHROOT_PATH|$CHROOT_PATH|g" \
|
||||
| \
|
||||
sudo bash -c "cat >> /etc/schroot/schroot.conf"
|
||||
rm -f "$TEMP_SCHROOTCONF"
|
||||
# Create image finalization script
|
||||
BUILD_PKGS="build-essential fakeroot devscripts"
|
||||
# Add edgy+ buildd tools
|
||||
if [ "$RELEASE" != "breezy" ] && [ "$RELEASE" != "dapper" ]; then
|
||||
BUILD_PKGS="$BUILD_PKGS pkg-create-dbgsym pkgbinarymangler"
|
||||
fi
|
||||
sudo bash -c "cat >> $MNT/finish.sh" <<EOM
|
||||
#!/bin/bash
|
||||
#set -x
|
||||
set -e
|
||||
# Reload package lists
|
||||
apt-get update || true
|
||||
# Pull down signature requirements
|
||||
apt-get -y --force-yes install gnupg ubuntu-keyring
|
||||
# Reload package lists
|
||||
apt-get update || true
|
||||
# Disable debconf questions so that automated builds won't prompt
|
||||
echo set debconf/frontend Noninteractive | debconf-communicate
|
||||
echo set debconf/priority critical | debconf-communicate
|
||||
# Install basic build tool set, trying to match buildd
|
||||
apt-get -y install $BUILD_PKGS
|
||||
# Set up expected /dev entries
|
||||
if [ ! -r /dev/stdin ]; then ln -s /proc/self/fd/0 /dev/stdin; fi
|
||||
if [ ! -r /dev/stdout ]; then ln -s /proc/self/fd/1 /dev/stdout; fi
|
||||
if [ ! -r /dev/stderr ]; then ln -s /proc/self/fd/2 /dev/stderr; fi
|
||||
# Clean up
|
||||
apt-get clean
|
||||
rm /finish.sh
|
||||
EOM
|
||||
sudo chmod +x "$MNT"/finish.sh
|
||||
sudo umount "$MNT"
|
||||
rmdir "$MNT"
|
||||
# Run finalization script on the "golden" copy via schroot.
|
||||
(cd / && schroot -c "$CHROOT_NAME"-source -u root /finish.sh)
|
||||
|
||||
# Finished
|
||||
echo ""
|
||||
echo "Done building $CHROOT_NAME."
|
||||
echo ""
|
||||
echo " To UPDATE the golden image: schroot -c ${CHROOT_NAME}-source -u root"
|
||||
echo " To ENTER an image snapshot: schroot -c ${CHROOT_NAME}"
|
||||
echo " To BUILD within a snapshot: sbuild -d ${CHROOT_NAME} PACKAGE*.dsc"
|
||||
echo ""
|
583
pbuilder-dist
583
pbuilder-dist
@ -1,58 +1,25 @@
|
||||
#! /usr/bin/python3
|
||||
#! /usr/bin/env python
|
||||
# -*- coding: utf-8 -*-
|
||||
#
|
||||
# Copyright (C) 2007-2010, Siegfried-A. Gevatter <rainct@ubuntu.com>,
|
||||
# 2010-2011, Stefano Rivera <stefanor@ubuntu.com>
|
||||
# With some changes by Iain Lane <iain@orangesquash.org.uk>
|
||||
# Copyright (C) 2007-2008 Siegfried-A. Gevatter <rainct@ubuntu.com>
|
||||
# Based upon pbuilder-dist-simple by Jamin Collins and Jordan Mantha.
|
||||
#
|
||||
# ##################################################################
|
||||
# License: GPLv2 or later
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# See file /usr/share/common-licenses/GPL-2 for more details.
|
||||
#
|
||||
# ##################################################################
|
||||
#
|
||||
# This script is a wrapper to be able to easily use pbuilder/cowbuilder for
|
||||
# This script is a wrapper to be able to easily use pbuilder for
|
||||
# different distributions (eg, Gutsy, Hardy, Debian unstable, etc).
|
||||
#
|
||||
# You can create symlinks to a pbuilder-dist executable to get different
|
||||
# configurations. For example, a symlink called pbuilder-hardy will assume
|
||||
# that the target distribution is always meant to be Ubuntu Hardy.
|
||||
|
||||
# pylint: disable=invalid-name
|
||||
# pylint: enable=invalid-name
|
||||
|
||||
import os
|
||||
import os.path
|
||||
import shutil
|
||||
import subprocess
|
||||
import sys
|
||||
from contextlib import suppress
|
||||
import os
|
||||
|
||||
import debian.deb822
|
||||
from distro_info import DebianDistroInfo, DistroDataOutdated, UbuntuDistroInfo
|
||||
class pbuilder_dist:
|
||||
|
||||
import ubuntutools.misc
|
||||
import ubuntutools.version
|
||||
from ubuntutools import getLogger
|
||||
from ubuntutools.config import UDTConfig
|
||||
from ubuntutools.question import YesNoQuestion
|
||||
def __init__(self):
|
||||
|
||||
Logger = getLogger()
|
||||
|
||||
|
||||
class PbuilderDist:
|
||||
def __init__(self, builder):
|
||||
# Base directory where pbuilder will put all the files it creates.
|
||||
self.base = None
|
||||
|
||||
@ -64,12 +31,6 @@ class PbuilderDist:
|
||||
# and 'non-free' for Debian.
|
||||
self.extra_components = True
|
||||
|
||||
# Extra pockets, useful on stable releases
|
||||
self.enable_security = True
|
||||
self.enable_updates = True
|
||||
self.enable_proposed = True
|
||||
self.enable_backports = False
|
||||
|
||||
# File where the log of the last operation will be saved.
|
||||
self.logfile = None
|
||||
|
||||
@ -89,463 +50,269 @@ class PbuilderDist:
|
||||
# 'distribution' or 'distribution-architecture'.
|
||||
self.chroot_string = None
|
||||
|
||||
# Proxy
|
||||
self.proxy = None
|
||||
|
||||
# Authentication method
|
||||
self.auth = "sudo"
|
||||
|
||||
# Builder
|
||||
self.builder = builder
|
||||
|
||||
# Distro info
|
||||
self.debian_distro_info = DebianDistroInfo()
|
||||
self.ubuntu_distro_info = UbuntuDistroInfo()
|
||||
|
||||
self._debian_distros = self.debian_distro_info.all + ["stable", "testing", "unstable"]
|
||||
|
||||
# Ensure that the used builder is installed
|
||||
paths = set(os.environ["PATH"].split(":"))
|
||||
paths |= set(("/sbin", "/usr/sbin", "/usr/local/sbin"))
|
||||
if not any(os.path.exists(os.path.join(p, builder)) for p in paths):
|
||||
Logger.error('Could not find "%s".', builder)
|
||||
sys.exit(1)
|
||||
self.auth = 'sudo'
|
||||
|
||||
##############################################################
|
||||
|
||||
self.base = os.path.expanduser(os.environ.get("PBUILDFOLDER", "~/pbuilder/"))
|
||||
if 'PBUILDFOLDER' in os.environ:
|
||||
self.base = os.environ['PBUILDFOLDER']
|
||||
else:
|
||||
self.base = os.path.expanduser('~/pbuilder/')
|
||||
|
||||
if "SUDO_USER" in os.environ:
|
||||
Logger.warning(
|
||||
"Running under sudo. "
|
||||
"This is probably not what you want. "
|
||||
"pbuilder-dist will use sudo itself, "
|
||||
"when necessary."
|
||||
)
|
||||
if os.stat(os.environ["HOME"]).st_uid != os.getuid():
|
||||
Logger.error("You don't own $HOME")
|
||||
sys.exit(1)
|
||||
if 'PBUILDAUTH' in os.environ:
|
||||
self.auth = os.environ['PBUILDAUTH']
|
||||
|
||||
if not os.path.isdir(self.base):
|
||||
try:
|
||||
os.makedirs(self.base)
|
||||
except OSError:
|
||||
Logger.error('Cannot create base directory "%s"', self.base)
|
||||
sys.exit(1)
|
||||
self.system_architecture = host_architecture()
|
||||
|
||||
if "PBUILDAUTH" in os.environ:
|
||||
self.auth = os.environ["PBUILDAUTH"]
|
||||
if not self.system_architecture or 'not found' in self.system_architecture:
|
||||
print 'Error: Not running on a Debian based system; could not detect its architecture.'
|
||||
|
||||
self.system_architecture = ubuntutools.misc.host_architecture()
|
||||
self.system_distro = ubuntutools.misc.system_distribution()
|
||||
if not self.system_architecture or not self.system_distro:
|
||||
sys.exit(1)
|
||||
if not os.path.isfile('/etc/lsb-release'):
|
||||
print 'Error: Not running on a Debian based system; could not find /etc/lsb-release.'
|
||||
exit(1)
|
||||
|
||||
for line in open('/etc/lsb-release'):
|
||||
line = line.strip()
|
||||
if line.startswith('DISTRIB_CODENAME'):
|
||||
self.system_distro = line[17:]
|
||||
break
|
||||
|
||||
if not self.system_distro:
|
||||
print 'Error: Could not determine what distribution you are running.'
|
||||
exit(1)
|
||||
|
||||
self.target_distro = self.system_distro
|
||||
|
||||
if 'http_proxy' in os.environ:
|
||||
self.base = os.environ['http_proxy']
|
||||
elif 'HTTP_PROXY' in os.environ:
|
||||
self.base = os.environ['HTTP_PROXY']
|
||||
|
||||
##############################################################
|
||||
|
||||
def __getitem__(self, name):
|
||||
|
||||
return getattr(self, name)
|
||||
|
||||
def _calculate(self):
|
||||
""" pbuilder_dist.calculate(distro) -> None
|
||||
|
||||
Do all necessary variable changes (and therefore required checks)
|
||||
before the string that will be executed is generated. At this
|
||||
point it's expected that no more variables will be modified
|
||||
outside this class.
|
||||
|
||||
"""
|
||||
|
||||
if not self.build_architecture:
|
||||
self.chroot_string = self.target_distro
|
||||
self.build_architecture = self.system_architecture
|
||||
else:
|
||||
self.chroot_string = '%(target_distro)s-%(build_architecture)s' % self
|
||||
|
||||
if not self.logfile:
|
||||
self.logfile = '%(base)s/.%(chroot_string)s.log' % self
|
||||
|
||||
def set_target_distro(self, distro):
|
||||
"""PbuilderDist.set_target_distro(distro) -> None
|
||||
""" pbuilder_dist.set_target_distro(distro) -> None
|
||||
|
||||
Check if the given target distribution name is correct, if it
|
||||
isn't know to the system ask the user for confirmation before
|
||||
proceeding, and finally either save the value into the appropiate
|
||||
variable or finalize pbuilder-dist's execution.
|
||||
|
||||
"""
|
||||
|
||||
if not distro.isalpha():
|
||||
Logger.error('"%s" is an invalid distribution codename.', distro)
|
||||
print 'Error: «%s» is an invalid distribution codename.'
|
||||
sys.exit(1)
|
||||
|
||||
if not os.path.isfile(os.path.join("/usr/share/debootstrap/scripts/", distro)):
|
||||
if os.path.isdir("/usr/share/debootstrap/scripts/"):
|
||||
# Debian experimental doesn't have a debootstrap file but
|
||||
# should work nevertheless. Ubuntu releases automatically use
|
||||
# the gutsy script as of debootstrap 1.0.128+nmu2ubuntu1.1.
|
||||
if distro not in (self._debian_distros + self.ubuntu_distro_info.all):
|
||||
question = (
|
||||
f'Warning: Unknown distribution "{distro}". ' "Do you want to continue"
|
||||
)
|
||||
answer = YesNoQuestion().ask(question, "no")
|
||||
if answer == "no":
|
||||
if not os.path.isfile(os.path.join('/usr/share/debootstrap/scripts/', distro)):
|
||||
answer = ask('Warning: Unknown distribution «%s». Do you want to continue [y/N]? ' % distro)
|
||||
if answer not in ('y', 'Y'):
|
||||
sys.exit(0)
|
||||
else:
|
||||
Logger.error('Please install package "debootstrap".')
|
||||
sys.exit(1)
|
||||
|
||||
self.target_distro = distro
|
||||
|
||||
def set_operation(self, operation):
|
||||
"""PbuilderDist.set_operation -> None
|
||||
""" pbuilder_dist.set_operation -> None
|
||||
|
||||
Check if the given string is a valid pbuilder operation and
|
||||
depending on this either save it into the appropiate variable
|
||||
or finalize pbuilder-dist's execution.
|
||||
|
||||
"""
|
||||
arguments = ("create", "update", "build", "clean", "login", "execute")
|
||||
|
||||
arguments = ('create', 'update', 'build', 'clean', 'login', 'execute')
|
||||
|
||||
if operation not in arguments:
|
||||
if operation.endswith(".dsc"):
|
||||
if os.path.isfile(operation):
|
||||
self.operation = "build"
|
||||
return [operation]
|
||||
Logger.error('Could not find file "%s".', operation)
|
||||
if item_ends_with(arguments, '.dsc'):
|
||||
self.operation = 'build'
|
||||
else:
|
||||
print 'Error: «%s» is not a recognized argument.' % operation
|
||||
print 'Please use one of those: ' + ', '.join(arguments) + '.'
|
||||
sys.exit(1)
|
||||
|
||||
Logger.error(
|
||||
'"%s" is not a recognized argument.\nPlease use one of these: %s.',
|
||||
operation,
|
||||
", ".join(arguments),
|
||||
)
|
||||
sys.exit(1)
|
||||
|
||||
else:
|
||||
self.operation = operation
|
||||
return []
|
||||
|
||||
def get_command(self, remaining_arguments=None):
|
||||
"""PbuilderDist.get_command -> string
|
||||
def get_command(self, remaining_arguments = None):
|
||||
""" pbuilder_dist.get_command -> string
|
||||
|
||||
Generate the pbuilder command which matches the given configuration
|
||||
and return it as a string.
|
||||
|
||||
"""
|
||||
if not self.build_architecture:
|
||||
self.build_architecture = self.system_architecture
|
||||
|
||||
if self.build_architecture == self.system_architecture:
|
||||
self.chroot_string = self.target_distro
|
||||
else:
|
||||
self.chroot_string = self.target_distro + "-" + self.build_architecture
|
||||
|
||||
prefix = os.path.join(self.base, self.chroot_string)
|
||||
if "--buildresult" not in remaining_arguments:
|
||||
result = os.path.normpath(f"{prefix}_result/")
|
||||
else:
|
||||
location_of_arg = remaining_arguments.index("--buildresult")
|
||||
result = os.path.normpath(remaining_arguments[location_of_arg + 1])
|
||||
remaining_arguments.pop(location_of_arg + 1)
|
||||
remaining_arguments.pop(location_of_arg)
|
||||
|
||||
if not self.logfile and self.operation != "login":
|
||||
if self.operation == "build":
|
||||
dsc_files = [a for a in remaining_arguments if a.strip().endswith(".dsc")]
|
||||
assert len(dsc_files) == 1
|
||||
dsc = debian.deb822.Dsc(open(dsc_files[0], encoding="utf-8"))
|
||||
version = ubuntutools.version.Version(dsc["Version"])
|
||||
name = (
|
||||
dsc["Source"]
|
||||
+ "_"
|
||||
+ version.strip_epoch()
|
||||
+ "_"
|
||||
+ self.build_architecture
|
||||
+ ".build"
|
||||
)
|
||||
self.logfile = os.path.join(result, name)
|
||||
else:
|
||||
self.logfile = os.path.join(result, "last_operation.log")
|
||||
|
||||
if not os.path.isdir(result):
|
||||
try:
|
||||
os.makedirs(result)
|
||||
except OSError:
|
||||
Logger.error('Cannot create results directory "%s"', result)
|
||||
sys.exit(1)
|
||||
# Calculate variables which depend on arguments given at runtime.
|
||||
self._calculate()
|
||||
|
||||
arguments = [
|
||||
f"--{self.operation}",
|
||||
"--distribution",
|
||||
self.target_distro,
|
||||
"--buildresult",
|
||||
result,
|
||||
self.operation,
|
||||
'--basetgz "%(base)s/%(chroot_string)s-base.tgz"' % self,
|
||||
'--distribution "%(target_distro)s"' % self,
|
||||
'--buildresult "%(base)s/%(chroot_string)s_result/"' % self,
|
||||
'--logfile "%(logfile)s"' % self,
|
||||
'--aptcache "/var/cache/apt/archives/"',
|
||||
### --mirror "${ARCHIVE}" \
|
||||
]
|
||||
|
||||
if self.operation == "update":
|
||||
arguments += ["--override-config"]
|
||||
|
||||
if self.builder == "pbuilder":
|
||||
arguments += ["--basetgz", prefix + "-base.tgz"]
|
||||
elif self.builder == "cowbuilder":
|
||||
arguments += ["--basepath", prefix + "-base.cow"]
|
||||
else:
|
||||
Logger.error('Unrecognized builder "%s".', self.builder)
|
||||
sys.exit(1)
|
||||
|
||||
if self.logfile:
|
||||
arguments += ["--logfile", self.logfile]
|
||||
|
||||
if os.path.exists("/var/cache/archive/"):
|
||||
arguments += ["--bindmounts", "/var/cache/archive/"]
|
||||
|
||||
config = UDTConfig()
|
||||
if self.target_distro in self._debian_distros:
|
||||
mirror = os.environ.get("MIRRORSITE", config.get_value("DEBIAN_MIRROR"))
|
||||
components = "main"
|
||||
if self.extra_components:
|
||||
components += " contrib non-free non-free-firmware"
|
||||
else:
|
||||
mirror = os.environ.get("MIRRORSITE", config.get_value("UBUNTU_MIRROR"))
|
||||
if self.build_architecture not in ("amd64", "i386"):
|
||||
mirror = os.environ.get("MIRRORSITE", config.get_value("UBUNTU_PORTS_MIRROR"))
|
||||
components = "main restricted"
|
||||
if self.extra_components:
|
||||
components += " universe multiverse"
|
||||
|
||||
arguments += ["--mirror", mirror]
|
||||
|
||||
othermirrors = []
|
||||
localrepo = f"/var/cache/archive/{self.target_distro}"
|
||||
if os.path.exists(localrepo):
|
||||
repo = f"deb file:///var/cache/archive/ {self.target_distro}/"
|
||||
othermirrors.append(repo)
|
||||
|
||||
if self.target_distro in self._debian_distros:
|
||||
try:
|
||||
codename = self.debian_distro_info.codename(
|
||||
self.target_distro, default=self.target_distro
|
||||
)
|
||||
except DistroDataOutdated as error:
|
||||
Logger.warning(error)
|
||||
if codename in (self.debian_distro_info.devel(), "experimental"):
|
||||
self.enable_security = False
|
||||
self.enable_updates = False
|
||||
self.enable_proposed = False
|
||||
elif codename in (self.debian_distro_info.testing(), "testing"):
|
||||
self.enable_updates = False
|
||||
|
||||
if self.enable_security:
|
||||
pocket = "-security"
|
||||
with suppress(ValueError):
|
||||
# before bullseye (version 11) security suite is /updates
|
||||
if float(self.debian_distro_info.version(codename)) < 11.0:
|
||||
pocket = "/updates"
|
||||
othermirrors.append(
|
||||
f"deb {config.get_value('DEBSEC_MIRROR')}"
|
||||
f" {self.target_distro}{pocket} {components}"
|
||||
)
|
||||
if self.enable_updates:
|
||||
othermirrors.append(f"deb {mirror} {self.target_distro}-updates {components}")
|
||||
if self.enable_proposed:
|
||||
othermirrors.append(
|
||||
f"deb {mirror} {self.target_distro}-proposed-updates {components}"
|
||||
)
|
||||
if self.enable_backports:
|
||||
othermirrors.append(f"deb {mirror} {self.target_distro}-backports {components}")
|
||||
|
||||
aptcache = os.path.join(self.base, "aptcache", "debian")
|
||||
else:
|
||||
try:
|
||||
dev_release = self.target_distro == self.ubuntu_distro_info.devel()
|
||||
except DistroDataOutdated as error:
|
||||
Logger.warning(error)
|
||||
dev_release = True
|
||||
|
||||
if dev_release:
|
||||
self.enable_security = False
|
||||
self.enable_updates = False
|
||||
|
||||
if self.enable_security:
|
||||
othermirrors.append(f"deb {mirror} {self.target_distro}-security {components}")
|
||||
if self.enable_updates:
|
||||
othermirrors.append(f"deb {mirror} {self.target_distro}-updates {components}")
|
||||
if self.enable_proposed:
|
||||
othermirrors.append(f"deb {mirror} {self.target_distro}-proposed {components}")
|
||||
|
||||
aptcache = os.path.join(self.base, "aptcache", "ubuntu")
|
||||
|
||||
if "OTHERMIRROR" in os.environ:
|
||||
othermirrors += os.environ["OTHERMIRROR"].split("|")
|
||||
|
||||
if othermirrors:
|
||||
arguments += ["--othermirror", "|".join(othermirrors)]
|
||||
|
||||
# Work around LP:#599695
|
||||
if (
|
||||
ubuntutools.misc.system_distribution() == "Debian"
|
||||
and self.target_distro not in self._debian_distros
|
||||
):
|
||||
if not os.path.exists("/usr/share/keyrings/ubuntu-archive-keyring.gpg"):
|
||||
Logger.error("ubuntu-keyring not installed")
|
||||
sys.exit(1)
|
||||
arguments += [
|
||||
"--debootstrapopts",
|
||||
"--keyring=/usr/share/keyrings/ubuntu-archive-keyring.gpg",
|
||||
]
|
||||
elif (
|
||||
ubuntutools.misc.system_distribution() == "Ubuntu"
|
||||
and self.target_distro in self._debian_distros
|
||||
):
|
||||
if not os.path.exists("/usr/share/keyrings/debian-archive-keyring.gpg"):
|
||||
Logger.error("debian-archive-keyring not installed")
|
||||
sys.exit(1)
|
||||
arguments += [
|
||||
"--debootstrapopts",
|
||||
"--keyring=/usr/share/keyrings/debian-archive-keyring.gpg",
|
||||
]
|
||||
|
||||
arguments += ["--aptcache", aptcache, "--components", components]
|
||||
|
||||
if not os.path.isdir(aptcache):
|
||||
try:
|
||||
os.makedirs(aptcache)
|
||||
except OSError:
|
||||
Logger.error('Cannot create aptcache directory "%s"', aptcache)
|
||||
sys.exit(1)
|
||||
|
||||
if self.build_architecture != self.system_architecture:
|
||||
arguments += ["--debootstrapopts", "--arch=" + self.build_architecture]
|
||||
arguments.append('--debootstrapopts --arch')
|
||||
arguments.append('--debootstrapopts "%(build_architecture)s"' % self)
|
||||
|
||||
apt_conf_dir = os.path.join(self.base, f"etc/{self.target_distro}/apt.conf")
|
||||
if os.path.exists(apt_conf_dir):
|
||||
arguments += ["--aptconfdir", apt_conf_dir]
|
||||
if self.proxy:
|
||||
arguments.append('--http-proxy "%(proxy)s"' % self)
|
||||
|
||||
### $( [ $ISDEBIAN != "False" ] || echo "--aptconfdir \"${BASE_DIR}/etc/${DISTRIBUTION}/apt.conf/\"" ) \
|
||||
|
||||
# Append remaining arguments
|
||||
if remaining_arguments:
|
||||
arguments.extend(remaining_arguments)
|
||||
|
||||
# Export the distribution and architecture information to the
|
||||
# environment so that it is accessible to ~/.pbuilderrc (LP: #628933).
|
||||
# With both common variable name schemes (BTS: #659060).
|
||||
return [
|
||||
self.auth,
|
||||
"HOME=" + os.path.expanduser("~"),
|
||||
"ARCHITECTURE=" + self.build_architecture,
|
||||
"DISTRIBUTION=" + self.target_distro,
|
||||
"ARCH=" + self.build_architecture,
|
||||
"DIST=" + self.target_distro,
|
||||
"DEB_BUILD_OPTIONS=" + os.environ.get("DEB_BUILD_OPTIONS", ""),
|
||||
self.builder,
|
||||
] + arguments
|
||||
return self.auth + ' /usr/sbin/pbuilder ' + ' '.join(arguments)
|
||||
|
||||
def host_architecture():
|
||||
""" host_architecture -> string
|
||||
|
||||
def show_help(exit_code=0):
|
||||
"""help() -> None
|
||||
Detect the host's architecture and return it as a string
|
||||
(i386/amd64/other values).
|
||||
|
||||
"""
|
||||
|
||||
return os.uname()[4].replace('x86_64', 'amd64').replace('i586', 'i386').replace('i686', 'i386')
|
||||
|
||||
def item_ends_with(list, string):
|
||||
""" item_ends_with(list, string) -> bool
|
||||
|
||||
Return True if one of the items in list ends with the given string,
|
||||
or else return False.
|
||||
|
||||
"""
|
||||
|
||||
for item in list:
|
||||
if item.endswith(string):
|
||||
return True
|
||||
|
||||
return False
|
||||
|
||||
def ask(question):
|
||||
""" ask(question) -> string
|
||||
|
||||
Ask the given question and return the answer. Also catch
|
||||
KeyboardInterrupt (Ctrl+C) and EOFError (Ctrl+D) exceptions and
|
||||
immediately return None if one of those is found.
|
||||
|
||||
"""
|
||||
|
||||
try:
|
||||
answer = raw_input(question)
|
||||
except (KeyboardInterrupt, EOFError):
|
||||
print
|
||||
answer = None
|
||||
|
||||
return answer
|
||||
|
||||
def help(exit_code = 0):
|
||||
""" help() -> None
|
||||
|
||||
Print a help message for pbuilder-dist, and exit with the given code.
|
||||
|
||||
"""
|
||||
Logger.info("See man pbuilder-dist for more information.")
|
||||
|
||||
print 'Bad...'
|
||||
|
||||
sys.exit(exit_code)
|
||||
|
||||
|
||||
def main():
|
||||
"""main() -> None
|
||||
""" main() -> None
|
||||
|
||||
This is pbuilder-dist's main function. It creates a PbuilderDist
|
||||
This is pbuilder-dist's main function. It creates a pbuilder_dist
|
||||
object, modifies all necessary settings taking data from the
|
||||
executable's name and command line options and finally either ends
|
||||
the script and runs pbuilder itself or exists with an error message.
|
||||
|
||||
"""
|
||||
script_name = os.path.basename(sys.argv[0])
|
||||
parts = script_name.split("-")
|
||||
|
||||
script_name = os.path.basename(__name__ or sys.argv[0])
|
||||
parts = script_name.split('-')
|
||||
|
||||
# Copy arguments into another list for save manipulation
|
||||
args = sys.argv[1:]
|
||||
|
||||
if "-" in script_name and parts[0] not in ("pbuilder", "cowbuilder") or len(parts) > 3:
|
||||
Logger.error('"%s" is not a valid name for a "pbuilder-dist" executable.', script_name)
|
||||
if '-' in script_name and parts[0] != 'pbuilder' or len(parts) > 3:
|
||||
print 'Error: «%s» is not a valid name for a «pbuilder-dist» executable.' % script_name
|
||||
sys.exit(1)
|
||||
|
||||
if len(args) < 1:
|
||||
Logger.error("Insufficient number of arguments.")
|
||||
show_help(1)
|
||||
print 'Insufficient number of arguments.'
|
||||
help(1)
|
||||
|
||||
if args[0] in ("-h", "--help", "help"):
|
||||
show_help(0)
|
||||
if args[0] in ('-h', '--help', 'help'):
|
||||
help(0)
|
||||
|
||||
app = PbuilderDist(parts[0])
|
||||
app = pbuilder_dist()
|
||||
|
||||
if len(parts) > 1 and parts[1] != "dist" and "." not in parts[1]:
|
||||
if len(parts) > 1:
|
||||
app.set_target_distro(parts[1])
|
||||
else:
|
||||
app.set_target_distro(args.pop(0))
|
||||
|
||||
if len(parts) > 2:
|
||||
requested_arch = parts[2]
|
||||
elif len(args) > 0:
|
||||
if shutil.which("arch-test") is not None:
|
||||
arch_test = subprocess.run(
|
||||
["arch-test", args[0]], check=False, stdout=subprocess.DEVNULL
|
||||
)
|
||||
if arch_test.returncode == 0:
|
||||
elif args[0] in ('i386', 'amd64'):
|
||||
requested_arch = args.pop(0)
|
||||
elif os.path.isdir("/usr/lib/arch-test") and args[0] in os.listdir(
|
||||
"/usr/lib/arch-test/"
|
||||
):
|
||||
Logger.error(
|
||||
'Architecture "%s" is not supported on your '
|
||||
"currently running kernel. Consider installing "
|
||||
"the qemu-user-static package to enable the use of "
|
||||
"foreign architectures.",
|
||||
args[0],
|
||||
)
|
||||
sys.exit(1)
|
||||
else:
|
||||
requested_arch = None
|
||||
else:
|
||||
Logger.error(
|
||||
'Cannot determine if "%s" is a valid architecture. '
|
||||
"Please install the arch-test package and retry.",
|
||||
args[0],
|
||||
)
|
||||
sys.exit(1)
|
||||
else:
|
||||
requested_arch = None
|
||||
|
||||
if requested_arch:
|
||||
if requested_arch in ('i386', 'amd64') and app.system_architecture == 'amd64':
|
||||
app.build_architecture = requested_arch
|
||||
# For some foreign architectures we need to use qemu
|
||||
if requested_arch != app.system_architecture and (
|
||||
app.system_architecture,
|
||||
requested_arch,
|
||||
) not in [
|
||||
("amd64", "i386"),
|
||||
("arm64", "arm"),
|
||||
("arm64", "armhf"),
|
||||
("powerpc", "ppc64"),
|
||||
("ppc64", "powerpc"),
|
||||
]:
|
||||
args += ["--debootstrap", "debootstrap"]
|
||||
|
||||
if "mainonly" in sys.argv or "--main-only" in sys.argv:
|
||||
app.extra_components = False
|
||||
if "mainonly" in sys.argv:
|
||||
args.remove("mainonly")
|
||||
else:
|
||||
args.remove("--main-only")
|
||||
|
||||
if "--release-only" in sys.argv:
|
||||
args.remove("--release-only")
|
||||
app.enable_security = False
|
||||
app.enable_updates = False
|
||||
app.enable_proposed = False
|
||||
elif "--security-only" in sys.argv:
|
||||
args.remove("--security-only")
|
||||
app.enable_updates = False
|
||||
app.enable_proposed = False
|
||||
elif "--updates-only" in sys.argv:
|
||||
args.remove("--updates-only")
|
||||
app.enable_proposed = False
|
||||
elif "--backports" in sys.argv:
|
||||
args.remove("--backports")
|
||||
app.enable_backports = True
|
||||
|
||||
if len(args) < 1:
|
||||
Logger.error("Insufficient number of arguments.")
|
||||
show_help(1)
|
||||
|
||||
# Parse the operation
|
||||
args = app.set_operation(args.pop(0)) + args
|
||||
|
||||
if app.operation == "build":
|
||||
if len([a for a in args if a.strip().endswith(".dsc")]) != 1:
|
||||
msg = "You have to specify one .dsc file if you want to build."
|
||||
Logger.error(msg)
|
||||
print 'Error: Architecture switching is not supported on your system; wrong filename.'
|
||||
sys.exit(1)
|
||||
|
||||
if 'mainonly' in sys.argv:
|
||||
app.extra_components = False
|
||||
args.remove('mainonly')
|
||||
|
||||
if len(args) < 1:
|
||||
print 'Insufficient number of arguments.'
|
||||
help(1)
|
||||
|
||||
# Parse the operation
|
||||
app.set_operation(args.pop(0))
|
||||
|
||||
# Execute the pbuilder command
|
||||
if "--debug-echo" not in args:
|
||||
sys.exit(subprocess.call(app.get_command(args)))
|
||||
else:
|
||||
Logger.info(app.get_command([arg for arg in args if arg != "--debug-echo"]))
|
||||
sys.exit(os.system(app.get_command(args)))
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
||||
if __name__ == "__main__":
|
||||
try:
|
||||
main()
|
||||
except KeyboardInterrupt:
|
||||
Logger.error("Manually aborted.")
|
||||
print 'Manually aborted.'
|
||||
sys.exit(1)
|
||||
|
@ -3,71 +3,42 @@
|
||||
# Copyright (C) Jamin W. Collins <jcollins@asgardsrealm.net>
|
||||
# Copyright (C) Jordan Mantha <mantha@ubuntu.com>
|
||||
#
|
||||
# ##################################################################
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# See file /usr/share/common-licenses/GPL for more details.
|
||||
#
|
||||
# ##################################################################
|
||||
# License: GPLv2 or later
|
||||
#
|
||||
# This script is a wrapper to be able to easily use pbuilder for
|
||||
# different Ubuntu distributions (eg, Lucid, Natty, etc).
|
||||
# different distributions (eg, Gutsy, Hardy, Debian unstable, etc).
|
||||
#
|
||||
# Create symlinks to this script naming them 'pbuilder-lucid',
|
||||
# 'pbuilder-natty', etc. If you want additional features try out the more
|
||||
# advanced script 'pbuilder-dist'.
|
||||
# Create symlinks to this script naming them 'pbuilder-feisty', 'pbuilder-
|
||||
# gutsy', 'pbuilder-hardy', etc. If you want additional features try
|
||||
# out the more advanced script 'pbuilder-dist'.
|
||||
|
||||
OPERATION=$1
|
||||
DISTRIBUTION=`basename $0 | cut -f2 -d '-'`
|
||||
PROCEED=false
|
||||
BASE_DIR="$HOME/pbuilder"
|
||||
|
||||
usage() {
|
||||
prog=$(basename $0)
|
||||
cat <<EOF
|
||||
Usage: $prog command [pbuilder-options...]
|
||||
|
||||
A simple multi-release pbuilder wrapper
|
||||
|
||||
Valid commands are:
|
||||
create
|
||||
update
|
||||
build
|
||||
clean
|
||||
login
|
||||
execute
|
||||
|
||||
Options:
|
||||
-h, --help show this help message and exit
|
||||
EOF
|
||||
exit $1
|
||||
}
|
||||
|
||||
case $OPERATION in
|
||||
create|update|build|clean|login|execute)
|
||||
;;
|
||||
-h|--help)
|
||||
usage 0
|
||||
;;
|
||||
*)
|
||||
usage 1
|
||||
create|update|build|clean|login|execute )
|
||||
PROCEED=true
|
||||
;;
|
||||
esac
|
||||
shift
|
||||
if [ ! -d $BASE_DIR/${DISTRIBUTION}_result ]; then
|
||||
mkdir -p $BASE_DIR/${DISTRIBUTION}_result/
|
||||
fi
|
||||
sudo pbuilder $OPERATION \
|
||||
if [ $PROCEED = true ]; then
|
||||
shift
|
||||
if [ ! -d $BASE_DIR/${DISTRIBUTION}_result ]
|
||||
then mkdir -p $BASE_DIR/${DISTRIBUTION}_result/
|
||||
fi
|
||||
sudo pbuilder $OPERATION \
|
||||
--basetgz $BASE_DIR/$DISTRIBUTION-base.tgz \
|
||||
--distribution $DISTRIBUTION \
|
||||
--buildresult $BASE_DIR/$DISTRIBUTION_result \
|
||||
--othermirror "deb http://archive.ubuntu.com/ubuntu $DISTRIBUTION universe multiverse" "$@"
|
||||
--othermirror "deb http://archive.ubuntu.com/ubuntu $DISTRIBUTION universe multiverse" $@
|
||||
else
|
||||
echo "Invalid command..."
|
||||
echo "Valid commands are:"
|
||||
echo " create"
|
||||
echo " update"
|
||||
echo " build"
|
||||
echo " clean"
|
||||
echo " login"
|
||||
echo " execute"
|
||||
exit 1
|
||||
fi
|
||||
|
142
pm-helper
142
pm-helper
@ -1,142 +0,0 @@
|
||||
#!/usr/bin/python3
|
||||
# Find the next thing to work on for proposed-migration
|
||||
# Copyright (C) 2023 Canonical Ltd.
|
||||
# Author: Steve Langasek <steve.langasek@ubuntu.com>
|
||||
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License, version 3.
|
||||
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
# General Public License for more details.
|
||||
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
import lzma
|
||||
import sys
|
||||
import webbrowser
|
||||
from argparse import ArgumentParser
|
||||
|
||||
import yaml
|
||||
from launchpadlib.launchpad import Launchpad
|
||||
|
||||
from ubuntutools.utils import get_url
|
||||
|
||||
# proposed-migration is only concerned with the devel series; unlike other
|
||||
# tools, don't make this configurable
|
||||
excuses_url = "https://ubuntu-archive-team.ubuntu.com/proposed-migration/update_excuses.yaml.xz"
|
||||
|
||||
|
||||
def get_proposed_version(excuses, package):
|
||||
for k in excuses["sources"]:
|
||||
if k["source"] == package:
|
||||
return k.get("new-version")
|
||||
return None
|
||||
|
||||
|
||||
def claim_excuses_bug(launchpad, bug, package):
|
||||
print(f"LP: #{bug.id}: {bug.title}")
|
||||
ubuntu = launchpad.distributions["ubuntu"]
|
||||
series = ubuntu.current_series.fullseriesname
|
||||
|
||||
for task in bug.bug_tasks:
|
||||
# targeting to a series doesn't make the default task disappear,
|
||||
# it just makes it useless
|
||||
if task.bug_target_name == f"{package} ({series})":
|
||||
our_task = task
|
||||
break
|
||||
if task.bug_target_name == f"{package} (Ubuntu)":
|
||||
our_task = task
|
||||
|
||||
if our_task.assignee == launchpad.me:
|
||||
print("Bug already assigned to you.")
|
||||
return True
|
||||
if our_task.assignee:
|
||||
print(f"Currently assigned to {our_task.assignee.name}")
|
||||
|
||||
print("""Do you want to claim this bug? [yN] """, end="")
|
||||
sys.stdout.flush()
|
||||
response = sys.stdin.readline()
|
||||
if response.strip().lower().startswith("y"):
|
||||
our_task.assignee = launchpad.me
|
||||
our_task.lp_save()
|
||||
return True
|
||||
|
||||
return False
|
||||
|
||||
|
||||
def create_excuses_bug(launchpad, package, version):
|
||||
print("Will open a new bug")
|
||||
bug = launchpad.bugs.createBug(
|
||||
title=f"proposed-migration for {package} {version}",
|
||||
tags=("update-excuse"),
|
||||
target=f"https://api.launchpad.net/devel/ubuntu/+source/{package}",
|
||||
description=f"{package} {version} is stuck in -proposed.",
|
||||
)
|
||||
|
||||
task = bug.bug_tasks[0]
|
||||
task.assignee = launchpad.me
|
||||
task.lp_save()
|
||||
|
||||
print(f"Opening {bug.web_link} in browser")
|
||||
webbrowser.open(bug.web_link)
|
||||
return bug
|
||||
|
||||
|
||||
def has_excuses_bugs(launchpad, package):
|
||||
ubuntu = launchpad.distributions["ubuntu"]
|
||||
pkg = ubuntu.getSourcePackage(name=package)
|
||||
if not pkg:
|
||||
raise ValueError(f"No such source package: {package}")
|
||||
|
||||
tasks = pkg.searchTasks(tags=["update-excuse"], order_by=["id"])
|
||||
|
||||
bugs = [task.bug for task in tasks]
|
||||
if not bugs:
|
||||
return False
|
||||
|
||||
if len(bugs) == 1:
|
||||
print(f"There is 1 open update-excuse bug against {package}")
|
||||
else:
|
||||
print(f"There are {len(bugs)} open update-excuse bugs against {package}")
|
||||
|
||||
for bug in bugs:
|
||||
if claim_excuses_bug(launchpad, bug, package):
|
||||
return True
|
||||
|
||||
return True
|
||||
|
||||
|
||||
def main():
|
||||
parser = ArgumentParser()
|
||||
parser.add_argument("-l", "--launchpad", dest="launchpad_instance", default="production")
|
||||
parser.add_argument(
|
||||
"-v", "--verbose", default=False, action="store_true", help="be more verbose"
|
||||
)
|
||||
parser.add_argument("package", nargs="?", help="act on this package only")
|
||||
args = parser.parse_args()
|
||||
|
||||
args.launchpad = Launchpad.login_with("pm-helper", args.launchpad_instance, version="devel")
|
||||
|
||||
f = get_url(excuses_url, False)
|
||||
with lzma.open(f) as lzma_f:
|
||||
excuses = yaml.load(lzma_f, Loader=yaml.CSafeLoader)
|
||||
|
||||
if args.package:
|
||||
try:
|
||||
if not has_excuses_bugs(args.launchpad, args.package):
|
||||
proposed_version = get_proposed_version(excuses, args.package)
|
||||
if not proposed_version:
|
||||
print(f"Package {args.package} not found in -proposed.")
|
||||
sys.exit(1)
|
||||
create_excuses_bug(args.launchpad, args.package, proposed_version)
|
||||
except ValueError as e:
|
||||
sys.stderr.write(f"{e}\n")
|
||||
else:
|
||||
pass # for now
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
sys.exit(main())
|
@ -1,14 +0,0 @@
|
||||
#!/usr/bin/python3
|
||||
#
|
||||
# pull-debian-ddebs -- pull ddeb package files for debian
|
||||
# Basic usage: pull-debian-ddebs <package name> [version|release]
|
||||
#
|
||||
# See pull-pkg
|
||||
|
||||
# pylint: disable=invalid-name
|
||||
# pylint: enable=invalid-name
|
||||
|
||||
from ubuntutools.pullpkg import PullPkg
|
||||
|
||||
if __name__ == "__main__":
|
||||
PullPkg.main(distro="debian", pull="ddebs")
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user