Merge lp:~jelmer/ubuntu-dev-tools/lptools-migration into lp:~ubuntu-dev/ubuntu-dev-tools/trunk
- lptools-migration
- Merge into trunk
Status: | Merged | ||||
---|---|---|---|---|---|
Merged at revision: | 1123 | ||||
Proposed branch: | lp:~jelmer/ubuntu-dev-tools/lptools-migration | ||||
Merge into: | lp:~ubuntu-dev/ubuntu-dev-tools/trunk | ||||
Diff against target: |
1227 lines (+30/-1005) 18 files modified
debian/NEWS (+18/-0) debian/changelog (+12/-1) debian/control (+0/-7) debian/copyright (+0/-14) doc/get-branches.1 (+0/-47) doc/grab-attachments.1 (+0/-57) doc/lp-list-bugs.1 (+0/-27) doc/lp-project-upload.1 (+0/-24) doc/lp-set-dup.1 (+0/-56) doc/lp-shell.1 (+0/-52) get-branches (+0/-118) grab-attachments (+0/-107) lp-list-bugs (+0/-63) lp-project-upload (+0/-178) lp-set-dup (+0/-134) lp-shell (+0/-112) setup.py (+0/-6) ubuntutools/test/test_help.py (+0/-2) |
||||
To merge this branch: | bzr merge lp:~jelmer/ubuntu-dev-tools/lptools-migration | ||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Stefano Rivera | Approve | ||
Review via email: mp+71847@code.launchpad.net |
Commit message
Description of the change
Remove lp-set-dup, lp-list-bugs and lp-project-upload, which have been migrated to lptools.
Stefano Rivera (stefanor) wrote : | # |
- 1121. By Jelmer Vernooij
-
Also remove manual pages, entries in copyright.
Jelmer Vernooij (jelmer) wrote : | # |
> Please also update the package description, debian/copyright, and
> ubuntutools/
Good point. I've updated the branch.
- 1122. By Jelmer Vernooij
-
Update test-help
Stefano Rivera (stefanor) wrote : | # |
I'm happy. Are you going to add a Breaks+Replaces in lptools?
Benjamin Drung (bdrung) wrote : | # |
Before we can merge this branch, we need to be assured that lptools will be upload to Debian.
Please refer to bug #708886.
Shouldn't get-branches, grab-attachments, and lp-shell moved to lptools too?
Benjamin Drung (bdrung) wrote : | # |
You added lptools to Recommends. Are there any tools in ubuntu-dev-tools that use one of the three scripts? Otherwise I think we should drop it and add lptools to packaging-dev instead.
Stefano Rivera (stefanor) wrote : | # |
Benjamin: Good catch, re getting lptools into Debian.
No, nothing else in u-d-t uses these scripts
Benjamin Drung (bdrung) wrote : | # |
Jelmer answered:
> I added it mainly to make the upgrade smoother for people who have
> ubuntu-dev-tools installed at the moment and use lp-set-dup,
> lp-list-bugs or lp-upload-project.
> Adding it as a recommends for packaging-dev works for me too. Just let
> me know which one you prefer.
I prefer dropping lptools from u-d-t Recommends and add it to packaging-dev. Other thoughts?
Stefano Rivera (stefanor) wrote : | # |
I think lptools should probably be in Debian (as a Debian user, I'd appreciate it).
And I agree with the packaging-dev solution to this problem.
- 1123. By Jelmer Vernooij
-
remove grab-attachments, too.
- 1124. By Jelmer Vernooij
-
Remove lp-shell, too.
- 1125. By Jelmer Vernooij
-
get-branches is in lptools now, too.
- 1126. By Jelmer Vernooij
-
merge trunk.
Jelmer Vernooij (jelmer) wrote : | # |
I've got a lptools upload ready for Debian, but I'm not sure what version of ubuntu-dev-tools to use in Breaks/Replaces yet. Would 0.129 be a safe bet?
Benjamin Drung (bdrung) wrote : | # |
0.129 will be a safe bet. I am going to merge this branch.
Can you drop lptools from Recommends?
Can you document in the changelog which tools where renamed?
Maybe a NEWS file entry would be useful.
Can you check if some names can be removed in the d/copyright file?
- 1127. By Jelmer Vernooij
-
Update changelog.
Jelmer Vernooij (jelmer) wrote : | # |
> 0.129 will be a safe bet. I am going to merge this branch.
>
> Can you drop lptools from Recommends?
Done.
> Can you document in the changelog which tools where renamed?
Done.
> Maybe a NEWS file entry would be useful.
Done.
> Can you check if some names can be removed in the d/copyright file?
As far as I can tell Dustin is the only one who no longer has copyright on any of the ubuntu-dev-tools; updated copyright accordingly.
I've uploaded a new lptools (with Breaks/Replaces for ubuntu-dev-tools << 0.129) to sid.
- 1128. By Jelmer Vernooij
-
Drop lptools from recommends.
- 1129. By Jelmer Vernooij
-
NEWS entry.
- 1130. By Jelmer Vernooij
-
Update copyright file.
Preview Diff
1 | === modified file 'debian/NEWS' | |||
2 | --- debian/NEWS 2011-03-01 13:03:32 +0000 | |||
3 | +++ debian/NEWS 2011-09-02 11:53:47 +0000 | |||
4 | @@ -1,3 +1,21 @@ | |||
5 | 1 | ubuntu-dev-tools (0.129) unstable; urgency=low | ||
6 | 2 | |||
7 | 3 | Several tools that worked against Launchpad but were not specific to Ubuntu | ||
8 | 4 | have been migrated to the "lptools" project. | ||
9 | 5 | |||
10 | 6 | The following tools have moved: | ||
11 | 7 | - get-branches (renamed to lp-get-branches) | ||
12 | 8 | - grab-attachments (renamed to lp-grab-attachments) | ||
13 | 9 | - lp-project-upload | ||
14 | 10 | - lp-list-bugs | ||
15 | 11 | - lp-set-dup | ||
16 | 12 | - lp-shell | ||
17 | 13 | |||
18 | 14 | They can now be found in the lptools package (version 0.0.1~bzr28-1 or | ||
19 | 15 | later). | ||
20 | 16 | |||
21 | 17 | -- Jelmer Vernooij <jelmer@debian.org> Fri, 02 Sep 2011 13:43:34 +0200 | ||
22 | 18 | |||
23 | 1 | ubuntu-dev-tools (0.119) unstable; urgency=low | 19 | ubuntu-dev-tools (0.119) unstable; urgency=low |
24 | 2 | 20 | ||
25 | 3 | launchpadlib 1.9 will cause some issues, as it uses the GNOME Keyring / KDE | 21 | launchpadlib 1.9 will cause some issues, as it uses the GNOME Keyring / KDE |
26 | 4 | 22 | ||
27 | === modified file 'debian/changelog' | |||
28 | --- debian/changelog 2011-08-16 18:56:38 +0000 | |||
29 | +++ debian/changelog 2011-09-02 11:53:47 +0000 | |||
30 | @@ -1,10 +1,21 @@ | |||
31 | 1 | ubuntu-dev-tools (0.129) UNRELEASED; urgency=low | 1 | ubuntu-dev-tools (0.129) UNRELEASED; urgency=low |
32 | 2 | 2 | ||
33 | 3 | [ Colin Watson ] | ||
34 | 3 | * syncpackage: Convert to new LP API, with --no-lp available for the old | 4 | * syncpackage: Convert to new LP API, with --no-lp available for the old |
35 | 4 | style of operation. | 5 | style of operation. |
36 | 5 | * syncpackage: Require -f/--force option to overwrite Ubuntu changes. | 6 | * syncpackage: Require -f/--force option to overwrite Ubuntu changes. |
37 | 6 | 7 | ||
39 | 7 | -- Colin Watson <cjwatson@ubuntu.com> Tue, 16 Aug 2011 16:40:22 +0100 | 8 | [ Jelmer Vernooij ] |
40 | 9 | * Remove several tools not specific to Ubuntu that have been migrated to | ||
41 | 10 | lptools (LP: #708886): | ||
42 | 11 | - get-branches (renamed to lp-get-branches) | ||
43 | 12 | - grab-attachments (renamed to lp-grab-attachments) | ||
44 | 13 | - lp-project-upload | ||
45 | 14 | - lp-list-bugs | ||
46 | 15 | - lp-set-dup | ||
47 | 16 | - lp-shell | ||
48 | 17 | |||
49 | 18 | -- Jelmer Vernooij <jelmer@debian.org> Thu, 01 Sep 2011 19:38:53 +0200 | ||
50 | 8 | 19 | ||
51 | 9 | ubuntu-dev-tools (0.128) unstable; urgency=low | 20 | ubuntu-dev-tools (0.128) unstable; urgency=low |
52 | 10 | 21 | ||
53 | 11 | 22 | ||
54 | === modified file 'debian/control' | |||
55 | --- debian/control 2011-08-14 15:07:42 +0000 | |||
56 | +++ debian/control 2011-09-02 11:53:47 +0000 | |||
57 | @@ -75,21 +75,14 @@ | |||
58 | 75 | - debian-distro-info - provides information about Debian's distributions. | 75 | - debian-distro-info - provides information about Debian's distributions. |
59 | 76 | - dgetlp - download a source package from the Launchpad library. | 76 | - dgetlp - download a source package from the Launchpad library. |
60 | 77 | - distro-info - provides information about the distributions' releases. | 77 | - distro-info - provides information about the distributions' releases. |
61 | 78 | - get-branches - used to branch/checkout all the bzr branches in a Launchpad | ||
62 | 79 | team. | ||
63 | 80 | - get-build-deps - install the build dependencies needed for a package | 78 | - get-build-deps - install the build dependencies needed for a package |
64 | 81 | reading debian/control. | 79 | reading debian/control. |
65 | 82 | - grab-attachments - download all bug attachments from a Launchpad bug | ||
66 | 83 | report. | ||
67 | 84 | - grab-merge - grabs a merge from merges.ubuntu.com easily. | 80 | - grab-merge - grabs a merge from merges.ubuntu.com easily. |
68 | 85 | - grep-merges - search for pending merges from Debian. | 81 | - grep-merges - search for pending merges from Debian. |
69 | 86 | - harvest - grabs information about development opportunities from | 82 | - harvest - grabs information about development opportunities from |
70 | 87 | http://harvest.ubuntu.com | 83 | http://harvest.ubuntu.com |
71 | 88 | - hugdaylist - compile HugDay lists from bug list URLs. | 84 | - hugdaylist - compile HugDay lists from bug list URLs. |
72 | 89 | - import-bug-from-debian - copy a bug from the Debian BTS to Launchpad | 85 | - import-bug-from-debian - copy a bug from the Debian BTS to Launchpad |
73 | 90 | - lp-list-bugs - briefly list status of Launchpad bugs. | ||
74 | 91 | - lp-project-upload - upload a release tarball to a Launchpad project | ||
75 | 92 | - lp-set-dup - sets the "duplicate of" bug of a bug and its dups. | ||
76 | 93 | - massfile - fill multiple bugs using a template. | 86 | - massfile - fill multiple bugs using a template. |
77 | 94 | - merge-changelog - manually merges two Debian changelogs with the same base | 87 | - merge-changelog - manually merges two Debian changelogs with the same base |
78 | 95 | version. | 88 | version. |
79 | 96 | 89 | ||
80 | === modified file 'debian/copyright' | |||
81 | --- debian/copyright 2011-06-25 15:53:44 +0000 | |||
82 | +++ debian/copyright 2011-09-02 11:53:47 +0000 | |||
83 | @@ -11,7 +11,6 @@ | |||
84 | 11 | doc/check-symbols.1 | 11 | doc/check-symbols.1 |
85 | 12 | doc/requestsync.1 | 12 | doc/requestsync.1 |
86 | 13 | doc/ubuntu-iso.1 | 13 | doc/ubuntu-iso.1 |
87 | 14 | lp-shell | ||
88 | 15 | requestsync | 14 | requestsync |
89 | 16 | setup.py | 15 | setup.py |
90 | 17 | ubuntu-iso | 16 | ubuntu-iso |
91 | @@ -22,7 +21,6 @@ | |||
92 | 22 | 2010, Benjamin Drung <bdrung@ubuntu.com> | 21 | 2010, Benjamin Drung <bdrung@ubuntu.com> |
93 | 23 | 2007-2010, Canonical Ltd. | 22 | 2007-2010, Canonical Ltd. |
94 | 24 | 2006-2007, Daniel Holbach <daniel.holbach@ubuntu.com> | 23 | 2006-2007, Daniel Holbach <daniel.holbach@ubuntu.com> |
95 | 25 | 2010, Dustin Kirkland <kirkland@ubuntu.com> | ||
96 | 26 | 2010, Evan Broder <evan@ebroder.net> | 24 | 2010, Evan Broder <evan@ebroder.net> |
97 | 27 | 2006-2007, Luke Yelavich <themuso@ubuntu.com> | 25 | 2006-2007, Luke Yelavich <themuso@ubuntu.com> |
98 | 28 | 2009-2010, Michael Bienia <geser@ubuntu.com> | 26 | 2009-2010, Michael Bienia <geser@ubuntu.com> |
99 | @@ -47,16 +45,11 @@ | |||
100 | 47 | doc/404main.1 | 45 | doc/404main.1 |
101 | 48 | doc/dgetlp.1 | 46 | doc/dgetlp.1 |
102 | 49 | doc/import-bug-from-debian.1 | 47 | doc/import-bug-from-debian.1 |
103 | 50 | doc/lp-project-upload.1 | ||
104 | 51 | doc/lp-set-dup.1 | ||
105 | 52 | doc/lp-shell.1 | ||
106 | 53 | doc/pbuilder-dist-simple.1 | 48 | doc/pbuilder-dist-simple.1 |
107 | 54 | doc/pbuilder-dist.1 | 49 | doc/pbuilder-dist.1 |
108 | 55 | doc/reverse-build-depends.1 | 50 | doc/reverse-build-depends.1 |
109 | 56 | doc/submittodebian.1 | 51 | doc/submittodebian.1 |
110 | 57 | import-bug-from-debian | 52 | import-bug-from-debian |
111 | 58 | lp-project-upload | ||
112 | 59 | lp-set-dup | ||
113 | 60 | pbuilder-dist | 53 | pbuilder-dist |
114 | 61 | pbuilder-dist-simple | 54 | pbuilder-dist-simple |
115 | 62 | reverse-build-depends | 55 | reverse-build-depends |
116 | @@ -87,8 +80,6 @@ | |||
117 | 87 | 80 | ||
118 | 88 | Files: ack-sync | 81 | Files: ack-sync |
119 | 89 | doc/bitesize.1 | 82 | doc/bitesize.1 |
120 | 90 | doc/get-branches.1 | ||
121 | 91 | doc/grab-attachments.1 | ||
122 | 92 | doc/grab-merge.1 | 83 | doc/grab-merge.1 |
123 | 93 | doc/harvest.1 | 84 | doc/harvest.1 |
124 | 94 | doc/hugdaylist.1 | 85 | doc/hugdaylist.1 |
125 | @@ -97,8 +88,6 @@ | |||
126 | 97 | doc/setup-packaging-environment.1 | 88 | doc/setup-packaging-environment.1 |
127 | 98 | doc/syncpackage.1 | 89 | doc/syncpackage.1 |
128 | 99 | bitesize | 90 | bitesize |
129 | 100 | get-branches | ||
130 | 101 | grab-attachments | ||
131 | 102 | grab-merge | 91 | grab-merge |
132 | 103 | harvest | 92 | harvest |
133 | 104 | hugdaylist | 93 | hugdaylist |
134 | @@ -108,7 +97,6 @@ | |||
135 | 108 | syncpackage | 97 | syncpackage |
136 | 109 | Copyright: 2010, Benjamin Drung <bdrung@ubuntu.com> | 98 | Copyright: 2010, Benjamin Drung <bdrung@ubuntu.com> |
137 | 110 | 2007-2011, Canonical Ltd. | 99 | 2007-2011, Canonical Ltd. |
138 | 111 | 2010, Dustin Kirkland <kirkland@ubuntu.com> | ||
139 | 112 | 2008, Jonathan Patrick Davies <jpds@ubuntu.com> | 100 | 2008, Jonathan Patrick Davies <jpds@ubuntu.com> |
140 | 113 | 2008-2010, Martin Pitt <martin.pitt@canonical.com> | 101 | 2008-2010, Martin Pitt <martin.pitt@canonical.com> |
141 | 114 | 2009, Siegfried-Angel Gevatter Pujals <rainct@ubuntu.com> | 102 | 2009, Siegfried-Angel Gevatter Pujals <rainct@ubuntu.com> |
142 | @@ -130,14 +118,12 @@ | |||
143 | 130 | doc/dch-repeat.1 | 118 | doc/dch-repeat.1 |
144 | 131 | doc/get-build-deps.1 | 119 | doc/get-build-deps.1 |
145 | 132 | doc/grep-merges.1 | 120 | doc/grep-merges.1 |
146 | 133 | doc/lp-list-bugs.1 | ||
147 | 134 | doc/mk-sbuild.1 | 121 | doc/mk-sbuild.1 |
148 | 135 | doc/pull-lp-source.1 | 122 | doc/pull-lp-source.1 |
149 | 136 | doc/pull-revu-source.1 | 123 | doc/pull-revu-source.1 |
150 | 137 | doc/ubuntu-build.1 | 124 | doc/ubuntu-build.1 |
151 | 138 | get-build-deps | 125 | get-build-deps |
152 | 139 | grep-merges | 126 | grep-merges |
153 | 140 | lp-list-bugs | ||
154 | 141 | mk-sbuild | 127 | mk-sbuild |
155 | 142 | pull-lp-source | 128 | pull-lp-source |
156 | 143 | pull-revu-source | 129 | pull-revu-source |
157 | 144 | 130 | ||
158 | === removed file 'doc/get-branches.1' | |||
159 | --- doc/get-branches.1 2010-12-02 23:06:43 +0000 | |||
160 | +++ doc/get-branches.1 1970-01-01 00:00:00 +0000 | |||
161 | @@ -1,47 +0,0 @@ | |||
162 | 1 | .TH get\-branches "1" "11 August 2008" "ubuntu-dev-tools" | ||
163 | 2 | .SH NAME | ||
164 | 3 | get\-branches - downloads all branches related to a Launchpad team or person | ||
165 | 4 | |||
166 | 5 | .SH SYNOPSIS | ||
167 | 6 | .B get\-branches | ||
168 | 7 | .RB [ \-d | ||
169 | 8 | .IR directory ] | ||
170 | 9 | .RB [ \-o | ||
171 | 10 | .BR branch | checkout ] | ||
172 | 11 | .B \-t | ||
173 | 12 | .I team | ||
174 | 13 | .br | ||
175 | 14 | .B get\-branches | ||
176 | 15 | .I team | ||
177 | 16 | .br | ||
178 | 17 | .B get\-branches \-\-help | ||
179 | 18 | |||
180 | 19 | .SH DESCRIPTION | ||
181 | 20 | \fBget\-branches\fR uses the LP API to get a list of branches for a person or | ||
182 | 21 | team and calls Bazaar to download all branches. | ||
183 | 22 | |||
184 | 23 | .SH OPTIONS | ||
185 | 24 | Listed below are the command line options for \fBget\-branches\fR: | ||
186 | 25 | .TP | ||
187 | 26 | .BR \-h ", " \-\-help | ||
188 | 27 | Display a help message and exit. | ||
189 | 28 | .TP | ||
190 | 29 | .BR \-d ", " \-\-directory | ||
191 | 30 | Download branches to a directory other than the current directory. | ||
192 | 31 | .TP | ||
193 | 32 | .BR \-o ", " \-\-operation | ||
194 | 33 | Specifies which Bazaar operation to use when downloading the branches; may be | ||
195 | 34 | either \fIbranch\fR or \fIcheckout\fR. | ||
196 | 35 | .TP | ||
197 | 36 | .BR \-t ", " \-\-team | ||
198 | 37 | Specifies which Launchpad team/person to download branches from. | ||
199 | 38 | This option is required. | ||
200 | 39 | |||
201 | 40 | .SH AUTHORS | ||
202 | 41 | \fBget\-branches\fR was written by Daniel Holbach <daniel.holbach@ubuntu.com>, | ||
203 | 42 | and this manual page was written by Jonathan Patrick Davies <jpds@ubuntu.com>. | ||
204 | 43 | .PP | ||
205 | 44 | Both are released under the terms of the GNU General Public License, version 3. | ||
206 | 45 | |||
207 | 46 | .SH SEE ALSO | ||
208 | 47 | .B bzr(1) | ||
209 | 48 | 0 | ||
210 | === removed file 'doc/grab-attachments.1' | |||
211 | --- doc/grab-attachments.1 2011-06-16 19:02:04 +0000 | |||
212 | +++ doc/grab-attachments.1 1970-01-01 00:00:00 +0000 | |||
213 | @@ -1,57 +0,0 @@ | |||
214 | 1 | .TH GRAB\-ATTACHMENTS "1" "10 August 2008" "ubuntu-dev-tools" | ||
215 | 2 | .SH NAME | ||
216 | 3 | grab\-attachments \- downloads attachments from a Launchpad bug | ||
217 | 4 | .SH SYNOPSIS | ||
218 | 5 | .B grab\-attachments\fR [\fIoptions\fR] \fIbug-number\fR... | ||
219 | 6 | .br | ||
220 | 7 | .B grab\-attachments \-h | ||
221 | 8 | .SH DESCRIPTION | ||
222 | 9 | \fBgrab\-attachments\fR is a script to download all attachments from a | ||
223 | 10 | Launchpad bug report or bug reports with a source package task into | ||
224 | 11 | a directory named after the bug e.g. bug-1. | ||
225 | 12 | |||
226 | 13 | .SH OPTIONS | ||
227 | 14 | Listed below are the command line options for grab\-attachments: | ||
228 | 15 | .TP | ||
229 | 16 | .I bug-number | ||
230 | 17 | Specifies the Launchpad bug number that the script should download | ||
231 | 18 | attachments from. | ||
232 | 19 | .TP | ||
233 | 20 | .BR \-h ", " \-\-help | ||
234 | 21 | Display a help message and exit. | ||
235 | 22 | .TP | ||
236 | 23 | .B \-l \fIINSTANCE\fR, \fB\-\-lpinstance\fR=\fIINSTANCE\fR | ||
237 | 24 | Use the specified instance of Launchpad (e.g. "staging"), instead of | ||
238 | 25 | the default of "production". | ||
239 | 26 | .TP | ||
240 | 27 | .B \-\-no\-conf | ||
241 | 28 | Do not read any configuration files, or configuration from environment | ||
242 | 29 | variables. | ||
243 | 30 | .TP | ||
244 | 31 | .BR \-d ", " \-\-duplicates | ||
245 | 32 | Download attachments from duplicates too. | ||
246 | 33 | .TP | ||
247 | 34 | .B \-p \fISRCPACKAGE\fR, \fB\-\-package\fR=\fISRCPACKAGE\fR | ||
248 | 35 | Download attachments from all bugs with a task for this source | ||
249 | 36 | package. | ||
250 | 37 | .SH ENVIRONMENT | ||
251 | 38 | All of the \fBCONFIGURATION VARIABLES\fR below are also supported as | ||
252 | 39 | environment variables. | ||
253 | 40 | Variables in the environment take precedence to those in configuration | ||
254 | 41 | files. | ||
255 | 42 | .SH CONFIGURATION VARIABLES | ||
256 | 43 | The following variables can be set in the environment or in | ||
257 | 44 | .BR ubuntu\-dev\-tools (5) | ||
258 | 45 | configuration files. | ||
259 | 46 | In each case, the script\-specific variable takes precedence over the | ||
260 | 47 | package\-wide variable. | ||
261 | 48 | .TP | ||
262 | 49 | .BR GRAB_ATTACHMENTS_LPINSTANCE ", " UBUNTUTOOLS_LPINSTANCE | ||
263 | 50 | The default value for \fB--lpinstance\fR. | ||
264 | 51 | .SH SEE ALSO | ||
265 | 52 | .BR ubuntu\-dev\-tools (5) | ||
266 | 53 | .SH AUTHOR | ||
267 | 54 | \fBgrab\-attachments\fR was written by Daniel Holbach and this manual page | ||
268 | 55 | was written by Jonathan Patrick Davies. | ||
269 | 56 | .PP | ||
270 | 57 | Both are released under the GNU General Public License, version 2. | ||
271 | 58 | 0 | ||
272 | === removed file 'doc/lp-list-bugs.1' | |||
273 | --- doc/lp-list-bugs.1 2010-09-17 11:45:52 +0000 | |||
274 | +++ doc/lp-list-bugs.1 1970-01-01 00:00:00 +0000 | |||
275 | @@ -1,27 +0,0 @@ | |||
276 | 1 | .TH lp\-list\-bugs 1 2010-09-17 ubuntu-dev-tools | ||
277 | 2 | .SH NAME | ||
278 | 3 | lp\-list\-bugs \- briefly list status of Launchpad bugs | ||
279 | 4 | .SH DESCRIPTION | ||
280 | 5 | .B lp\-list\-bugs | ||
281 | 6 | takes one or more Launchpad bug numbers, and lists the status of each bug in a | ||
282 | 7 | concise format. | ||
283 | 8 | For example: | ||
284 | 9 | .PP | ||
285 | 10 | .RS | ||
286 | 11 | .nf | ||
287 | 12 | $ lp\-list\-bugs 3 | ||
288 | 13 | Bug 3: Custom information for each translation team | ||
289 | 14 | rosetta: Fix Released | ||
290 | 15 | ubuntu: Invalid | ||
291 | 16 | mono (Ubuntu): Invalid | ||
292 | 17 | .fi | ||
293 | 18 | .RE | ||
294 | 19 | .SH OPTIONS | ||
295 | 20 | .TP | ||
296 | 21 | .BR \-h ", " \-\-help | ||
297 | 22 | Display a help message and exit. | ||
298 | 23 | .SH AUTHORS | ||
299 | 24 | .B lp\-list\-bugs | ||
300 | 25 | and this manual page were written by Colin Watson <cjwatson@ubuntu.com>. | ||
301 | 26 | Both are released under the terms of the GNU General Public License, version | ||
302 | 27 | 3 or later. | ||
303 | 28 | 0 | ||
304 | === removed file 'doc/lp-project-upload.1' | |||
305 | --- doc/lp-project-upload.1 2011-06-02 22:30:20 +0000 | |||
306 | +++ doc/lp-project-upload.1 1970-01-01 00:00:00 +0000 | |||
307 | @@ -1,24 +0,0 @@ | |||
308 | 1 | .TH lp-project-upload "1" "05 September 2009" "ubuntu-dev-tools" | ||
309 | 2 | .SH NAME | ||
310 | 3 | lp\-project\-upload \- Upload a release tarball to a Launchpad project. | ||
311 | 4 | |||
312 | 5 | .SH SYNOPSIS | ||
313 | 6 | .B lp\-project\-upload | ||
314 | 7 | .I <project name> <version> <tarball> [new milestone] [changelog file] [releasenotes file] | ||
315 | 8 | |||
316 | 9 | .SH DESCRIPTION | ||
317 | 10 | \fBlp\-project\-upload\fR uploads a tarball release of a project to Launchpad. | ||
318 | 11 | It can create milestones and releases on the fly after confirmation. | ||
319 | 12 | |||
320 | 13 | If there is a file \fItarball\fB.asc\fR, it is uploaded as the signature of the | ||
321 | 14 | tarball. | ||
322 | 15 | |||
323 | 16 | You can optionally provide the name of the next milestone, which will be created if specified. | ||
324 | 17 | |||
325 | 18 | You can optionally provide filename(s) specifying the changelog and release notes entries for this release. Note that these might be /dev/null, if you do not want to provide changelog or release notes information. If these are not specified, an interactive editor will allow you to compose these. | ||
326 | 19 | |||
327 | 20 | .SH AUTHORS | ||
328 | 21 | \fBlp\-project\-upload\fR was written by Martin Pitt <martin.pitt@ubuntu.com> and enhanced by Dustin Kirkland <kirkland@ubuntu.com>. | ||
329 | 22 | .PP | ||
330 | 23 | It is released under the terms of the GNU General Public License, version 2 | ||
331 | 24 | or (at your option) any later version. | ||
332 | 25 | 0 | ||
333 | === removed file 'doc/lp-set-dup.1' | |||
334 | --- doc/lp-set-dup.1 2010-12-22 20:57:02 +0000 | |||
335 | +++ doc/lp-set-dup.1 1970-01-01 00:00:00 +0000 | |||
336 | @@ -1,56 +0,0 @@ | |||
337 | 1 | .TH lp\-set\-dup "1" "March 6 2010" "ubuntu-dev-tools" | ||
338 | 2 | .SH NAME | ||
339 | 3 | lp\-set\-dup \- mark one or more bugs as duplicate of another bug | ||
340 | 4 | |||
341 | 5 | .SH SYNOPSIS | ||
342 | 6 | .B lp\-set\-dup \fR[\fB\-f\fR] <\fImain bug\fR> <\fIduplicate bug\fR> | ||
343 | 7 | [<\fIduplicate bug\fR> ...] | ||
344 | 8 | .br | ||
345 | 9 | .B lp\-set\-dup \-\-help | ||
346 | 10 | |||
347 | 11 | .SH DESCRIPTION | ||
348 | 12 | \fBlp\-set\-dup\fR allow to easily mark one or more bug as duplicate of | ||
349 | 13 | another bug. It checks for permission to operate on a given bug first, | ||
350 | 14 | then perform required tasks on Launchpad. | ||
351 | 15 | |||
352 | 16 | .SH OPTIONS | ||
353 | 17 | Listed below are the command line options for \fBlp\-set\-dup\fR: | ||
354 | 18 | .TP | ||
355 | 19 | .BR \-h ", " \-\-help | ||
356 | 20 | Display a help message and exit. | ||
357 | 21 | .TP | ||
358 | 22 | .B \-f | ||
359 | 23 | Skip confirmation prompt. | ||
360 | 24 | .TP | ||
361 | 25 | .B \-l \fIINSTANCE\fR, \fB\-\-lpinstance\fR=\fIINSTANCE\fR | ||
362 | 26 | Use the specified instance of Launchpad (e.g. "staging"), instead of | ||
363 | 27 | the default of "production". | ||
364 | 28 | .TP | ||
365 | 29 | .B \-\-no\-conf | ||
366 | 30 | Do not read any configuration files, or configuration from environment | ||
367 | 31 | variables. | ||
368 | 32 | |||
369 | 33 | .SH ENVIRONMENT | ||
370 | 34 | All of the \fBCONFIGURATION VARIABLES\fR below are also supported as | ||
371 | 35 | environment variables. | ||
372 | 36 | Variables in the environment take precedence to those in configuration | ||
373 | 37 | files. | ||
374 | 38 | |||
375 | 39 | .SH CONFIGURATION VARIABLES | ||
376 | 40 | The following variables can be set in the environment or in | ||
377 | 41 | .BR ubuntu\-dev\-tools (5) | ||
378 | 42 | configuration files. | ||
379 | 43 | In each case, the script\-specific variable takes precedence over the | ||
380 | 44 | package\-wide variable. | ||
381 | 45 | .TP | ||
382 | 46 | .BR LP_SET_DUP_LPINSTANCE ", " UBUNTUTOOLS_LPINSTANCE | ||
383 | 47 | The default value for \fB--lpinstance\fR. | ||
384 | 48 | |||
385 | 49 | .SH SEE ALSO | ||
386 | 50 | .BR ubuntu\-dev\-tools (5) | ||
387 | 51 | |||
388 | 52 | .SH AUTHORS | ||
389 | 53 | \fBlp\-set\-dup\fR was written by LoĂ¯c Minier <lool@dooz.org>, | ||
390 | 54 | and this manual page was written by Luca Falavigna <dktrkranz@debian.org>. | ||
391 | 55 | .PP | ||
392 | 56 | Both are released under the terms of the GNU General Public License, version 2. | ||
393 | 57 | 0 | ||
394 | === removed file 'doc/lp-shell.1' | |||
395 | --- doc/lp-shell.1 2011-08-14 16:54:53 +0000 | |||
396 | +++ doc/lp-shell.1 1970-01-01 00:00:00 +0000 | |||
397 | @@ -1,52 +0,0 @@ | |||
398 | 1 | .TH lp-shell "1" "27 March 2010" "ubuntu-dev-tools" | ||
399 | 2 | .SH NAME | ||
400 | 3 | lp\-shell \- Open an interactive launchpadlib shell. | ||
401 | 4 | |||
402 | 5 | .SH SYNOPSIS | ||
403 | 6 | .B lp\-shell | ||
404 | 7 | .RB [ \-a ] | ||
405 | 8 | .RB [ \-\-python ] | ||
406 | 9 | .RB [ \-\-ipython ] | ||
407 | 10 | .RI [ service ] | ||
408 | 11 | .RI [ "LP API version" ] | ||
409 | 12 | |||
410 | 13 | .SH DESCRIPTION | ||
411 | 14 | .B lp\-shell | ||
412 | 15 | opens an interactive Python shell with a launchpadlib.Launchpad object "lp" | ||
413 | 16 | which is ready for use. | ||
414 | 17 | |||
415 | 18 | It authenticates against Launchpad with the consumer name "udt-lp-shell". When | ||
416 | 19 | using \fBlp\-shell\fR with the \fB\-a\fR option it will use the anonymous login | ||
417 | 20 | from launchpadlib.Launchpad. | ||
418 | 21 | |||
419 | 22 | By default \fBlp\-shell\fR connects to the "\fIproduction\fR" Launchpad service | ||
420 | 23 | using the "\fI1.0\fR" LP API version. | ||
421 | 24 | |||
422 | 25 | If you want to connect to another Launchpad service, call \fBlp\-shell\fR with | ||
423 | 26 | the service name as the second argument. \fBlp\-shell\fR supports all services | ||
424 | 27 | known by launchpadlib Python module. | ||
425 | 28 | Currently known are (list can be incomplete or outdated): "production", | ||
426 | 29 | "staging", "dogfood". | ||
427 | 30 | |||
428 | 31 | A different LP API version can be selected by passing the API version to use as | ||
429 | 32 | the third argument. Current supported are: "beta", "1.0" and "devel". | ||
430 | 33 | |||
431 | 34 | .SH OPTIONS | ||
432 | 35 | .TP | ||
433 | 36 | .B \-a | ||
434 | 37 | Login anonymously into Launchpad. | ||
435 | 38 | |||
436 | 39 | .TP | ||
437 | 40 | .B \-\-ipython | ||
438 | 41 | Use an ipython shell if available (default). | ||
439 | 42 | |||
440 | 43 | .TP | ||
441 | 44 | .B \-\-python | ||
442 | 45 | Use a regular python shell. | ||
443 | 46 | |||
444 | 47 | .SH AUTHORS | ||
445 | 48 | .B lp\-shell | ||
446 | 49 | was written by Martin Pitt <martin.pitt@ubuntu.com>. | ||
447 | 50 | .PP | ||
448 | 51 | It is released under the terms of the GNU General Public License, version 2 | ||
449 | 52 | or (at your option) any later version. | ||
450 | 53 | 0 | ||
451 | === removed file 'get-branches' | |||
452 | --- get-branches 2011-05-24 18:22:37 +0000 | |||
453 | +++ get-branches 1970-01-01 00:00:00 +0000 | |||
454 | @@ -1,118 +0,0 @@ | |||
455 | 1 | #!/usr/bin/python | ||
456 | 2 | # -*- coding: utf-8 -*- | ||
457 | 3 | # | ||
458 | 4 | # Copyright (C) 2007 Canonical Ltd. | ||
459 | 5 | # Created by Daniel Holbach <daniel.holbach@ubuntu.com> | ||
460 | 6 | # Modified by Jonathan Patrick Davies <jpds@ubuntu.com> | ||
461 | 7 | # | ||
462 | 8 | # ################################################################## | ||
463 | 9 | # | ||
464 | 10 | # This program is free software; you can redistribute it and/or | ||
465 | 11 | # modify it under the terms of the GNU General Public License | ||
466 | 12 | # as published by the Free Software Foundation; version 3. | ||
467 | 13 | # | ||
468 | 14 | # This program is distributed in the hope that it will be useful, | ||
469 | 15 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
470 | 16 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
471 | 17 | # GNU General Public License for more details. | ||
472 | 18 | # | ||
473 | 19 | # See file /usr/share/common-licenses/GPL-3 for more details. | ||
474 | 20 | # | ||
475 | 21 | # ################################################################## | ||
476 | 22 | # | ||
477 | 23 | # This script is used to checkout or branch all the Bazaar branches | ||
478 | 24 | # of a Launchpad team. | ||
479 | 25 | # | ||
480 | 26 | |||
481 | 27 | import os | ||
482 | 28 | import sys | ||
483 | 29 | from optparse import OptionParser | ||
484 | 30 | from ubuntutools.lp.lpapicache import PersonTeam | ||
485 | 31 | from ubuntutools import subprocess | ||
486 | 32 | |||
487 | 33 | def main(): | ||
488 | 34 | usage = "Usage: %prog [-d <directory>] -t <team> [-o <operation>]" | ||
489 | 35 | usage += "\nUsage: %prog <team>" | ||
490 | 36 | opt_parser = OptionParser(usage) | ||
491 | 37 | |||
492 | 38 | # Our options. | ||
493 | 39 | opt_parser.add_option("-d", "--directory", action="store", type="string", | ||
494 | 40 | dest="directory", default=os.getcwd(), | ||
495 | 41 | help="Directory to download branches to.") | ||
496 | 42 | opt_parser.add_option("-t", "--team", action="store", type="string", | ||
497 | 43 | dest="lpteam", | ||
498 | 44 | help="Launchpad team to download branches from.") | ||
499 | 45 | opt_parser.add_option("-o", "--operation", action="store", type="string", | ||
500 | 46 | dest="operation", default="branch", | ||
501 | 47 | help="Whether to branch or checkout the Bazaar " | ||
502 | 48 | "branches. May be either 'branch' or " | ||
503 | 49 | "'checkout'.") | ||
504 | 50 | |||
505 | 51 | (options, args) = opt_parser.parse_args() | ||
506 | 52 | |||
507 | 53 | # Fetch our current directory to return to later. | ||
508 | 54 | pwd = os.getcwd() | ||
509 | 55 | |||
510 | 56 | # Parse our options. | ||
511 | 57 | if len(args) != 1 and options.lpteam == None: | ||
512 | 58 | opt_parser.error("No team has been specified.") | ||
513 | 59 | |||
514 | 60 | # Dictionary settings. | ||
515 | 61 | directory = options.directory | ||
516 | 62 | if not os.path.isdir(directory): # Check that it is a directory. | ||
517 | 63 | opt_parser.error("%s is not a valid directory." % directory) | ||
518 | 64 | os.chdir(directory) | ||
519 | 65 | |||
520 | 66 | # Type of Bazaar operation to perform. | ||
521 | 67 | operation_type = options.operation.lower() | ||
522 | 68 | if operation_type not in ("branch", "checkout"): | ||
523 | 69 | opt_parser.error("Invalid operation '%s' for '-o' flag." % \ | ||
524 | 70 | operation_type) | ||
525 | 71 | |||
526 | 72 | # Launchpad team setting. | ||
527 | 73 | if options.lpteam: | ||
528 | 74 | team = options.lpteam.lower() | ||
529 | 75 | if args: | ||
530 | 76 | team = args[0].lower() | ||
531 | 77 | try: | ||
532 | 78 | team = PersonTeam(team) | ||
533 | 79 | except KeyError: | ||
534 | 80 | print >> sys.stderr, "E: The team '%s' doesn't exist." % team | ||
535 | 81 | |||
536 | 82 | # Get a list of branches | ||
537 | 83 | branches = team.getBranches() | ||
538 | 84 | |||
539 | 85 | print "Downloading all branches for the '%s' team. This may take some " \ | ||
540 | 86 | "time." % team.display_name | ||
541 | 87 | |||
542 | 88 | try: | ||
543 | 89 | os.makedirs(team.name) | ||
544 | 90 | except: | ||
545 | 91 | pass | ||
546 | 92 | |||
547 | 93 | os.chdir(team.name) | ||
548 | 94 | |||
549 | 95 | for branch in branches: | ||
550 | 96 | project_name = branch.project.name | ||
551 | 97 | if not os.path.exists(project_name): | ||
552 | 98 | os.makedirs(project_name) | ||
553 | 99 | os.chdir(project_name) | ||
554 | 100 | |||
555 | 101 | if not os.path.exists(branch.name): | ||
556 | 102 | print "Branching %s ..." % branch.display_name | ||
557 | 103 | cmd = ["bzr", operation_type, branch.bzr_identity, branch.name] | ||
558 | 104 | subprocess.call(cmd) | ||
559 | 105 | else: | ||
560 | 106 | print "Merging %s ..." % branch.display_name | ||
561 | 107 | os.chdir(branch.name) | ||
562 | 108 | subprocess.call(["bzr", "merge", "--pull", "--remember"]) | ||
563 | 109 | os.chdir(os.path.join(directory, team.name)) | ||
564 | 110 | |||
565 | 111 | os.chdir(pwd) | ||
566 | 112 | sys.exit(0) | ||
567 | 113 | |||
568 | 114 | if __name__ == "__main__": | ||
569 | 115 | try: | ||
570 | 116 | main() | ||
571 | 117 | except KeyboardInterrupt: | ||
572 | 118 | print "Operation was interrupted by user." | ||
573 | 119 | 0 | ||
574 | === removed file 'grab-attachments' | |||
575 | --- grab-attachments 2011-06-21 16:25:15 +0000 | |||
576 | +++ grab-attachments 1970-01-01 00:00:00 +0000 | |||
577 | @@ -1,107 +0,0 @@ | |||
578 | 1 | #!/usr/bin/python | ||
579 | 2 | # | ||
580 | 3 | # Copyright (C) 2007, Canonical Ltd. | ||
581 | 4 | # Written by Daniel Holbach, | ||
582 | 5 | # Stefano Rivera, | ||
583 | 6 | # Brian Murray | ||
584 | 7 | # | ||
585 | 8 | # ################################################################## | ||
586 | 9 | # | ||
587 | 10 | # This program is free software; you can redistribute it and/or | ||
588 | 11 | # modify it under the terms of the GNU General Public License | ||
589 | 12 | # as published by the Free Software Foundation; version 3. | ||
590 | 13 | # | ||
591 | 14 | # This program is distributed in the hope that it will be useful, | ||
592 | 15 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
593 | 16 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
594 | 17 | # GNU General Public License for more details. | ||
595 | 18 | # | ||
596 | 19 | # See file /usr/share/common-licenses/GPL-3 for more details. | ||
597 | 20 | # | ||
598 | 21 | # ################################################################## | ||
599 | 22 | |||
600 | 23 | from optparse import OptionParser | ||
601 | 24 | import errno | ||
602 | 25 | import os | ||
603 | 26 | import sys | ||
604 | 27 | |||
605 | 28 | from launchpadlib.launchpad import Launchpad | ||
606 | 29 | |||
607 | 30 | from ubuntutools.config import UDTConfig | ||
608 | 31 | |||
609 | 32 | USAGE = "grab-attachments <bug numbers>" | ||
610 | 33 | |||
611 | 34 | |||
612 | 35 | def download_attachments(bug): | ||
613 | 36 | |||
614 | 37 | bug_folder_name = 'bug-%s' % bug.id | ||
615 | 38 | |||
616 | 39 | try: | ||
617 | 40 | os.mkdir(bug_folder_name) | ||
618 | 41 | except OSError, error: | ||
619 | 42 | if error.errno == errno.EEXIST: | ||
620 | 43 | return | ||
621 | 44 | |||
622 | 45 | for attachment in bug.attachments: | ||
623 | 46 | f = attachment.data.open() | ||
624 | 47 | filename = os.path.join(os.getcwd(), bug_folder_name, f.filename) | ||
625 | 48 | local_file = open(filename, "w") | ||
626 | 49 | local_file.write(f.read()) | ||
627 | 50 | f.close() | ||
628 | 51 | local_file.close() | ||
629 | 52 | |||
630 | 53 | |||
631 | 54 | def main(): | ||
632 | 55 | parser = OptionParser('Usage: %prog [options] <bug numbers>') | ||
633 | 56 | parser.add_option('-l', '--lpinstance', metavar='INSTANCE', | ||
634 | 57 | dest='lpinstance', default=None, | ||
635 | 58 | help='Launchpad instance to connect to ' | ||
636 | 59 | '(default: production)') | ||
637 | 60 | parser.add_option('--no-conf', | ||
638 | 61 | dest='no_conf', default=False, action='store_true', | ||
639 | 62 | help="Don't read config files or environment variables") | ||
640 | 63 | parser.add_option('-d', '--duplicates', default=False, | ||
641 | 64 | action='store_true', | ||
642 | 65 | help='Download attachments from duplicates too') | ||
643 | 66 | parser.add_option('-p', '--package', | ||
644 | 67 | help='Download attachments from all bugs with a ' | ||
645 | 68 | 'task for this source package') | ||
646 | 69 | |||
647 | 70 | opts, args = parser.parse_args() | ||
648 | 71 | if len(args) < 1 and not opts.package: | ||
649 | 72 | parser.error('No bug numbers provided') | ||
650 | 73 | config = UDTConfig(opts.no_conf) | ||
651 | 74 | if opts.lpinstance is None: | ||
652 | 75 | opts.lpinstance = config.get_value('LPINSTANCE') | ||
653 | 76 | |||
654 | 77 | try: | ||
655 | 78 | launchpad = Launchpad.login_with("ubuntu-dev-tools", opts.lpinstance) | ||
656 | 79 | |||
657 | 80 | if opts.package: | ||
658 | 81 | ubuntu = launchpad.projects['ubuntu'] | ||
659 | 82 | src_package = ubuntu.getSourcePackage(name=opts.package) | ||
660 | 83 | if src_package is None: | ||
661 | 84 | parser.error('Unable to find package %s' % opts.package) | ||
662 | 85 | for task in src_package.searchTasks(): | ||
663 | 86 | args.append(task.bug.id) | ||
664 | 87 | |||
665 | 88 | for arg in args: | ||
666 | 89 | try: | ||
667 | 90 | bug_number = int(arg) | ||
668 | 91 | except ValueError: | ||
669 | 92 | parser.error("'%s' is not a valid bug number." % arg) | ||
670 | 93 | |||
671 | 94 | bug = launchpad.bugs[bug_number] | ||
672 | 95 | download_attachments(bug) | ||
673 | 96 | |||
674 | 97 | if opts.duplicates is True: | ||
675 | 98 | for bug in bug.duplicates: | ||
676 | 99 | download_attachments(bug) | ||
677 | 100 | |||
678 | 101 | # no LP credentials | ||
679 | 102 | except IOError, error: | ||
680 | 103 | print error | ||
681 | 104 | sys.exit(1) | ||
682 | 105 | |||
683 | 106 | if __name__ == '__main__': | ||
684 | 107 | main() | ||
685 | 108 | 0 | ||
686 | === removed file 'lp-list-bugs' | |||
687 | --- lp-list-bugs 2011-02-28 22:30:54 +0000 | |||
688 | +++ lp-list-bugs 1970-01-01 00:00:00 +0000 | |||
689 | @@ -1,63 +0,0 @@ | |||
690 | 1 | #! /usr/bin/python | ||
691 | 2 | # -*- coding: UTF-8 -*- | ||
692 | 3 | """Briefly list status of Launchpad bugs.""" | ||
693 | 4 | |||
694 | 5 | # Copyright (c) 2010 Canonical Ltd. | ||
695 | 6 | # | ||
696 | 7 | # lp-set-dup is free software; you can redistribute it and/or modify it | ||
697 | 8 | # under the terms of the GNU General Public License as published by the | ||
698 | 9 | # Free Software Foundation; either version 3, or (at your option) any | ||
699 | 10 | # later version. | ||
700 | 11 | # | ||
701 | 12 | # lp-set-dup is distributed in the hope that it will be useful, but | ||
702 | 13 | # WITHOUT ANY WARRANTY; without even the implied warranty of | ||
703 | 14 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
704 | 15 | # General Public License for more details. | ||
705 | 16 | # | ||
706 | 17 | # You should have received a copy of the GNU General Public License | ||
707 | 18 | # along with lp-set-dup; see the file COPYING. If not, write to the Free | ||
708 | 19 | # Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA | ||
709 | 20 | # 02110-1301, USA. | ||
710 | 21 | # | ||
711 | 22 | # Authors: | ||
712 | 23 | # Colin Watson <cjwatson@ubuntu.com> | ||
713 | 24 | |||
714 | 25 | import sys | ||
715 | 26 | from optparse import OptionParser | ||
716 | 27 | |||
717 | 28 | from launchpadlib.launchpad import Launchpad | ||
718 | 29 | from launchpadlib.errors import HTTPError | ||
719 | 30 | |||
720 | 31 | def main(): | ||
721 | 32 | usage = "Usage: %prog <bug> [...]" | ||
722 | 33 | parser = OptionParser(usage) | ||
723 | 34 | args = parser.parse_args()[1] | ||
724 | 35 | if len(args) < 1: | ||
725 | 36 | parser.error("Need at least one bug number") | ||
726 | 37 | |||
727 | 38 | try: | ||
728 | 39 | launchpad = Launchpad.login_with('ubuntu-dev-tools', 'production') | ||
729 | 40 | except Exception, error: | ||
730 | 41 | print >> sys.stderr, 'Could not connect to Launchpad:', str(error) | ||
731 | 42 | sys.exit(2) | ||
732 | 43 | |||
733 | 44 | for bugnum in args: | ||
734 | 45 | try: | ||
735 | 46 | bug = launchpad.bugs[bugnum] | ||
736 | 47 | print "Bug %s: %s" % (bugnum, bug.title) | ||
737 | 48 | for task in bug.bug_tasks: | ||
738 | 49 | print " %s: %s" % (task.bug_target_name, task.status) | ||
739 | 50 | except HTTPError, error: | ||
740 | 51 | if error.response.status == 401: | ||
741 | 52 | print >> sys.stderr, \ | ||
742 | 53 | ("E: Don't have enough permissions to access bug %s" % | ||
743 | 54 | bugnum) | ||
744 | 55 | print >> sys.stderr, error.content | ||
745 | 56 | continue | ||
746 | 57 | elif error.response.status == 404: | ||
747 | 58 | print >> sys.stderr, "E: Bug %s not found" % bugnum | ||
748 | 59 | else: | ||
749 | 60 | raise | ||
750 | 61 | |||
751 | 62 | if __name__ == '__main__': | ||
752 | 63 | main() | ||
753 | 64 | 0 | ||
754 | === removed file 'lp-project-upload' | |||
755 | --- lp-project-upload 2011-06-24 14:32:07 +0000 | |||
756 | +++ lp-project-upload 1970-01-01 00:00:00 +0000 | |||
757 | @@ -1,178 +0,0 @@ | |||
758 | 1 | #!/usr/bin/python | ||
759 | 2 | |||
760 | 3 | # Copyright (c) 2009 Canonical Ltd. | ||
761 | 4 | # | ||
762 | 5 | # This program is free software; you can redistribute it and/or modify it | ||
763 | 6 | # under the terms of the GNU General Public License as published by the | ||
764 | 7 | # Free Software Foundation; either version 2, or (at your option) any | ||
765 | 8 | # later version. | ||
766 | 9 | # | ||
767 | 10 | # lp-project-upload is distributed in the hope that it will be useful, but | ||
768 | 11 | # WITHOUT ANY WARRANTY; without even the implied warranty of | ||
769 | 12 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
770 | 13 | # General Public License for more details. | ||
771 | 14 | |||
772 | 15 | # Authors: | ||
773 | 16 | # Martin Pitt <martin.pitt@ubuntu.com>, based on | ||
774 | 17 | # http://blog.launchpad.net/api/recipe-for-uploading-files-via-the-api | ||
775 | 18 | # Dustin Kirkland <kirkland@ubuntu.com> | ||
776 | 19 | # - support files for changelog and release notes | ||
777 | 20 | |||
778 | 21 | '''Upload a release tarball to a Launchpad project.''' | ||
779 | 22 | |||
780 | 23 | import datetime | ||
781 | 24 | import os | ||
782 | 25 | import sys | ||
783 | 26 | import tempfile | ||
784 | 27 | |||
785 | 28 | from launchpadlib.launchpad import Launchpad | ||
786 | 29 | from launchpadlib.errors import HTTPError | ||
787 | 30 | |||
788 | 31 | from ubuntutools import subprocess | ||
789 | 32 | |||
790 | 33 | def create_release(project, version): | ||
791 | 34 | '''Create new release and milestone for LP project.''' | ||
792 | 35 | |||
793 | 36 | print 'Release %s could not be found for project. Create it? (Y/n)' % \ | ||
794 | 37 | version | ||
795 | 38 | answer = sys.stdin.readline().strip() | ||
796 | 39 | if answer.startswith('n'): | ||
797 | 40 | sys.exit(0) | ||
798 | 41 | |||
799 | 42 | n_series = len(project.series) | ||
800 | 43 | if n_series == 1: | ||
801 | 44 | series = project.series[0] | ||
802 | 45 | elif n_series > 1: | ||
803 | 46 | msg = 'More than one series exist. Which one would you like to ' \ | ||
804 | 47 | 'upload to? Possible series are (listed as index, name):' | ||
805 | 48 | print msg | ||
806 | 49 | for idx, serie in enumerate(project.series): | ||
807 | 50 | print '\t%i - %s' % (idx, serie.name) | ||
808 | 51 | print 'Enter series index: ' | ||
809 | 52 | answer = sys.stdin.readline().strip() | ||
810 | 53 | try: | ||
811 | 54 | series = project.series[int(answer)] | ||
812 | 55 | except (ValueError, IndexError): | ||
813 | 56 | print >> sys.stderr, 'The series index is invalid (%s).' % answer | ||
814 | 57 | sys.exit(3) | ||
815 | 58 | else: | ||
816 | 59 | print "Using series named '%s'" % series.name | ||
817 | 60 | else: | ||
818 | 61 | print >> sys.stderr, ('Does not support creating releases if no ' | ||
819 | 62 | 'series exists.') | ||
820 | 63 | sys.exit(3) | ||
821 | 64 | |||
822 | 65 | release_date = datetime.date.today().strftime('%Y-%m-%d') | ||
823 | 66 | milestone = series.newMilestone(name=version, | ||
824 | 67 | date_targeted=release_date) | ||
825 | 68 | return milestone.createProductRelease(date_released=release_date) | ||
826 | 69 | |||
827 | 70 | def edit_file(prefix, description): | ||
828 | 71 | (fd, f) = tempfile.mkstemp(prefix=prefix+'.') | ||
829 | 72 | os.write(fd, '\n\n#------\n# Please enter the %s here. ' | ||
830 | 73 | 'Lines which start with "#" are ignored.\n' % description) | ||
831 | 74 | os.close(fd) | ||
832 | 75 | subprocess.call(['sensible-editor', f]) | ||
833 | 76 | return cat_file(f) | ||
834 | 77 | |||
835 | 78 | def cat_file(f): | ||
836 | 79 | content = '' | ||
837 | 80 | for line in open(f): | ||
838 | 81 | if line.startswith('#'): | ||
839 | 82 | continue | ||
840 | 83 | content += line | ||
841 | 84 | return content.strip() | ||
842 | 85 | |||
843 | 86 | def main(): | ||
844 | 87 | if len(sys.argv) < 4 or len(sys.argv) > 7: | ||
845 | 88 | print >> sys.stderr, '''Upload a release tarball to a Launchpad project. | ||
846 | 89 | |||
847 | 90 | Usage: %s <project name> <version> <tarball> [new milestone] [changelog file] [releasenotes file]''' % sys.argv[0] | ||
848 | 91 | sys.exit(1) | ||
849 | 92 | |||
850 | 93 | new_milestone = None | ||
851 | 94 | changelog_file = None | ||
852 | 95 | releasenotes_file = None | ||
853 | 96 | if len(sys.argv) == 4: | ||
854 | 97 | (project, version, tarball) = sys.argv[1:] | ||
855 | 98 | elif len(sys.argv) == 5: | ||
856 | 99 | (project, version, tarball, new_milestone) = sys.argv[1:] | ||
857 | 100 | elif len(sys.argv) == 6: | ||
858 | 101 | (project, version, tarball, new_milestone, changelog_file) = sys.argv[1:] | ||
859 | 102 | elif len(sys.argv) == 7: | ||
860 | 103 | (project, version, tarball, new_milestone, changelog_file, releasenotes_file) = sys.argv[1:] | ||
861 | 104 | |||
862 | 105 | try: | ||
863 | 106 | launchpad = Launchpad.login_with('ubuntu-dev-tools', 'production') | ||
864 | 107 | except Exception, error: | ||
865 | 108 | print >> sys.stderr, 'Could not connect to Launchpad:', str(error) | ||
866 | 109 | sys.exit(2) | ||
867 | 110 | |||
868 | 111 | try: | ||
869 | 112 | # Look up the project using the Launchpad instance. | ||
870 | 113 | proj = launchpad.projects[project] | ||
871 | 114 | # Find the release in the project's releases collection. | ||
872 | 115 | release = None | ||
873 | 116 | for rel in proj.releases: | ||
874 | 117 | if rel.version == version: | ||
875 | 118 | release = rel | ||
876 | 119 | break | ||
877 | 120 | if not release: | ||
878 | 121 | for milestone in proj.all_milestones: | ||
879 | 122 | if milestone.name == version: | ||
880 | 123 | today = datetime.date.today().strftime('%Y-%m-%d') | ||
881 | 124 | release = milestone.createProductRelease(date_released=today) | ||
882 | 125 | if not release: | ||
883 | 126 | release = create_release(proj, version) | ||
884 | 127 | |||
885 | 128 | # Get the file contents. | ||
886 | 129 | file_content = open(tarball, 'r').read() | ||
887 | 130 | # Get the signature, if available. | ||
888 | 131 | signature = tarball + '.asc' | ||
889 | 132 | if not os.path.exists(signature): | ||
890 | 133 | print 'Calling GPG to create tarball signature...' | ||
891 | 134 | cmd = ['gpg', '--armor', '--sign', '--detach-sig', tarball] | ||
892 | 135 | if subprocess.call(cmd) != 0: | ||
893 | 136 | print >> sys.stderr, 'gpg failed, aborting' | ||
894 | 137 | |||
895 | 138 | if os.path.exists(signature): | ||
896 | 139 | signature_content = open(signature, 'r').read() | ||
897 | 140 | else: | ||
898 | 141 | signature_content = None | ||
899 | 142 | |||
900 | 143 | # Create a new product release file. | ||
901 | 144 | filename = os.path.basename(tarball) | ||
902 | 145 | release.add_file(filename=filename, description='release tarball', | ||
903 | 146 | file_content=file_content, content_type='appplication/x-gzip', | ||
904 | 147 | file_type='Code Release Tarball', signature_filename=signature, | ||
905 | 148 | signature_content=signature_content) | ||
906 | 149 | |||
907 | 150 | if changelog_file is not None: | ||
908 | 151 | changelog = cat_file(changelog_file) | ||
909 | 152 | else: | ||
910 | 153 | changelog = edit_file('changelog', 'changelog') | ||
911 | 154 | if changelog: | ||
912 | 155 | release.changelog = changelog | ||
913 | 156 | |||
914 | 157 | if releasenotes_file is not None: | ||
915 | 158 | release_notes = cat_file(releasenotes_file) | ||
916 | 159 | else: | ||
917 | 160 | release_notes = edit_file('releasenotes', 'release notes') | ||
918 | 161 | if release_notes: | ||
919 | 162 | release.release_notes = release_notes | ||
920 | 163 | |||
921 | 164 | release.lp_save() | ||
922 | 165 | |||
923 | 166 | # Create a new milestone if requested | ||
924 | 167 | if new_milestone is not None: | ||
925 | 168 | mil = release.milestone | ||
926 | 169 | for series in proj.series: | ||
927 | 170 | if mil.name in [milestone.name for milestone in series.all_milestones]: | ||
928 | 171 | series.newMilestone(name=new_milestone) | ||
929 | 172 | |||
930 | 173 | except HTTPError, error: | ||
931 | 174 | print 'An error happened in the upload:', error.content | ||
932 | 175 | sys.exit(1) | ||
933 | 176 | |||
934 | 177 | if __name__ == '__main__': | ||
935 | 178 | main() | ||
936 | 179 | 0 | ||
937 | === removed file 'lp-set-dup' | |||
938 | --- lp-set-dup 2011-02-28 22:30:54 +0000 | |||
939 | +++ lp-set-dup 1970-01-01 00:00:00 +0000 | |||
940 | @@ -1,134 +0,0 @@ | |||
941 | 1 | #!/usr/bin/python | ||
942 | 2 | # -*- coding: UTF-8 -*- | ||
943 | 3 | """Sets the "duplicate of" bug of a bug and its dups.""" | ||
944 | 4 | |||
945 | 5 | # Copyright (c) 2009 Canonical Ltd. | ||
946 | 6 | # | ||
947 | 7 | # lp-set-dup is free software; you can redistribute it and/or modify it | ||
948 | 8 | # under the terms of the GNU General Public License as published by the | ||
949 | 9 | # Free Software Foundation; either version 2, or (at your option) any | ||
950 | 10 | # later version. | ||
951 | 11 | # | ||
952 | 12 | # lp-set-dup is distributed in the hope that it will be useful, but | ||
953 | 13 | # WITHOUT ANY WARRANTY; without even the implied warranty of | ||
954 | 14 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
955 | 15 | # General Public License for more details. | ||
956 | 16 | # | ||
957 | 17 | # You should have received a copy of the GNU General Public License | ||
958 | 18 | # along with lp-set-dup; see the file COPYING. If not, write to the Free | ||
959 | 19 | # Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA | ||
960 | 20 | # 02110-1301, USA. | ||
961 | 21 | # | ||
962 | 22 | # Authors: | ||
963 | 23 | # LoĂ¯c Minier <lool@dooz.org> | ||
964 | 24 | |||
965 | 25 | import sys | ||
966 | 26 | from optparse import OptionParser | ||
967 | 27 | |||
968 | 28 | from launchpadlib.launchpad import Launchpad | ||
969 | 29 | from launchpadlib.errors import HTTPError | ||
970 | 30 | |||
971 | 31 | from ubuntutools.config import UDTConfig | ||
972 | 32 | |||
973 | 33 | def die(message): | ||
974 | 34 | print >> sys.stderr, "Fatal: " + message | ||
975 | 35 | sys.exit(1) | ||
976 | 36 | |||
977 | 37 | def main(): | ||
978 | 38 | usage = "Usage: %prog [-f] <new main bug> <bug to dup> [<bug to dup>...]" | ||
979 | 39 | opt_parser = OptionParser(usage) | ||
980 | 40 | opt_parser.add_option("-f", | ||
981 | 41 | help="Skip confirmation prompt", | ||
982 | 42 | dest="force", default=False, action="store_true") | ||
983 | 43 | opt_parser.add_option("-l", "--lpinstance", metavar="INSTANCE", | ||
984 | 44 | help="Launchpad instance to connect to " | ||
985 | 45 | "(default: production)", | ||
986 | 46 | dest="lpinstance", default=None) | ||
987 | 47 | opt_parser.add_option("--no-conf", | ||
988 | 48 | help="Don't read config files or " | ||
989 | 49 | "environment variables.", | ||
990 | 50 | dest="no_conf", default=False, action="store_true") | ||
991 | 51 | (options, args) = opt_parser.parse_args() | ||
992 | 52 | |||
993 | 53 | if len(args) < 2: | ||
994 | 54 | opt_parser.error("Need at least a new main bug and a bug to dup") | ||
995 | 55 | |||
996 | 56 | config = UDTConfig(options.no_conf) | ||
997 | 57 | if options.lpinstance is None: | ||
998 | 58 | options.lpinstance = config.get_value("LPINSTANCE") | ||
999 | 59 | |||
1000 | 60 | launchpad = None | ||
1001 | 61 | try: | ||
1002 | 62 | print "Setting up Launchpad" | ||
1003 | 63 | launchpad = Launchpad.login_with("ubuntu-dev-tools", options.lpinstance) | ||
1004 | 64 | print "Launchpad setup complete" | ||
1005 | 65 | except ImportError: | ||
1006 | 66 | suggestion = "check whether python-launchpadlib is installed" | ||
1007 | 67 | if launchpad is None: | ||
1008 | 68 | die("Couldn't setup Launchpad for the ubuntu-dev-tools consumer; %s" % \ | ||
1009 | 69 | (suggestion, )) | ||
1010 | 70 | |||
1011 | 71 | # check that the new main bug isn't a duplicate | ||
1012 | 72 | try: | ||
1013 | 73 | new_main_bug = launchpad.bugs[args[0]] | ||
1014 | 74 | except HTTPError, error: | ||
1015 | 75 | if error.response.status == 401: | ||
1016 | 76 | print >> sys.stderr, ("E: Don't have enough permissions to access " | ||
1017 | 77 | "bug %s") % (args[0]) | ||
1018 | 78 | die(error.content) | ||
1019 | 79 | else: | ||
1020 | 80 | raise | ||
1021 | 81 | new_main_dup_of = new_main_bug.duplicate_of | ||
1022 | 82 | if new_main_dup_of is not None: | ||
1023 | 83 | answer = None | ||
1024 | 84 | try: | ||
1025 | 85 | answer = raw_input("Bug %s is a duplicate of %s; would you like to " | ||
1026 | 86 | "use %s as the new main bug instead? [y/N]" % \ | ||
1027 | 87 | (new_main_bug.id, new_main_dup_of.id, | ||
1028 | 88 | new_main_dup_of.id)) | ||
1029 | 89 | except: | ||
1030 | 90 | die("Aborted") | ||
1031 | 91 | if answer.lower() not in ("y", "yes"): | ||
1032 | 92 | die("User aborted") | ||
1033 | 93 | new_main_bug = new_main_dup_of | ||
1034 | 94 | |||
1035 | 95 | # build list of bugs to process, first the dups then the bug | ||
1036 | 96 | bugs_to_process = [] | ||
1037 | 97 | for bug_number in args[1:]: | ||
1038 | 98 | print "Processing %s" % (bug_number) | ||
1039 | 99 | try: | ||
1040 | 100 | bug = launchpad.bugs[bug_number] | ||
1041 | 101 | except HTTPError, error: | ||
1042 | 102 | if error.response.status == 401: | ||
1043 | 103 | print >> sys.stderr, ("W: Don't have enough permissions to " | ||
1044 | 104 | "access bug %s") % (bug_number) | ||
1045 | 105 | print >> sys.stderr, "W: %s" % (error.content) | ||
1046 | 106 | continue | ||
1047 | 107 | else: | ||
1048 | 108 | raise | ||
1049 | 109 | dups = bug.duplicates | ||
1050 | 110 | if dups is not None: | ||
1051 | 111 | bugs_to_process.extend(dups) | ||
1052 | 112 | print "Found %i dups for %s" % (len(dups), bug_number) | ||
1053 | 113 | bugs_to_process.append(bug) | ||
1054 | 114 | |||
1055 | 115 | # process dups first, then their main bug | ||
1056 | 116 | print "Would set the following bugs as duplicates of %s: %s" % \ | ||
1057 | 117 | (new_main_bug.id, " ".join([str(b.id) for b in bugs_to_process])) | ||
1058 | 118 | |||
1059 | 119 | if not options.force: | ||
1060 | 120 | answer = None | ||
1061 | 121 | try: | ||
1062 | 122 | answer = raw_input("Proceed? [y/N]") | ||
1063 | 123 | except: | ||
1064 | 124 | die("Aborted") | ||
1065 | 125 | if answer.lower() not in ("y", "yes"): | ||
1066 | 126 | die("User aborted") | ||
1067 | 127 | |||
1068 | 128 | for bug in bugs_to_process: | ||
1069 | 129 | print "Marking bug %s as a duplicate of %s" % (bug.id, new_main_bug.id) | ||
1070 | 130 | bug.duplicate_of = new_main_bug | ||
1071 | 131 | bug.lp_save() | ||
1072 | 132 | |||
1073 | 133 | if __name__ == '__main__': | ||
1074 | 134 | main() | ||
1075 | 135 | 0 | ||
1076 | === removed file 'lp-shell' | |||
1077 | --- lp-shell 2011-08-20 09:31:02 +0000 | |||
1078 | +++ lp-shell 1970-01-01 00:00:00 +0000 | |||
1079 | @@ -1,112 +0,0 @@ | |||
1080 | 1 | #!/usr/bin/python | ||
1081 | 2 | |||
1082 | 3 | # Open an interactive launchpadlib Python shell. | ||
1083 | 4 | # It supports all known LP service instances and API versions. The login | ||
1084 | 5 | # can optionally happen anonymously. | ||
1085 | 6 | |||
1086 | 7 | # Author: Martin Pitt <martin.pitt@ubuntu.com> | ||
1087 | 8 | # Copyright: (C) 2010 Canonical Ltd. | ||
1088 | 9 | # | ||
1089 | 10 | # This package is free software; you can redistribute it and/or modify | ||
1090 | 11 | # it under the terms of the GNU General Public License as published by | ||
1091 | 12 | # the Free Software Foundation, at version 2. | ||
1092 | 13 | # | ||
1093 | 14 | # This package is distributed in the hope that it will be useful, | ||
1094 | 15 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
1095 | 16 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
1096 | 17 | # GNU General Public License for more details. | ||
1097 | 18 | |||
1098 | 19 | import sys | ||
1099 | 20 | import code | ||
1100 | 21 | from optparse import OptionParser | ||
1101 | 22 | |||
1102 | 23 | from launchpadlib.launchpad import Launchpad | ||
1103 | 24 | from launchpadlib.uris import lookup_service_root | ||
1104 | 25 | |||
1105 | 26 | def main(): | ||
1106 | 27 | instance = 'production' | ||
1107 | 28 | valid_api_versions = ('beta', '1.0', 'devel') | ||
1108 | 29 | api_version = '1.0' | ||
1109 | 30 | |||
1110 | 31 | usage = 'Usage: %prog [-a] [instance] [LP API version]' | ||
1111 | 32 | opt_parser = OptionParser(usage) | ||
1112 | 33 | opt_parser.add_option('-a', action='store_true', | ||
1113 | 34 | dest='anonymous', default=False, | ||
1114 | 35 | help='Login anonymously into LP.') | ||
1115 | 36 | opt_parser.add_option('--ipython', action='store_const', | ||
1116 | 37 | dest='shell', const='ipython', default="ipython", | ||
1117 | 38 | help='Use ipython shell (default).') | ||
1118 | 39 | opt_parser.add_option('--python', action='store_const', | ||
1119 | 40 | dest='shell', const='python', | ||
1120 | 41 | help='Use python shell.') | ||
1121 | 42 | |||
1122 | 43 | |||
1123 | 44 | (options, args) = opt_parser.parse_args() | ||
1124 | 45 | |||
1125 | 46 | if len(args) >= 1: | ||
1126 | 47 | try: | ||
1127 | 48 | instance = lookup_service_root(args[0]) | ||
1128 | 49 | except ValueError, err: | ||
1129 | 50 | print 'E: %s' % (err) | ||
1130 | 51 | print 'I: Falling back to "production".' | ||
1131 | 52 | |||
1132 | 53 | if len(args) >= 2: | ||
1133 | 54 | if args[1] in valid_api_versions: | ||
1134 | 55 | api_version = args[1] | ||
1135 | 56 | else: | ||
1136 | 57 | print 'E: "%s" is not a valid LP API version.' % (args[1]) | ||
1137 | 58 | print 'I: Falling back to "1.0".' | ||
1138 | 59 | |||
1139 | 60 | if options.anonymous: | ||
1140 | 61 | launchpad = Launchpad.login_anonymously('udt-lp-shell', instance, | ||
1141 | 62 | version=api_version) | ||
1142 | 63 | banner = ('Connected anonymously to LP service "%s" with API version ' | ||
1143 | 64 | '"%s":' % (instance, api_version)) | ||
1144 | 65 | else: | ||
1145 | 66 | launchpad = Launchpad.login_with('udt-lp-shell', instance, | ||
1146 | 67 | version=api_version) | ||
1147 | 68 | banner = 'Connected to LP service "%s" with API version "%s":' % \ | ||
1148 | 69 | (instance, api_version) | ||
1149 | 70 | |||
1150 | 71 | banner += '\nNote: LP can be accessed through the "lp" object.' | ||
1151 | 72 | |||
1152 | 73 | sh = None | ||
1153 | 74 | if options.shell == "ipython": | ||
1154 | 75 | try: | ||
1155 | 76 | try: # ipython >= 0.11 | ||
1156 | 77 | from IPython.frontend.terminal.embed import InteractiveShellEmbed | ||
1157 | 78 | sh = InteractiveShellEmbed(banner2=banner, user_ns={'lp': launchpad}) | ||
1158 | 79 | except ImportError: # ipython < 0.11 | ||
1159 | 80 | # pylint does not handle nested try-except, disable import error | ||
1160 | 81 | # pylint: disable-msg=E0611 | ||
1161 | 82 | from IPython.Shell import IPShellEmbed | ||
1162 | 83 | sh = IPShellEmbed(argv=[], user_ns={'lp': launchpad}) | ||
1163 | 84 | sh.set_banner(sh.IP.BANNER + '\n' + banner) | ||
1164 | 85 | sh.excepthook = sys.__excepthook__ | ||
1165 | 86 | except ImportError: | ||
1166 | 87 | print "E: ipython not available. Using normal python shell." | ||
1167 | 88 | |||
1168 | 89 | if sh: | ||
1169 | 90 | sh() | ||
1170 | 91 | else: | ||
1171 | 92 | class CompleterConsole(code.InteractiveConsole): | ||
1172 | 93 | def __init__(self): | ||
1173 | 94 | local = {'lp': launchpad} | ||
1174 | 95 | code.InteractiveConsole.__init__(self, locals=local) | ||
1175 | 96 | try: | ||
1176 | 97 | import readline | ||
1177 | 98 | except ImportError: | ||
1178 | 99 | print 'I: readline module not available.' | ||
1179 | 100 | else: | ||
1180 | 101 | import rlcompleter | ||
1181 | 102 | readline.parse_and_bind("tab: complete") | ||
1182 | 103 | |||
1183 | 104 | # Disable default apport hook, as lp-shell is intended for interactive use | ||
1184 | 105 | # and thus exceptions often bubble up to the top level. | ||
1185 | 106 | sys.excepthook = sys.__excepthook__ | ||
1186 | 107 | |||
1187 | 108 | console = CompleterConsole() | ||
1188 | 109 | console.interact(banner) | ||
1189 | 110 | |||
1190 | 111 | if __name__ == '__main__': | ||
1191 | 112 | main() | ||
1192 | 113 | 0 | ||
1193 | === modified file 'setup.py' | |||
1194 | --- setup.py 2011-07-01 20:07:08 +0000 | |||
1195 | +++ setup.py 2011-09-02 11:53:47 +0000 | |||
1196 | @@ -20,18 +20,12 @@ | |||
1197 | 20 | 'check-symbols', | 20 | 'check-symbols', |
1198 | 21 | 'dch-repeat', | 21 | 'dch-repeat', |
1199 | 22 | 'dgetlp', | 22 | 'dgetlp', |
1200 | 23 | 'get-branches', | ||
1201 | 24 | 'get-build-deps', | 23 | 'get-build-deps', |
1202 | 25 | 'grab-attachments', | ||
1203 | 26 | 'grab-merge', | 24 | 'grab-merge', |
1204 | 27 | 'grep-merges', | 25 | 'grep-merges', |
1205 | 28 | 'harvest', | 26 | 'harvest', |
1206 | 29 | 'hugdaylist', | 27 | 'hugdaylist', |
1207 | 30 | 'import-bug-from-debian', | 28 | 'import-bug-from-debian', |
1208 | 31 | 'lp-list-bugs', | ||
1209 | 32 | 'lp-project-upload', | ||
1210 | 33 | 'lp-set-dup', | ||
1211 | 34 | 'lp-shell', | ||
1212 | 35 | 'massfile', | 29 | 'massfile', |
1213 | 36 | 'merge-changelog', | 30 | 'merge-changelog', |
1214 | 37 | 'mk-sbuild', | 31 | 'mk-sbuild', |
1215 | 38 | 32 | ||
1216 | === modified file 'ubuntutools/test/test_help.py' | |||
1217 | --- ubuntutools/test/test_help.py 2011-05-24 18:22:37 +0000 | |||
1218 | +++ ubuntutools/test/test_help.py 2011-09-02 11:53:47 +0000 | |||
1219 | @@ -29,8 +29,6 @@ | |||
1220 | 29 | 'check-symbols': 'No Help', | 29 | 'check-symbols': 'No Help', |
1221 | 30 | 'get-build-deps': 'No Help, runs sudo', | 30 | 'get-build-deps': 'No Help, runs sudo', |
1222 | 31 | 'grep-merges': 'No Help', | 31 | 'grep-merges': 'No Help', |
1223 | 32 | 'lp-project-upload': 'Returns non-zero after help. ' | ||
1224 | 33 | 'Leaving u-d-t in LP: #524680', | ||
1225 | 34 | 'pbuilder-dist-simple': 'No Help', | 32 | 'pbuilder-dist-simple': 'No Help', |
1226 | 35 | 'setup-packaging-environment': 'Throws Error', | 33 | 'setup-packaging-environment': 'Throws Error', |
1227 | 36 | 'submittodebian': 'No Help', | 34 | 'submittodebian': 'No Help', |
Please also update the package description, debian/copyright, and test/test_ help.py. And remove the manpages.
ubuntutools/