##// END OF EJS Templates
Clean up version info tools and remove bzr references.
Fernando Perez -
Show More
@@ -20,16 +20,16 b" for d in ['build','dist',pjoin('docs','build'),pjoin('docs','dist'),"
20 remove_tree(d)
20 remove_tree(d)
21
21
22 # Build source and binary distros
22 # Build source and binary distros
23 c('./setup.py sdist --formats=gztar,zip')
23 sh('./setup.py sdist --formats=gztar,zip')
24
24
25 # Build eggs
25 # Build eggs
26 c('python2.6 ./setupegg.py bdist_egg')
26 sh('python2.6 ./setupegg.py bdist_egg')
27
27
28 # Call the windows build separately, so that the extra Windows scripts don't
28 # Call the windows build separately, so that the extra Windows scripts don't
29 # get pulled into Unix builds (setup.py has code which checks for
29 # get pulled into Unix builds (setup.py has code which checks for
30 # bdist_wininst)
30 # bdist_wininst)
31 c("python setup.py bdist_wininst --install-script=ipython_win_post_install.py")
31 sh("python setup.py bdist_wininst --install-script=ipython_win_post_install.py")
32
32
33 # Change name so retarded Vista runs the installer correctly
33 # Change name so retarded Vista runs the installer correctly
34 c("rename 's/linux-i686/win32-setup/' dist/*.exe")
34 sh("rename 's/linux-i686/win32-setup/' dist/*.exe")
35 c("rename 's/linux-x86_64/win32-setup/' dist/*.exe")
35 sh("rename 's/linux-x86_64/win32-setup/' dist/*.exe")
@@ -21,5 +21,5 b" tar_name = '%s.tgz' % base_name"
21 start_dir = os.getcwd()
21 start_dir = os.getcwd()
22 cd('..')
22 cd('..')
23 git_tpl = 'git archive --format=tar --prefix={0}/ HEAD | gzip > {1}'
23 git_tpl = 'git archive --format=tar --prefix={0}/ HEAD | gzip > {1}'
24 c(git_tpl.format(base_name, tar_name))
24 sh(git_tpl.format(base_name, tar_name))
25 c('mv {0} tools/'.format(tar_name))
25 sh('mv {0} tools/'.format(tar_name))
@@ -11,14 +11,16 b' pjoin = os.path.join'
11 cd = os.chdir
11 cd = os.chdir
12
12
13 # Utility functions
13 # Utility functions
14 def c(cmd):
14 def sh(cmd):
15 """Run system command, raise SystemExit if it returns an error."""
15 """Run system command in shell, raise SystemExit if it returns an error."""
16 print "$",cmd
16 print "$",cmd
17 stat = os.system(cmd)
17 stat = os.system(cmd)
18 #stat = 0 # Uncomment this and comment previous to run in debug mode
18 #stat = 0 # Uncomment this and comment previous to run in debug mode
19 if stat:
19 if stat:
20 raise SystemExit("Command %s failed with code: %s" % (cmd, stat))
20 raise SystemExit("Command %s failed with code: %s" % (cmd, stat))
21
21
22 # Backwards compatibility
23 c = sh
22
24
23 def get_ipdir():
25 def get_ipdir():
24 """Get IPython directory from command line, or assume it's the one above."""
26 """Get IPython directory from command line, or assume it's the one above."""
@@ -39,17 +41,8 b' def get_ipdir():'
39
41
40 def compile_tree():
42 def compile_tree():
41 """Compile all Python files below current directory."""
43 """Compile all Python files below current directory."""
42 vstr = '.'.join(map(str,sys.version_info[:2]))
44 stat = os.system('python -m compileall .')
43 stat = os.system('python %s/lib/python%s/compileall.py .' %
44 (sys.prefix,vstr))
45 if stat:
45 if stat:
46 msg = '*** ERROR: Some Python files in tree do NOT compile! ***\n'
46 msg = '*** ERROR: Some Python files in tree do NOT compile! ***\n'
47 msg += 'See messages above for the actual file that produced it.\n'
47 msg += 'See messages above for the actual file that produced it.\n'
48 raise SystemExit(msg)
48 raise SystemExit(msg)
49
50
51 def version_info():
52 """Return bzr version info as a dict."""
53 out = os.popen('bzr version-info')
54 pairs = (l.split(':',1) for l in out)
55 return dict(((k,v.strip()) for (k,v) in pairs))
1 NO CONTENT: file was removed
NO CONTENT: file was removed
1 NO CONTENT: file was removed
NO CONTENT: file was removed
General Comments 0
You need to be logged in to leave comments. Login now