diff options
author | Laurent Bachelier <laurent@bachelier.name> | 2010-05-29 01:19:03 +0200 |
---|---|---|
committer | Laurent Bachelier <laurent@bachelier.name> | 2010-05-29 01:19:03 +0200 |
commit | 942fb3cc9a0d1d752cacaa10dd5504c65dde16c2 (patch) | |
tree | 16921f9df3d4cdfb3c5e397e3ce0325c98f9e4a0 | |
parent | Workaround for Python 2.5; simplified namespaces (diff) | |
download | confman-942fb3cc9a0d1d752cacaa10dd5504c65dde16c2.tar.xz |
Simpler code
-rw-r--r-- | confman.py | 12 |
1 files changed, 3 insertions, 9 deletions
@@ -184,6 +184,8 @@ class ProgrammableAction(Action): Get limited environment execution. This function could be overloaded to add some custom methods. """ + options = self.config.options + def redirect(filename): raise SymlinkForwarder("_"+filename) @@ -193,15 +195,7 @@ class ProgrammableAction(Action): def ignore(): raise IgnoreForwarder() - exec_env = \ - { - "options": self.config.options, - "redirect": redirect, - "empty": empty, - "ignore": ignore, - } - - return exec_env + return locals() def check(self): source = self.source_path() |