diff options
| author | Jason R. Coombs <jaraco@jaraco.com> | 2014-06-22 09:23:42 -0400 |
|---|---|---|
| committer | Jason R. Coombs <jaraco@jaraco.com> | 2014-06-22 09:23:42 -0400 |
| commit | f6b5e29275f9a54bda847de79760f24a613a3d28 (patch) | |
| tree | 6669f1ad56d804b1018e2412480ff255d991fc20 /setuptools/command/saveopts.py | |
| parent | 97fbee720d6dd5bda37dc2a945d60ec056d49d9e (diff) | |
| parent | 8e3f9d3253d1d0fb820dad4249d5110d017595c1 (diff) | |
| download | python-setuptools-git-f6b5e29275f9a54bda847de79760f24a613a3d28.tar.gz | |
Merge Pull Request 67 from bb://agronholm/bitbucket
Diffstat (limited to 'setuptools/command/saveopts.py')
| -rwxr-xr-x | setuptools/command/saveopts.py | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/setuptools/command/saveopts.py b/setuptools/command/saveopts.py index 7209be4c..611cec55 100755 --- a/setuptools/command/saveopts.py +++ b/setuptools/command/saveopts.py @@ -1,7 +1,6 @@ -import distutils, os -from setuptools import Command from setuptools.command.setopt import edit_config, option_base + class saveopts(option_base): """Save command-line options to a file""" @@ -13,12 +12,11 @@ class saveopts(option_base): for cmd in dist.command_options: - if cmd=='saveopts': - continue # don't save our own options! + if cmd == 'saveopts': + continue # don't save our own options! - for opt,(src,val) in dist.get_option_dict(cmd).items(): - if src=="command line": - settings.setdefault(cmd,{})[opt] = val + for opt, (src, val) in dist.get_option_dict(cmd).items(): + if src == "command line": + settings.setdefault(cmd, {})[opt] = val edit_config(self.filename, settings, self.dry_run) - |
