mirror of
https://git.launchpad.net/ubuntu-dev-tools
synced 2025-03-12 23:51:08 +00:00
* get-branches:
- Improve invalid directory error. - Check that the team page exists before creating new directory for downloads. * doc/get-branches.1: Created.
This commit is contained in:
parent
dc80eacf3f
commit
59a6f32e8e
1
debian/changelog
vendored
1
debian/changelog
vendored
@ -2,6 +2,7 @@ ubuntu-dev-tools (0.37ubuntu1) intrepid; urgency=low
|
||||
|
||||
[ Jonathan Patrick Davies ]
|
||||
* get-branches: Open the teams code page before making a new directory.
|
||||
* doc/get-branches.1: Created.
|
||||
|
||||
-- Jonathan Patrick Davies <jpds@ubuntu.com> Sun, 10 August 2008 22:07:58 +0100
|
||||
|
||||
|
45
doc/get-branches.1
Normal file
45
doc/get-branches.1
Normal file
@ -0,0 +1,45 @@
|
||||
.TH GET-BRANCHES "1" "11 August 2008" "ubuntu-dev-tools"
|
||||
.SH NAME
|
||||
get-branches \- downloads all branches related to a Launchpad team or person
|
||||
|
||||
.SH SYNOPSIS
|
||||
|
||||
.B get-branches [-d directory] [-o branch|checkout] \-t <team>
|
||||
|
||||
.B get-branches <team>
|
||||
|
||||
.B get-branches \-\-help
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBget-branches\fR examines the code page of a Launchpad team/person, parses it,
|
||||
and calls Bazaar to download all branches on that page.
|
||||
|
||||
.SH OPTIONS
|
||||
.PP
|
||||
Listed below are the command line options for \fBget-branches\fR:
|
||||
.TP
|
||||
.B \-h or \-\-help
|
||||
Display a help message and exit.
|
||||
.TP
|
||||
.B \-d or \-\-directory
|
||||
Download branches to a directory other than the current directory.
|
||||
.TP
|
||||
.B \-o or \-\-operation
|
||||
Specifies which Bazaar operation to use when downloading the branches; may be
|
||||
either \fIbranch\fR or \fIcheckout\fR.
|
||||
.TP
|
||||
.B \-t or \-\-team
|
||||
Specifies which Launchpad team/person to download branches from. This option is
|
||||
required.
|
||||
|
||||
.SH AUTHORS
|
||||
.PP
|
||||
\fBget-branches\fR was written by Daniel Holbach <daniel.holbach@ubuntu.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.
|
||||
|
||||
.SH SEE ALSO
|
||||
.PP
|
||||
.B bzr(1)
|
@ -59,7 +59,8 @@ def main():
|
||||
sys.exit(1)
|
||||
|
||||
if not os.path.isdir(directory): # Check that it is a directory.
|
||||
print >> sys.stderr, "%s is not a directory." % directory
|
||||
print >> sys.stderr, "%s is not a valid directory." % directory
|
||||
optParser.print_help()
|
||||
sys.exit(1)
|
||||
else:
|
||||
directory = os.path.abspath(args[0])
|
||||
@ -138,7 +139,7 @@ def main():
|
||||
|
||||
branch_url_regex = r'<tt>bzr branch lp:~(.*)</tt>'
|
||||
branch_url = re.findall(branch_url_regex, branch_page)
|
||||
print "Downloading branch:", branch_url[0]
|
||||
print "Downloading branch: lp:~%s." % branch_url[0]
|
||||
|
||||
if branch_url[0]:
|
||||
product = branch_url[0].split("/")[-2]
|
||||
|
Loading…
x
Reference in New Issue
Block a user