diff options
author | makkalot <makkalot@gmail.com> | 2008-08-07 15:26:17 +0300 |
---|---|---|
committer | makkalot <makkalot@gmail.com> | 2008-08-07 15:26:17 +0300 |
commit | 11833cb069e0723b1395c28b64ce753a3a9acdec (patch) | |
tree | fe346fa6595b765a85ec2796922a25b27069d14e /func/minion/modules/command.py | |
parent | 8578022bb04931e391e78d1ef16b27fe9a02b120 (diff) | |
download | func-11833cb069e0723b1395c28b64ce753a3a9acdec.tar.gz func-11833cb069e0723b1395c28b64ce753a3a9acdec.tar.xz func-11833cb069e0723b1395c28b64ce753a3a9acdec.zip |
the series of exporting the minion modules to UI command module
Diffstat (limited to 'func/minion/modules/command.py')
-rw-r--r-- | func/minion/modules/command.py | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/func/minion/modules/command.py b/func/minion/modules/command.py index cc463cf..20a6ccf 100644 --- a/func/minion/modules/command.py +++ b/func/minion/modules/command.py @@ -42,3 +42,29 @@ class Command(func_module.FuncModule): if os.access(command, os.X_OK): return True return False + + def register_method_args(self): + """ + The argument export method + """ + #common type in both descriptions + command = { + 'type':'string', + 'optional':False, + 'description':'The command that is going to be used', + } + + return { + 'run':{ + 'args':{ + 'command':command + }, + 'description':'Run a specified command' + }, + 'exists':{ + 'args':{ + 'command':command + }, + 'description':'Check if specific command exists' + } + } |