summaryrefslogtreecommitdiffstats
path: root/Lib/distutils/command/bdist_msi.py
diff options
context:
space:
mode:
authorCollin Winter <collinw@gmail.com>2007-08-30 03:52:21 (GMT)
committerCollin Winter <collinw@gmail.com>2007-08-30 03:52:21 (GMT)
commit5b7e9d76f39dbf63573519c178835f72e5a5027a (patch)
tree96b04b9d52d875c9f39d148d88efeafb5184fd35 /Lib/distutils/command/bdist_msi.py
parenta73bfee73da519a508e7d95bc55c1984ae7089bd (diff)
downloadcpython-5b7e9d76f39dbf63573519c178835f72e5a5027a.zip
cpython-5b7e9d76f39dbf63573519c178835f72e5a5027a.tar.gz
cpython-5b7e9d76f39dbf63573519c178835f72e5a5027a.tar.bz2
General cleanup, raise normalization in Lib/distutils.
Diffstat (limited to 'Lib/distutils/command/bdist_msi.py')
-rw-r--r--Lib/distutils/command/bdist_msi.py28
1 files changed, 14 insertions, 14 deletions
diff --git a/Lib/distutils/command/bdist_msi.py b/Lib/distutils/command/bdist_msi.py
index 5225bed..d313a50 100644
--- a/Lib/distutils/command/bdist_msi.py
+++ b/Lib/distutils/command/bdist_msi.py
@@ -81,7 +81,7 @@ class PyDialog(Dialog):
Return the button, so that events can be associated"""
return self.pushbutton(name, int(self.w*xpos - 28), self.h-27, 56, 17, 3, title, next)
-class bdist_msi (Command):
+class bdist_msi(Command):
description = "create a Microsoft Installer (.msi) binary distribution"
@@ -114,7 +114,7 @@ class bdist_msi (Command):
boolean_options = ['keep-temp', 'no-target-compile', 'no-target-optimize',
'skip-build']
- def initialize_options (self):
+ def initialize_options(self):
self.bdist_dir = None
self.keep_temp = 0
self.no_target_compile = 0
@@ -125,7 +125,7 @@ class bdist_msi (Command):
self.install_script = None
self.pre_install_script = None
- def finalize_options (self):
+ def finalize_options(self):
if self.bdist_dir is None:
bdist_base = self.get_finalized_command('bdist').bdist_base
self.bdist_dir = os.path.join(bdist_base, 'msi')
@@ -133,30 +133,29 @@ class bdist_msi (Command):
if self.target_version:
if not self.skip_build and self.distribution.has_ext_modules()\
and self.target_version != short_version:
- raise DistutilsOptionError, \
- "target version can only be %s, or the '--skip_build'" \
- " option must be specified" % (short_version,)
+ raise DistutilsOptionError(
+ "target version can only be %s, or the '--skip_build'"
+ " option must be specified" % (short_version,))
else:
self.target_version = short_version
self.set_undefined_options('bdist', ('dist_dir', 'dist_dir'))
if self.pre_install_script:
- raise DistutilsOptionError, "the pre-install-script feature is not yet implemented"
+ raise DistutilsOptionError(
+ "the pre-install-script feature is not yet implemented")
if self.install_script:
for script in self.distribution.scripts:
if self.install_script == os.path.basename(script):
break
else:
- raise DistutilsOptionError, \
- "install_script '%s' not found in scripts" % \
- self.install_script
+ raise DistutilsOptionError(
+ "install_script '%s' not found in scripts"
+ % self.install_script)
self.install_script_key = None
- # finalize_options()
-
- def run (self):
+ def run(self):
if not self.skip_build:
self.run_command('build')
@@ -263,7 +262,8 @@ class bdist_msi (Command):
key = dir.add_file(file)
if file==self.install_script:
if self.install_script_key:
- raise DistutilsOptionError, "Multiple files with name %s" % file
+ raise DistutilsOptionError(
+ "Multiple files with name %s" % file)
self.install_script_key = '[#%s]' % key
cab.commit(db)