Show More
@@ -211,10 +211,15 b' def hg_completer(self,event):' | |||
|
211 | 211 | |
|
212 | 212 | |
|
213 | 213 | |
|
214 | __bzr_commands = None | |
|
215 | ||
|
214 | 216 | def bzr_commands(): |
|
217 | global __bzr_commands | |
|
218 | if __bzr_commands is not None: | |
|
219 | return __bzr_commands | |
|
215 | 220 | out = os.popen('bzr help commands') |
|
216 |
|
|
|
217 | ||
|
221 | __bzr_commands = [l.split()[0] for l in out] | |
|
222 | return __bzr_commands | |
|
218 | 223 | |
|
219 | 224 | def bzr_completer(self,event): |
|
220 | 225 | """ Completer for bazaar commands """ |
@@ -1,12 +1,7 b'' | |||
|
1 | 1 | import os,sys,shutil |
|
2 | 2 | |
|
3 | repo = "http://ipython.scipy.org/svn/ipython/ipython/branches/0.7.3" | |
|
4 | basename = 'ipython' | |
|
5 | workdir = './mkdist' | |
|
6 | ||
|
7 | workdir = os.path.abspath(workdir) | |
|
3 | basever = '0.8.3' | |
|
8 | 4 | |
|
9 | print "working at",workdir | |
|
10 | 5 | def oscmd(c): |
|
11 | 6 | print ">",c |
|
12 | 7 | s = os.system(c) |
@@ -14,15 +9,24 b' def oscmd(c):' | |||
|
14 | 9 | print "Error",s |
|
15 | 10 | sys.exit(s) |
|
16 | 11 | |
|
12 | def verinfo(): | |
|
13 | ||
|
14 | out = os.popen('bzr version-info') | |
|
15 | pairs = (l.split(':',1) for l in out) | |
|
16 | d = dict(((k,v.strip()) for (k,v) in pairs)) | |
|
17 | return d | |
|
18 | ||
|
19 | basename = 'ipython' | |
|
20 | ||
|
21 | #tarname = '%s.r%s.tgz' % (basename, ver) | |
|
22 | oscmd('update_revnum.py') | |
|
23 | ||
|
24 | ver = verinfo() | |
|
17 | 25 | |
|
18 | assert not os.path.isdir(workdir) | |
|
19 | os.mkdir(workdir) | |
|
20 | os.chdir(workdir) | |
|
26 | if ver['branch-nick'] == 'ipython': | |
|
27 | tarname = 'ipython-%s.bzr.r%s.tgz' % (basever, ver['revno']) | |
|
28 | else: | |
|
29 | tarname = 'ipython-%s.bzr.r%s.%s.tgz' % (basever, ver['revno'], ver['branch-nick']) | |
|
30 | ||
|
31 | oscmd('bzr export ' + tarname) | |
|
21 | 32 | |
|
22 | oscmd('svn export %s %s' % (repo,basename)) | |
|
23 | ver = os.popen('svnversion ../..').read().strip() | |
|
24 | tarname = '%s.r%s.tgz' % (basename, ver) | |
|
25 | oscmd('tar czvf ../%s %s' % (tarname, basename)) | |
|
26 | print "Produced: ",os.path.abspath('../' + tarname) | |
|
27 | os.chdir('/') | |
|
28 | shutil.rmtree(workdir) |
General Comments 0
You need to be logged in to leave comments.
Login now