Merge lp:~bulldog98/kubuntu-dev-tools/trunk into lp:kubuntu-dev-tools
- trunk
- Merge into trunk
Proposed by
Jonathan Kolberg
Status: | Merged |
---|---|
Merged at revision: | 119 |
Proposed branch: | lp:~bulldog98/kubuntu-dev-tools/trunk |
Merge into: | lp:kubuntu-dev-tools |
Diff against target: |
874 lines (+733/-8) 16 files modified
TODO (+1/-2) bin/kgetsource (+44/-6) bin/khighestversion (+132/-0) bin/kshowbranches (+31/-0) bin/kshowseries (+32/-0) debian/rules (+2/-0) zsh_completion/_astyle-kubuntu (+3/-0) zsh_completion/_batpaste (+3/-0) zsh_completion/_kbranchmover (+2/-0) zsh_completion/_kbzr (+422/-0) zsh_completion/_kde-sc-build-status (+2/-0) zsh_completion/_kgetsource (+48/-0) zsh_completion/_klinksource (+5/-0) zsh_completion/_kshowbranches (+2/-0) zsh_completion/_kshowseries (+2/-0) zsh_completion/_kubuntu-update-symbols (+2/-0) |
To merge this branch: | bzr merge lp:~bulldog98/kubuntu-dev-tools/trunk |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Kubuntu Packagers | Pending | ||
Review via email: mp+73672@code.launchpad.net |
Commit message
Description of the change
This adds 2 new functions using launchpadlib and zsh completion for most of the commands
To post a comment you must log in.
- 124. By Jonathan Kolberg
-
Added the helper Harald sugested
- 125. By Jonathan Kolberg
-
updated completion
- 126. By Jonathan Kolberg
-
Made kgetsource also update control
this bumps kde-sc-dev-latest to the version of the package
- 127. By Jonathan Kolberg
-
Also made the epoch optional (assumes 4:)
- 128. By Jonathan Kolberg
-
Made kgetsource also accept only one argument.
Then it autodects the latest stable tar on the server and downloads that and uses that as version.
- 129. By Jonathan Kolberg
-
Fixed a small bug in my Implementation
- 130. By Jonathan Kolberg
-
Updated TODO
- 131. By Jonathan Kolberg
-
Also install zsh completion files
- 132. By Jonathan Kolberg
-
Cleaned up the rules
- 133. By Jonathan Kolberg
-
Made completion for kgetsource better
- 134. By Jonathan Kolberg
-
Updated kgetsource and made zsh completion better
Preview Diff
[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1 | === modified file 'TODO' | |||
2 | --- TODO 2009-01-13 13:29:10 +0000 | |||
3 | +++ TODO 2011-09-19 15:44:21 +0000 | |||
4 | @@ -1,6 +1,5 @@ | |||
6 | 1 | * Add docbook for kubuntu-dev-tools (meta manpage for batscripts and gypsy) | 1 | * Add docbook for kubuntu-dev-tools |
7 | 2 | * Add readme | 2 | * Add readme |
8 | 3 | * Test centering around batbranch | ||
9 | 4 | * Don't bundle but push | 3 | * Don't bundle but push |
10 | 5 | * Maybe use bzr-builddeb? | 4 | * Maybe use bzr-builddeb? |
11 | 6 | + either way batbuild needs an option to just export the debian dir (e.g. for | 5 | + either way batbuild needs an option to just export the debian dir (e.g. for |
12 | 7 | 6 | ||
13 | === modified file 'bin/kgetsource' | |||
14 | --- bin/kgetsource 2011-07-23 17:52:56 +0000 | |||
15 | +++ bin/kgetsource 2011-09-19 15:44:21 +0000 | |||
16 | @@ -1,6 +1,7 @@ | |||
17 | 1 | #!/usr/bin/env ruby | 1 | #!/usr/bin/env ruby |
18 | 2 | #-- | 2 | #-- |
19 | 3 | # Copyright (C) 2011 Harald Sitter <apachelogger@ubuntu.com> | 3 | # Copyright (C) 2011 Harald Sitter <apachelogger@ubuntu.com> |
20 | 4 | # Copyright (C) 2011 Jonathan Kolberg <bulldog98@kubuntu.org> | ||
21 | 4 | # | 5 | # |
22 | 5 | # This program is free software; you can redistribute it and/or | 6 | # This program is free software; you can redistribute it and/or |
23 | 6 | # modify it under the terms of the GNU General Public License as | 7 | # modify it under the terms of the GNU General Public License as |
24 | @@ -33,6 +34,7 @@ | |||
25 | 33 | if split_version.length > 1 | 34 | if split_version.length > 1 |
26 | 34 | return split_version[1] | 35 | return split_version[1] |
27 | 35 | end | 36 | end |
28 | 37 | #TODO: test for \n and remove that | ||
29 | 36 | return @version | 38 | return @version |
30 | 37 | end | 39 | end |
31 | 38 | end | 40 | end |
32 | @@ -79,23 +81,59 @@ | |||
33 | 79 | if not File.exists?("build-area") | 81 | if not File.exists?("build-area") |
34 | 80 | Dir.mkdir("build-area") | 82 | Dir.mkdir("build-area") |
35 | 81 | end | 83 | end |
36 | 84 | puts ("scp ftpubuntu@ftpmaster.kde.org:/home/ftpubuntu/#{series}/#{version.upstream_version}/src/#{tar.name} build-area/") | ||
37 | 82 | `scp ftpubuntu@ftpmaster.kde.org:/home/ftpubuntu/#{series}/#{version.upstream_version}/src/#{tar.name} build-area/` | 85 | `scp ftpubuntu@ftpmaster.kde.org:/home/ftpubuntu/#{series}/#{version.upstream_version}/src/#{tar.name} build-area/` |
38 | 83 | `cd build-area && ln -s #{tar.name} #{tar.orig_name}` | 86 | `cd build-area && ln -s #{tar.name} #{tar.orig_name}` |
39 | 84 | end | 87 | end |
40 | 85 | 88 | ||
41 | 86 | def update_changelog() | 89 | def update_changelog() |
43 | 87 | `cd #{name} && dch -v #{version.version}-0ubuntu1 -D UNRELEASED 'New upstream release'` | 90 | #if @version.version = @version.upstream_version |
44 | 91 | `cd #{name} && dch -v '4:#{version.upstream_version}-0ubuntu1' -D UNRELEASED 'New upstream release'` | ||
45 | 92 | #else | ||
46 | 93 | # `cd #{name} && dch -v #{version.version}-0ubuntu1 -D UNRELEASED 'New upstream release'` | ||
47 | 94 | #end | ||
48 | 95 | def stringReplace(fileName) | ||
49 | 96 | aFile = File.open(fileName, "r") | ||
50 | 97 | aString = aFile.read | ||
51 | 98 | aFile.close | ||
52 | 99 | |||
53 | 100 | left = "kde-sc-dev-latest (>= " | ||
54 | 101 | right = ")" | ||
55 | 102 | |||
56 | 103 | aString.gsub!(/#{Regexp.quote(left)}(.*?)#{Regexp.quote(right)}/m, | ||
57 | 104 | "#{left}#{"4:"+@version.upstream_version}#{right}") | ||
58 | 105 | |||
59 | 106 | File.open(fileName, "w") { |file| file << aString } | ||
60 | 107 | end | ||
61 | 108 | stringReplace(@name+"/debian/control") | ||
62 | 88 | end | 109 | end |
63 | 89 | end | 110 | end |
64 | 90 | 111 | ||
66 | 91 | if ARGV[0].nil? or ARGV[1].nil? or ARGV[2].nil? | 112 | def more() |
67 | 92 | puts("NEED MORE ARGS YE BSTD") | 113 | puts("NEED MORE ARGS YE BSTD") |
68 | 93 | exit(1) | 114 | exit(1) |
69 | 94 | end | 115 | end |
70 | 95 | 116 | ||
72 | 96 | source = Source.new(ARGV[0], ARGV[1], ARGV[2]) | 117 | if ARGV[0].nil? |
73 | 118 | more | ||
74 | 119 | end | ||
75 | 97 | 120 | ||
79 | 98 | source.get_bzr() | 121 | if ARGV[1].nil? |
80 | 99 | source.get_upstream() | 122 | vers=`khighestversion highest stable` |
81 | 100 | source.update_changelog() | 123 | source = Source.new(ARGV[0],"4:#{vers}","stable") |
82 | 124 | source.get_bzr() | ||
83 | 125 | source.get_upstream() | ||
84 | 126 | source.update_changelog() | ||
85 | 127 | else | ||
86 | 128 | if ARGV[2].nil? | ||
87 | 129 | #TODO: make kgetsource autoguess the series | ||
88 | 130 | more | ||
89 | 131 | else | ||
90 | 132 | source = Source.new(ARGV[0], ARGV[1], ARGV[2]) | ||
91 | 133 | |||
92 | 134 | source.get_bzr() | ||
93 | 135 | source.get_upstream() | ||
94 | 136 | source.update_changelog() | ||
95 | 137 | end | ||
96 | 138 | end | ||
97 | 101 | 139 | ||
98 | 102 | 140 | ||
99 | === added file 'bin/khighestversion' | |||
100 | --- bin/khighestversion 1970-01-01 00:00:00 +0000 | |||
101 | +++ bin/khighestversion 2011-09-19 15:44:21 +0000 | |||
102 | @@ -0,0 +1,132 @@ | |||
103 | 1 | #!/usr/bin/env ruby | ||
104 | 2 | #-- | ||
105 | 3 | # Copyright (C) 2011 Jonathan Kolberg <bulldog98@kubuntu-de.org> | ||
106 | 4 | # | ||
107 | 5 | # This program is free software; you can redistribute it and/or | ||
108 | 6 | # modify it under the terms of the GNU General Public License as | ||
109 | 7 | # published by the Free Software Foundation; either version 2 of | ||
110 | 8 | # the License or (at your option) version 3 or any later version | ||
111 | 9 | # accepted by the membership of KDE e.V. (or its successor approved | ||
112 | 10 | # by the membership of KDE e.V.), which shall act as a proxy | ||
113 | 11 | # defined in Section 14 of version 3 of the license. | ||
114 | 12 | # | ||
115 | 13 | # This program is distributed in the hope that it will be useful, | ||
116 | 14 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
117 | 15 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
118 | 16 | # GNU General Public License for more details. | ||
119 | 17 | # | ||
120 | 18 | # You should have received a copy of the GNU General Public License | ||
121 | 19 | # along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
122 | 20 | #-- | ||
123 | 21 | |||
124 | 22 | class Versions | ||
125 | 23 | attr_reader :stable, :unstable, :versions, :highest, :higheststable, :result, :search, :name | ||
126 | 24 | |||
127 | 25 | def initialize(search,name) | ||
128 | 26 | @stable = [] | ||
129 | 27 | tmp = `ssh ftpubuntu@ftpmaster.kde.org ls -c /home/ftpubuntu/stable/` | ||
130 | 28 | for i in tmp | ||
131 | 29 | if i =~ /^[1-9]\.[0-9]\.[0-9]/ | ||
132 | 30 | stable << i | ||
133 | 31 | end | ||
134 | 32 | end | ||
135 | 33 | tmp2 = `ssh ftpubuntu@ftpmaster.kde.org ls -c /home/ftpubuntu/unstable/` | ||
136 | 34 | @unstable = [] | ||
137 | 35 | for i in tmp2 | ||
138 | 36 | if i =~ /^[1-9]\.[0-9]\.[0-9]/ | ||
139 | 37 | unstable << i | ||
140 | 38 | end | ||
141 | 39 | end | ||
142 | 40 | @versions = [] | ||
143 | 41 | @highest = "0.0.0" | ||
144 | 42 | @higheststable = "0.0.0" | ||
145 | 43 | @search = search + "\n" | ||
146 | 44 | @versions = stable + unstable | ||
147 | 45 | @name = name | ||
148 | 46 | end | ||
149 | 47 | |||
150 | 48 | def sort!() | ||
151 | 49 | versions.sort! | ||
152 | 50 | versions.reverse! | ||
153 | 51 | stable.sort! | ||
154 | 52 | stable.reverse! | ||
155 | 53 | unstable.sort! | ||
156 | 54 | unstable.reverse! | ||
157 | 55 | end | ||
158 | 56 | |||
159 | 57 | def higheststable!() | ||
160 | 58 | stable.sort! | ||
161 | 59 | @higheststable = stable.last | ||
162 | 60 | end | ||
163 | 61 | |||
164 | 62 | def path! | ||
165 | 63 | self.where! | ||
166 | 64 | if @result.nil? | ||
167 | 65 | puts("THIS VERSION DOESN'T EXIST") | ||
168 | 66 | exit(1) | ||
169 | 67 | end | ||
170 | 68 | path = "/home/ftpubuntu" + @result + "/" + @search + "/src/" + @name | ||
171 | 69 | puts | ||
172 | 70 | end | ||
173 | 71 | |||
174 | 72 | private | ||
175 | 73 | def where!() | ||
176 | 74 | if @stable.include?(@search) | ||
177 | 75 | @result = "stable" | ||
178 | 76 | else | ||
179 | 77 | if @unstable.include?(@search) | ||
180 | 78 | @result = "unstable" | ||
181 | 79 | end | ||
182 | 80 | end | ||
183 | 81 | end | ||
184 | 82 | end | ||
185 | 83 | |||
186 | 84 | if ARGV[0].nil? | ||
187 | 85 | puts("Y U NOT GIMME NARGS? :'(((((") | ||
188 | 86 | exit(1) | ||
189 | 87 | end | ||
190 | 88 | |||
191 | 89 | if ARGV[0] == "version" | ||
192 | 90 | v = Versions.new("","") | ||
193 | 91 | v.sort! | ||
194 | 92 | puts v.versions | ||
195 | 93 | exit(0) | ||
196 | 94 | end | ||
197 | 95 | |||
198 | 96 | if ARGV[0] == "highest" | ||
199 | 97 | if ARGV[1].nil? | ||
200 | 98 | puts("Y U NOT GIMME NARGS? :'(((((") | ||
201 | 99 | exit(1) | ||
202 | 100 | end | ||
203 | 101 | v = Versions.new("","") | ||
204 | 102 | v.sort! | ||
205 | 103 | if ARGV[1] == "all" | ||
206 | 104 | puts v.versions.first | ||
207 | 105 | exit(0) | ||
208 | 106 | end | ||
209 | 107 | if ARGV[1] == "stable" | ||
210 | 108 | puts v.stable.first | ||
211 | 109 | exit(0) | ||
212 | 110 | end | ||
213 | 111 | if ARGV[1] == "unstable" | ||
214 | 112 | puts v.unstable.first | ||
215 | 113 | exit(0) | ||
216 | 114 | end | ||
217 | 115 | puts ("Y U NOT GIMME RIGHT ARGS? :'((((") | ||
218 | 116 | exit(1) | ||
219 | 117 | end | ||
220 | 118 | |||
221 | 119 | if ARGV[0] == "path" | ||
222 | 120 | if ARGV[1].nil? || ARGV[2].nil? | ||
223 | 121 | puts("Y U NOT GIMME NARGS? :'(((((") | ||
224 | 122 | exit(1) | ||
225 | 123 | end | ||
226 | 124 | #kgetsource_helper path NAME VERSION | ||
227 | 125 | v = Versions.new(ARGS[2],ARGS[1]) | ||
228 | 126 | v.path! | ||
229 | 127 | end | ||
230 | 128 | |||
231 | 129 | if ARGV[0] | ||
232 | 130 | puts("Y U NOT GIMME RIGHT ARGS? :'((((") | ||
233 | 131 | exit(1) | ||
234 | 132 | end | ||
235 | 0 | 133 | ||
236 | === added file 'bin/kshowbranches' | |||
237 | --- bin/kshowbranches 1970-01-01 00:00:00 +0000 | |||
238 | +++ bin/kshowbranches 2011-09-19 15:44:21 +0000 | |||
239 | @@ -0,0 +1,31 @@ | |||
240 | 1 | #!/usr/bin/python | ||
241 | 2 | #-- | ||
242 | 3 | # Copyright (C) 2011 Jonathan Kolberg <bulldog98@kubuntu-de.org> | ||
243 | 4 | # | ||
244 | 5 | # This program is free software; you can redistribute it and/or | ||
245 | 6 | # modify it under the terms of the GNU General Public License as | ||
246 | 7 | # published by the Free Software Foundation; either version 2 of | ||
247 | 8 | # the License or (at your option) version 3 or any later version | ||
248 | 9 | # accepted by the membership of KDE e.V. (or its successor approved | ||
249 | 10 | # by the membership of KDE e.V.), which shall act as a proxy | ||
250 | 11 | # defined in Section 14 of version 3 of the license. | ||
251 | 12 | # | ||
252 | 13 | # This program is distributed in the hope that it will be useful, | ||
253 | 14 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
254 | 15 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
255 | 16 | # GNU General Public License for more details. | ||
256 | 17 | # | ||
257 | 18 | # You should have received a copy of the GNU General Public License | ||
258 | 19 | # along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
259 | 20 | #-- | ||
260 | 21 | |||
261 | 22 | import sys | ||
262 | 23 | from launchpadlib.launchpad import Launchpad | ||
263 | 24 | |||
264 | 25 | lp = Launchpad.login_with('kshowbranches', 'production') | ||
265 | 26 | |||
266 | 27 | team = lp.people['kubuntu-packagers'] | ||
267 | 28 | branches = team.getBranches() | ||
268 | 29 | |||
269 | 30 | for branch in branches: | ||
270 | 31 | print branch.bzr_identity | ||
271 | 0 | \ No newline at end of file | 32 | \ No newline at end of file |
272 | 1 | 33 | ||
273 | === added file 'bin/kshowseries' | |||
274 | --- bin/kshowseries 1970-01-01 00:00:00 +0000 | |||
275 | +++ bin/kshowseries 2011-09-19 15:44:21 +0000 | |||
276 | @@ -0,0 +1,32 @@ | |||
277 | 1 | #!/usr/bin/python | ||
278 | 2 | #-- | ||
279 | 3 | # Copyright (C) 2011 Jonathan Kolberg <bulldog98@kubuntu-de.org> | ||
280 | 4 | # | ||
281 | 5 | # This program is free software; you can redistribute it and/or | ||
282 | 6 | # modify it under the terms of the GNU General Public License as | ||
283 | 7 | # published by the Free Software Foundation; either version 2 of | ||
284 | 8 | # the License or (at your option) version 3 or any later version | ||
285 | 9 | # accepted by the membership of KDE e.V. (or its successor approved | ||
286 | 10 | # by the membership of KDE e.V.), which shall act as a proxy | ||
287 | 11 | # defined in Section 14 of version 3 of the license. | ||
288 | 12 | # | ||
289 | 13 | # This program is distributed in the hope that it will be useful, | ||
290 | 14 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
291 | 15 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
292 | 16 | # GNU General Public License for more details. | ||
293 | 17 | # | ||
294 | 18 | # You should have received a copy of the GNU General Public License | ||
295 | 19 | # along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
296 | 20 | #-- | ||
297 | 21 | |||
298 | 22 | import sys | ||
299 | 23 | from launchpadlib.launchpad import Launchpad | ||
300 | 24 | |||
301 | 25 | lp = Launchpad.login_with('kshowseries', 'production') | ||
302 | 26 | |||
303 | 27 | ubuntu = lp.distributions["ubuntu"] | ||
304 | 28 | series = ubuntu.series_collection_link | ||
305 | 29 | |||
306 | 30 | for serie in ubuntu.series: | ||
307 | 31 | if serie.active: | ||
308 | 32 | print serie.name | ||
309 | 0 | \ No newline at end of file | 33 | \ No newline at end of file |
310 | 1 | 34 | ||
311 | === modified file 'debian/rules' | |||
312 | --- debian/rules 2008-12-10 08:49:19 +0000 | |||
313 | +++ debian/rules 2011-09-19 15:44:21 +0000 | |||
314 | @@ -20,6 +20,8 @@ | |||
315 | 20 | dh_clean -k | 20 | dh_clean -k |
316 | 21 | dh_installdirs | 21 | dh_installdirs |
317 | 22 | ruby setup.rb install --prefix=$(CURDIR)/debian/kubuntu-dev-tools | 22 | ruby setup.rb install --prefix=$(CURDIR)/debian/kubuntu-dev-tools |
318 | 23 | mkdir -p $(CURDIR)/debian/kubuntu-dev-tools/usr/share/zsh/functions/Completion/ | ||
319 | 24 | cp zsh_completion/* $(CURDIR)/debian/kubuntu-dev-tools/usr/share/zsh/functions/Completion/ | ||
320 | 23 | 25 | ||
321 | 24 | binary-indep: build install | 26 | binary-indep: build install |
322 | 25 | dh_testdir | 27 | dh_testdir |
323 | 26 | 28 | ||
324 | === added directory 'zsh_completion' | |||
325 | === added file 'zsh_completion/_astyle-kubuntu' | |||
326 | --- zsh_completion/_astyle-kubuntu 1970-01-01 00:00:00 +0000 | |||
327 | +++ zsh_completion/_astyle-kubuntu 2011-09-19 15:44:21 +0000 | |||
328 | @@ -0,0 +1,3 @@ | |||
329 | 1 | #compdef astyle-kubuntu | ||
330 | 2 | |||
331 | 3 | _arguments "1: :." | ||
332 | 0 | \ No newline at end of file | 4 | \ No newline at end of file |
333 | 1 | 5 | ||
334 | === added file 'zsh_completion/_batpaste' | |||
335 | --- zsh_completion/_batpaste 1970-01-01 00:00:00 +0000 | |||
336 | +++ zsh_completion/_batpaste 2011-09-19 15:44:21 +0000 | |||
337 | @@ -0,0 +1,3 @@ | |||
338 | 1 | #compdef batpaste | ||
339 | 2 | |||
340 | 3 | _arguments '1:file to paste:_files' | ||
341 | 0 | \ No newline at end of file | 4 | \ No newline at end of file |
342 | 1 | 5 | ||
343 | === added file 'zsh_completion/_kbranchmover' | |||
344 | --- zsh_completion/_kbranchmover 1970-01-01 00:00:00 +0000 | |||
345 | +++ zsh_completion/_kbranchmover 2011-09-19 15:44:21 +0000 | |||
346 | @@ -0,0 +1,2 @@ | |||
347 | 1 | #compdef kbranchmover | ||
348 | 2 | _message "no more arguments" | ||
349 | 0 | \ No newline at end of file | 3 | \ No newline at end of file |
350 | 1 | 4 | ||
351 | === added file 'zsh_completion/_kbzr' | |||
352 | --- zsh_completion/_kbzr 1970-01-01 00:00:00 +0000 | |||
353 | +++ zsh_completion/_kbzr 2011-09-19 15:44:21 +0000 | |||
354 | @@ -0,0 +1,422 @@ | |||
355 | 1 | #compdef kbzr | ||
356 | 2 | |||
357 | 3 | #This is a modified version of _bzr shipped with zsh | ||
358 | 4 | |||
359 | 5 | local curcontext="$curcontext" state line expl cmd args ret=1 | ||
360 | 6 | typeset -A opt_args | ||
361 | 7 | |||
362 | 8 | _arguments -C \ | ||
363 | 9 | '1: :->cmd' \ | ||
364 | 10 | '*:: :->args' && ret=0 | ||
365 | 11 | |||
366 | 12 | if (( ! $+_bzr_cmds )); then | ||
367 | 13 | typeset -gH _bzr_cmds | ||
368 | 14 | _bzr_cmds=(${(f)"$(_call_program bzr bzr shell-complete)"}) | ||
369 | 15 | fi | ||
370 | 16 | |||
371 | 17 | if [[ $state != 'args' ]]; then | ||
372 | 18 | _describe -t subcommand 'subcommand' _bzr_cmds | ||
373 | 19 | return 0 | ||
374 | 20 | fi | ||
375 | 21 | |||
376 | 22 | cmd="$words[1]" | ||
377 | 23 | curcontext="${curcontext%:*:*}:bzr-$cmd:" | ||
378 | 24 | |||
379 | 25 | (( $+functions[_bzr_unknownFiles] )) || | ||
380 | 26 | _bzr_unknownFiles() { | ||
381 | 27 | local fileList | ||
382 | 28 | fileList=(${(ps:\0:)"$(bzr ls --null --unknown)"}) | ||
383 | 29 | compadd -af fileList | ||
384 | 30 | return 0 | ||
385 | 31 | } | ||
386 | 32 | |||
387 | 33 | (( $+functions[_bzr_unknownRoot] )) || | ||
388 | 34 | _bzr_unknownRoot() { | ||
389 | 35 | local fileList | ||
390 | 36 | fileList=(${(ps:\0:)"$(bzr ls --null --from-root --unknown)"}) | ||
391 | 37 | compadd -af fileList | ||
392 | 38 | return 0 | ||
393 | 39 | } | ||
394 | 40 | |||
395 | 41 | (( $+functions[_bzr_versionedFiles] )) || | ||
396 | 42 | _bzr_versionedFiles() { | ||
397 | 43 | local fileList | ||
398 | 44 | fileList=(${(ps:\0:)"$(bzr ls --null --versioned)"}) | ||
399 | 45 | compadd -af fileList | ||
400 | 46 | return 0 | ||
401 | 47 | } | ||
402 | 48 | |||
403 | 49 | (( $+functions[_bzr_completeParents] )) || | ||
404 | 50 | _bzr_completeParents() { | ||
405 | 51 | local parentFile=$(bzr root 2>/dev/null)/.bzr/branch/parent | ||
406 | 52 | [[ -r $parentFile ]] && compadd -X "Completing parents" $(cat $parentFile) | ||
407 | 53 | } | ||
408 | 54 | |||
409 | 55 | (( $+functions[_kubuntu_completion] )) || | ||
410 | 56 | _kubuntu_completion() { | ||
411 | 57 | if ( [[ ${+_kubuntu_completion_cache_packages} -eq 0 ]] || | ||
412 | 58 | _cache_invalid KUBUNTU_PACKAGES_CACHE) && ! _retrieve_cache KUBUNTU_PACKAGES_CACHE; | ||
413 | 59 | then | ||
414 | 60 | _kubuntu_completion_cache_packages=( | ||
415 | 61 | ${(f)"$(kshowbranches| grep "lp:~kubuntu-packagers/kubuntu-packaging/" |sed 's/lp:\~kubuntu-packagers\/kubuntu-packaging\///' 2>/dev/null)"} | ||
416 | 62 | ) | ||
417 | 63 | |||
418 | 64 | _store_cache KUBUNTU_PACKAGES_CACHE _kubuntu_completion_cache_packages | ||
419 | 65 | fi | ||
420 | 66 | typeset -gH _kubuntu_completion_cache_packages | ||
421 | 67 | |||
422 | 68 | compadd -x "branch name" -a _kubuntu_completion_cache_packages | ||
423 | 69 | } | ||
424 | 70 | |||
425 | 71 | args=( '(-)'{--help,-h}'[show help message]' ) | ||
426 | 72 | |||
427 | 73 | case $cmd in | ||
428 | 74 | (add) | ||
429 | 75 | args+=( | ||
430 | 76 | '--dry-run[show what would be added without adding anything]' | ||
431 | 77 | '--no-recurse[do not recurse into subdirectories]' | ||
432 | 78 | '(-q --quiet -v --verbose)'{--quiet,-q}'[be quiet]' | ||
433 | 79 | '(-v --verbose -q --quiet)'{--verbose,-v}'[display more information]' | ||
434 | 80 | '*:unknown files:_bzr_unknownFiles' | ||
435 | 81 | ) | ||
436 | 82 | ;; | ||
437 | 83 | |||
438 | 84 | (annotate|blame|praise) | ||
439 | 85 | args+=( | ||
440 | 86 | '--all[show annotations on all lines]' | ||
441 | 87 | '--long[show date in annotations]' | ||
442 | 88 | '(-r --revision)'{--revision=,-r}'[the revision to show]:rev:' | ||
443 | 89 | '*:files:_bzr_versionedFiles' | ||
444 | 90 | ) | ||
445 | 91 | ;; | ||
446 | 92 | |||
447 | 93 | (branch|get|clone) | ||
448 | 94 | args+=( | ||
449 | 95 | '(-r --revision)'{--revision=,-r}'[the revision to get]:rev:' | ||
450 | 96 | '--basis=[specify basis branch]:basis:' | ||
451 | 97 | ) | ||
452 | 98 | if (( CURRENT == 2 )); then | ||
453 | 99 | args+=( '*:FROM_LOCATION:_kubuntu_completion' ) | ||
454 | 100 | elif (( CURRENT == 3 )); then | ||
455 | 101 | args+=( '*:TO_LOCATION:_files -/' ) | ||
456 | 102 | fi | ||
457 | 103 | ;; | ||
458 | 104 | |||
459 | 105 | (checkout|co) | ||
460 | 106 | args+=( | ||
461 | 107 | '--lightweight[perform a lightweight checkout]' | ||
462 | 108 | '(-r --revision)'{--revision=,-r}'[the revision to get]:rev:' | ||
463 | 109 | _kubuntu_completion | ||
464 | 110 | ) | ||
465 | 111 | ;; | ||
466 | 112 | |||
467 | 113 | (rename|move|mv) | ||
468 | 114 | if (( CURRENT == 2 )); then | ||
469 | 115 | args+=( '*:files:_bzr_versionedFiles' ) | ||
470 | 116 | else | ||
471 | 117 | args=( '*:destination dir:_files -/' ) | ||
472 | 118 | fi | ||
473 | 119 | ;; | ||
474 | 120 | |||
475 | 121 | (cat) | ||
476 | 122 | args+=( | ||
477 | 123 | '(-r --revision)'{--revision=,-r}'[revision]:rev:' | ||
478 | 124 | '*:file:_bzr_versionedFiles' | ||
479 | 125 | ) | ||
480 | 126 | ;; | ||
481 | 127 | |||
482 | 128 | (root) | ||
483 | 129 | args+=( '*:file:_files' ) | ||
484 | 130 | ;; | ||
485 | 131 | |||
486 | 132 | (log) | ||
487 | 133 | args+=( | ||
488 | 134 | '--forward[reverse direction of revisions]' | ||
489 | 135 | '(-l --long --short --log_format)--line[use log format with one line per revision. Same as "--log-format line"]' | ||
490 | 136 | '(-l --long --short --line)--log-format=[use the specified log format]:log format:(line short long)' | ||
491 | 137 | '(-l --long --short --line --log-format)'{--long,-l}'[use detailed log format. Same as "--log-format long"]' | ||
492 | 138 | '(-l --long --log_format)--short[use moderately short log format. Same as "--log-format short"]' | ||
493 | 139 | '(-m --message)'{--message=,-m}'[specify regexp]:regexp:' | ||
494 | 140 | '(-r --revision)'{--revision=,-r}'[revision or range]:rev or rev range:' | ||
495 | 141 | '--show-ids[show file IDs]' | ||
496 | 142 | '--timezone=[specify timezone for dates]:timezone:' | ||
497 | 143 | '(-v --verbose)'{--verbose,-v}'[show revision manifest]' | ||
498 | 144 | '*:file:_bzr_versionedFiles' | ||
499 | 145 | ) | ||
500 | 146 | ;; | ||
501 | 147 | |||
502 | 148 | (resolve|resolved) | ||
503 | 149 | args+=( | ||
504 | 150 | '--all[resolve all conflicts in this tree]' | ||
505 | 151 | '*:file:_bzr_versionedFiles' | ||
506 | 152 | ) | ||
507 | 153 | ;; | ||
508 | 154 | |||
509 | 155 | (status|st|stat) | ||
510 | 156 | args+=( | ||
511 | 157 | '--all[include unchanged versioned files]' | ||
512 | 158 | '(-r --revision)'{--revision=,-r}'[compare working tree with revision]:revision:' | ||
513 | 159 | '--show-ids[show file IDs]' | ||
514 | 160 | '*:file:_bzr_versionedFiles' | ||
515 | 161 | ) | ||
516 | 162 | ;; | ||
517 | 163 | |||
518 | 164 | (check) | ||
519 | 165 | args+=( | ||
520 | 166 | '(-v --verbose)'{--verbose,-v}'[display more information]' | ||
521 | 167 | '*:DIR:_files -/' | ||
522 | 168 | ) | ||
523 | 169 | ;; | ||
524 | 170 | |||
525 | 171 | (mkdir|renames|update) | ||
526 | 172 | args+=( '*:DIR:_files -/' ) | ||
527 | 173 | ;; | ||
528 | 174 | |||
529 | 175 | (init|upgrade) | ||
530 | 176 | args+=( | ||
531 | 177 | '--format=[format for repository]:format:(default knit metaweave weave)' | ||
532 | 178 | '*:DIR:_files -/' | ||
533 | 179 | ) | ||
534 | 180 | ;; | ||
535 | 181 | |||
536 | 182 | (init-repo|init-repository) | ||
537 | 183 | args+=( | ||
538 | 184 | '--format=[format for repository]:format:(default knit metaweave weave)' | ||
539 | 185 | '--trees[allows branches in repository to have a working tree]' | ||
540 | 186 | '*:DIR:_files -/' | ||
541 | 187 | ) | ||
542 | 188 | ;; | ||
543 | 189 | |||
544 | 190 | (remove|rm) | ||
545 | 191 | args+=( | ||
546 | 192 | '(-v --verbose)'{--verbose,-v}'[display more information]' | ||
547 | 193 | '*:file:_bzr_versionedFiles' | ||
548 | 194 | ) | ||
549 | 195 | ;; | ||
550 | 196 | |||
551 | 197 | (pull) | ||
552 | 198 | args+=( | ||
553 | 199 | '--overwrite[ignore differences, overwrite unconditionally]' | ||
554 | 200 | '--remember[remember the specified location as a default]' | ||
555 | 201 | '(-r --revision)'{--revision=,-r}'[get a particular revision]:revision:' | ||
556 | 202 | '(-v --verbose)'{--verbose,-v}'[display more information]' | ||
557 | 203 | '*:local repository:_files -/' | ||
558 | 204 | ) | ||
559 | 205 | _bzr_completeParents | ||
560 | 206 | ;; | ||
561 | 207 | |||
562 | 208 | (missing) | ||
563 | 209 | args+=( | ||
564 | 210 | '(-l --long --short --log_format)--line[use log format with one line per revision. Same as "--log-format line"]' | ||
565 | 211 | '(-l --long --short --line)--log-format=[use the specified log format]:log format:(line short long)' | ||
566 | 212 | '(-l --long --short --line --log-format)'{--long,-l}'[use detailed log format. Same as "--log-format long"]' | ||
567 | 213 | '(-l --long --log_format)--short[use moderately short log format. Same as "--log-format short"]' | ||
568 | 214 | '--mine-only[display changes in the local branch only]' | ||
569 | 215 | '--reverse[reverse the order of revisions]' | ||
570 | 216 | '--show-ids[show internal object ids]' | ||
571 | 217 | '--theirs-only[display changes in the remote branch only]' | ||
572 | 218 | '(-v --verbose)'{--verbose,-v}'[display more information]' | ||
573 | 219 | '*:local repository:_files -/' | ||
574 | 220 | ) | ||
575 | 221 | _bzr_completeParents | ||
576 | 222 | ;; | ||
577 | 223 | |||
578 | 224 | (commit|checkin|ci) | ||
579 | 225 | args+=( | ||
580 | 226 | '(-F --file)'{--file=,-F}'[commit message from file]:message file:' | ||
581 | 227 | '--local[perform a local only commit in a bound branch]' | ||
582 | 228 | '(-m --message)'{--message=,-m}'[commit message]:message text:' | ||
583 | 229 | '--strict[refuse to commit if there are unknown files]' | ||
584 | 230 | '--unchanged[include unchanged files]' | ||
585 | 231 | '(-q --quiet -v --verbose)'{--quiet,-q}'[be quiet]' | ||
586 | 232 | '(-v --verbose -q --quiet)'{--verbose,-v}'[display more information]' | ||
587 | 233 | '*:modified files:_bzr_versionedFiles' | ||
588 | 234 | ) | ||
589 | 235 | ;; | ||
590 | 236 | |||
591 | 237 | (bind|break-lock|reconcile) | ||
592 | 238 | _bzr_completeParents | ||
593 | 239 | ;; | ||
594 | 240 | |||
595 | 241 | (register-branch) | ||
596 | 242 | args+=( | ||
597 | 243 | '--author=[email of the branch author, if not you]:email:' | ||
598 | 244 | '--branch-description=[longer description of the branch]:description:' | ||
599 | 245 | '--branch-name=[short name for the branch]:name:' | ||
600 | 246 | '--branch-title=[one-sentence description of the branch]:title:' | ||
601 | 247 | '--dry-run[prepare the request but do not actually send it]' | ||
602 | 248 | '--link-bug=[the bug this branch fixes]:bug-ID:' | ||
603 | 249 | '--product=[launchpad product short name to associate with the branch]:product:' | ||
604 | 250 | ) | ||
605 | 251 | _bzr_completeParents | ||
606 | 252 | ;; | ||
607 | 253 | |||
608 | 254 | (remerge) | ||
609 | 255 | args+=( | ||
610 | 256 | '--merge-type=[the type of the merge]:type:' | ||
611 | 257 | '--reprocess[reprocess to reduce spurious conflicts]' | ||
612 | 258 | '--show-base[show base revision text in conflicts]' | ||
613 | 259 | ) | ||
614 | 260 | _bzr_completeParents | ||
615 | 261 | ;; | ||
616 | 262 | |||
617 | 263 | (conflicts|added|deleted|modified|unknowns|directories|ignored|unbind|nick|revno|version) | ||
618 | 264 | ;; | ||
619 | 265 | |||
620 | 266 | (whoami) | ||
621 | 267 | args+=( '--email[only show e-mail address]' ) | ||
622 | 268 | ;; | ||
623 | 269 | |||
624 | 270 | (inventory) | ||
625 | 271 | args+=( | ||
626 | 272 | '--kind=[limit output by type]:kind:(file directory symlink)' | ||
627 | 273 | '(-r --revision)'{--revision=,-r}'[show inventory of a revision]:revision:' | ||
628 | 274 | '--show-ids[show file IDs]' | ||
629 | 275 | ) | ||
630 | 276 | ;; | ||
631 | 277 | |||
632 | 278 | (diff|dif|di) | ||
633 | 279 | args+=( | ||
634 | 280 | '(-r --revision)'{--revision=,-r}'[revision]:revision:' | ||
635 | 281 | '--diff-options=[options to pass to gdiff]:diff options:' | ||
636 | 282 | '(-p --prefix)'{--prefix,-p}'[set prefix added to old and new filenames]' | ||
637 | 283 | '*:files:_files' | ||
638 | 284 | ) | ||
639 | 285 | ;; | ||
640 | 286 | |||
641 | 287 | (export) | ||
642 | 288 | args+=( | ||
643 | 289 | '(-r --revision)'{--revision=,-r}'[revision]:revision:' | ||
644 | 290 | '--format=[format of exported file]:format:(dir tar tgz tbz2)' | ||
645 | 291 | '--root=[root directory of patch]:_files -/' | ||
646 | 292 | '*:destination:_files' | ||
647 | 293 | ) | ||
648 | 294 | ;; | ||
649 | 295 | |||
650 | 296 | (ignore) | ||
651 | 297 | args+=( '*:NAME_PATTERN:_bzr_unknownRoot' ) | ||
652 | 298 | ;; | ||
653 | 299 | |||
654 | 300 | (info) | ||
655 | 301 | args+=( | ||
656 | 302 | '(-v --verbose)'{--verbose,-v}'[display more information]' | ||
657 | 303 | '*:branch:_files -/' | ||
658 | 304 | ) | ||
659 | 305 | ;; | ||
660 | 306 | |||
661 | 307 | (testament) | ||
662 | 308 | args+=( | ||
663 | 309 | '(-l --long)'{--long,-l}'[use long format]' | ||
664 | 310 | '(-r --revision)'{--revision=,-r}'[revision]:revision:' | ||
665 | 311 | '*:branch:_files -/' | ||
666 | 312 | ) | ||
667 | 313 | ;; | ||
668 | 314 | |||
669 | 315 | (revert|merge-revert) | ||
670 | 316 | args+=( | ||
671 | 317 | '--no-backup[skip generation of backup~ files]' | ||
672 | 318 | '(-r --revision)'{--revision=,-r}'[revision]:revision:' | ||
673 | 319 | '*:file:_bzr_versionedFiles' | ||
674 | 320 | ) | ||
675 | 321 | ;; | ||
676 | 322 | |||
677 | 323 | (merge) | ||
678 | 324 | args+=( | ||
679 | 325 | '--force[ignore uncommitted changes]' | ||
680 | 326 | '--merge-type:merge type:(diff3 merge3 weave)' | ||
681 | 327 | '--remember[remember the specified location as a default]' | ||
682 | 328 | '--reprocess[reprocess to reduce spurious conflicts]' | ||
683 | 329 | '(-r --revision)'{--revision=,-r}'[revision]:revision:' | ||
684 | 330 | '--show-base[show base revision text in conflicts]' | ||
685 | 331 | '*:local repository:_files -/' | ||
686 | 332 | ) | ||
687 | 333 | _bzr_completeParents | ||
688 | 334 | ;; | ||
689 | 335 | |||
690 | 336 | (ls) | ||
691 | 337 | args+=( | ||
692 | 338 | '(-q --quiet -v --verbose)'{--quiet,-q}'[be quiet]' | ||
693 | 339 | '(-v --verbose -q --quiet)'{--verbose,-v}'[display more information]' | ||
694 | 340 | '(-r --revision)'{--revision=,-r}'[revision]:revision:' | ||
695 | 341 | '--from-root[print all paths from the root of the branch]' | ||
696 | 342 | '--non-recursive[do not recurse into subdirectories]' | ||
697 | 343 | '--null[null separate the files]' | ||
698 | 344 | '--ignored[print ignored files]' | ||
699 | 345 | '--unknown[print unknown files]' | ||
700 | 346 | '--versioned[print versioned files]' | ||
701 | 347 | ) | ||
702 | 348 | ;; | ||
703 | 349 | |||
704 | 350 | (switch) | ||
705 | 351 | args+=( | ||
706 | 352 | '--force[switch even if local commits will be lost]' | ||
707 | 353 | '(-q --quiet -v --verbose)'{--quiet,-q}'[be quiet]' | ||
708 | 354 | '(-v --verbose -q --quiet)'{--verbose,-v}'[display more information]' | ||
709 | 355 | '*:local repository:_files -/' | ||
710 | 356 | ) | ||
711 | 357 | _bzr_completeParents | ||
712 | 358 | ;; | ||
713 | 359 | |||
714 | 360 | (help) | ||
715 | 361 | args=( | ||
716 | 362 | '(-l --long)'{--long,-l}'[use long format]' | ||
717 | 363 | '*:subcmds:->cmds' | ||
718 | 364 | ) | ||
719 | 365 | _arguments -s "$args[@]" && ret=0 | ||
720 | 366 | _describe -t subcommand 'subcommand' _bzr_cmds | ||
721 | 367 | return 0 | ||
722 | 368 | ;; | ||
723 | 369 | |||
724 | 370 | # Plugins | ||
725 | 371 | |||
726 | 372 | (visualize|visualise|viz|vis) | ||
727 | 373 | args+=( '(-r --revision)'{--revision=,-r}'[starting revision]:rev:' ) | ||
728 | 374 | ;; | ||
729 | 375 | |||
730 | 376 | (gannotate|gblame|gpraise) | ||
731 | 377 | args+=( | ||
732 | 378 | '--all[show annotations on all lines]' | ||
733 | 379 | '--plain[do not hightlight annotation lines]' | ||
734 | 380 | '*:files:_bzr_versionedFiles' | ||
735 | 381 | ) | ||
736 | 382 | ;; | ||
737 | 383 | |||
738 | 384 | (push) | ||
739 | 385 | args+=( | ||
740 | 386 | '--create-prefix[create the path leading up to the branch when missing]' | ||
741 | 387 | '--overwrite[ignore differences, overwrite unconditionally]' | ||
742 | 388 | '--remember[remember the specified location as a default]' | ||
743 | 389 | '*:local repository:_files -/' | ||
744 | 390 | ) | ||
745 | 391 | _bzr_completeParents | ||
746 | 392 | ;; | ||
747 | 393 | |||
748 | 394 | (clean-tree) | ||
749 | 395 | args+=( | ||
750 | 396 | '--dry-run[show files to delete instead of deleting them]' | ||
751 | 397 | '--ignored[delete all ignored files]' | ||
752 | 398 | '--detritus[delete conflict files, merge backups, failed self-tests, *~, *.tmp, etc]' | ||
753 | 399 | ) | ||
754 | 400 | ;; | ||
755 | 401 | |||
756 | 402 | (uncommit) | ||
757 | 403 | args+=( | ||
758 | 404 | '--dry-run[do not make any changes]' | ||
759 | 405 | '--force[say "yes" to all questions]' | ||
760 | 406 | '(-r --revision)'{--revision=,-r}'[the earliest revision to delete]:rev:' | ||
761 | 407 | '(-v --verbose)'{--verbose,-v}'[display more information]' | ||
762 | 408 | ) | ||
763 | 409 | ;; | ||
764 | 410 | |||
765 | 411 | (sign-my-commits) | ||
766 | 412 | args+=( '--dry-run[do not actually sign anything]' ) | ||
767 | 413 | ;; | ||
768 | 414 | |||
769 | 415 | (*) | ||
770 | 416 | _message "unknown bzr command completion: $cmd" | ||
771 | 417 | return 1 | ||
772 | 418 | ;; | ||
773 | 419 | esac | ||
774 | 420 | |||
775 | 421 | _arguments -s "$args[@]" && ret=0 | ||
776 | 422 | return $ret | ||
777 | 0 | \ No newline at end of file | 423 | \ No newline at end of file |
778 | 1 | 424 | ||
779 | === added file 'zsh_completion/_kde-sc-build-status' | |||
780 | --- zsh_completion/_kde-sc-build-status 1970-01-01 00:00:00 +0000 | |||
781 | +++ zsh_completion/_kde-sc-build-status 2011-09-19 15:44:21 +0000 | |||
782 | @@ -0,0 +1,2 @@ | |||
783 | 1 | #compdef kde-sc-build-status | ||
784 | 2 | _message "no more arguments" | ||
785 | 0 | \ No newline at end of file | 3 | \ No newline at end of file |
786 | 1 | 4 | ||
787 | === added file 'zsh_completion/_kgetsource' | |||
788 | --- zsh_completion/_kgetsource 1970-01-01 00:00:00 +0000 | |||
789 | +++ zsh_completion/_kgetsource 2011-09-19 15:44:21 +0000 | |||
790 | @@ -0,0 +1,48 @@ | |||
791 | 1 | #compdef kgetsource | ||
792 | 2 | #_arguments '1:name of the package:_getpackages' '2:version of the package:_print_valid_version' '3:series:_series' | ||
793 | 3 | function _name() { | ||
794 | 4 | |||
795 | 5 | #TODO: do something with following: ssh ftpubuntu@ftpmaster.kde.org ls -c /home/ftpubuntu/stable/4.7.0/src/ | ||
796 | 6 | if ( [[ ${+_kubuntu_completion_cache_packages} -eq 0 ]] || | ||
797 | 7 | _cache_invalid KUBUNTU_PACKAGES_CACHE) && ! _retrieve_cache KUBUNTU_PACKAGES_CACHE; | ||
798 | 8 | then | ||
799 | 9 | _kubuntu_completion_cache_packages=( | ||
800 | 10 | ${(f)"$(kshowbranches| grep "lp:~kubuntu-packagers/kubuntu-packaging/" |sed 's/lp:\~kubuntu-packagers\/kubuntu-packaging\///' 2>/dev/null)"} | ||
801 | 11 | ) | ||
802 | 12 | |||
803 | 13 | _store_cache KUBUNTU_PACKAGES_CACHE _kubuntu_completion_cache_packages | ||
804 | 14 | fi | ||
805 | 15 | typeset -gH _kubuntu_completion_cache_packages | ||
806 | 16 | |||
807 | 17 | compadd -a _kubuntu_completion_cache_packages | ||
808 | 18 | } | ||
809 | 19 | |||
810 | 20 | function _version() { | ||
811 | 21 | if ( [[ ${+_kubuntu_completion_cache_versions} -eq 0 ]] || | ||
812 | 22 | _cache_invalid KUBUNTU_VERSIONS_CACHE) && ! _retrieve_cache KUBUNTU_VERSIONS_CACHE; | ||
813 | 23 | then | ||
814 | 24 | _kubuntu_completion_cache_versions=( | ||
815 | 25 | ${(f)"$(khighestversion highest stable)"} ${(f)"$(khighestversion highest unstable)"} | ||
816 | 26 | ) | ||
817 | 27 | |||
818 | 28 | _store_cache KUBUNTU_VERSIONS_CACHE _kubuntu_completion_cache_versions | ||
819 | 29 | fi | ||
820 | 30 | typeset -gH _kubuntu_completion_cache_versions | ||
821 | 31 | |||
822 | 32 | compadd -a _kubuntu_completion_cache_versions | ||
823 | 33 | } | ||
824 | 34 | |||
825 | 35 | function _series() { | ||
826 | 36 | #do something with words[CURRENT-1] | ||
827 | 37 | echo words[CURRENT-1] | ||
828 | 38 | __series=('unstable' 'stable') | ||
829 | 39 | typeset -gH __series | ||
830 | 40 | compadd -a __series | ||
831 | 41 | } | ||
832 | 42 | |||
833 | 43 | local ret=1 | ||
834 | 44 | _arguments \ | ||
835 | 45 | ':package name:_name' \ | ||
836 | 46 | ':version:_version' \ | ||
837 | 47 | ':series:_series' && ret=0 | ||
838 | 48 | return ret | ||
839 | 0 | \ No newline at end of file | 49 | \ No newline at end of file |
840 | 1 | 50 | ||
841 | === added file 'zsh_completion/_klinksource' | |||
842 | --- zsh_completion/_klinksource 1970-01-01 00:00:00 +0000 | |||
843 | +++ zsh_completion/_klinksource 2011-09-19 15:44:21 +0000 | |||
844 | @@ -0,0 +1,5 @@ | |||
845 | 1 | #compdef klinksource | ||
846 | 2 | |||
847 | 3 | #TODO: make it work | ||
848 | 4 | |||
849 | 5 | _arguments "1:tar to link:_files -g '*-?*.tar.(gz|bz2|xz|lzma)'" | ||
850 | 0 | \ No newline at end of file | 6 | \ No newline at end of file |
851 | 1 | 7 | ||
852 | === added file 'zsh_completion/_kshowbranches' | |||
853 | --- zsh_completion/_kshowbranches 1970-01-01 00:00:00 +0000 | |||
854 | +++ zsh_completion/_kshowbranches 2011-09-19 15:44:21 +0000 | |||
855 | @@ -0,0 +1,2 @@ | |||
856 | 1 | #compdef kshowbranches | ||
857 | 2 | _message "no more arguments" | ||
858 | 0 | \ No newline at end of file | 3 | \ No newline at end of file |
859 | 1 | 4 | ||
860 | === added file 'zsh_completion/_kshowseries' | |||
861 | --- zsh_completion/_kshowseries 1970-01-01 00:00:00 +0000 | |||
862 | +++ zsh_completion/_kshowseries 2011-09-19 15:44:21 +0000 | |||
863 | @@ -0,0 +1,2 @@ | |||
864 | 1 | #compdef kshowseries | ||
865 | 2 | _message "no more arguments" | ||
866 | 0 | \ No newline at end of file | 3 | \ No newline at end of file |
867 | 1 | 4 | ||
868 | === added file 'zsh_completion/_kubuntu-update-symbols' | |||
869 | --- zsh_completion/_kubuntu-update-symbols 1970-01-01 00:00:00 +0000 | |||
870 | +++ zsh_completion/_kubuntu-update-symbols 2011-09-19 15:44:21 +0000 | |||
871 | @@ -0,0 +1,2 @@ | |||
872 | 1 | #compdef kubuntu-update-symbols | ||
873 | 2 | _message "no more arguments" | ||
874 | 0 | \ No newline at end of file | 3 | \ No newline at end of file |