This commit is contained in:
Kloadut 2012-10-08 23:02:26 +02:00
parent e34f6e0b4f
commit d30ef19b80
2 changed files with 31 additions and 20 deletions

View file

@ -6,6 +6,7 @@ import ldap
import ldap.modlist as modlist
import re
import getpass
sys.path.append('./') # Local temporary hack
def colorize(astr, color):
@ -59,7 +60,7 @@ def str_to_func(astr):
try:
func = getattr(mod, function)
except NameError:
except AttributeError:
raise YunoHostError(168, _('Function is not defined'))
else:
return func

View file

@ -33,7 +33,7 @@ gettext.install('YunoHost')
from yunohost import YunoHostError, str_to_func, colorize
action_dict = {
"""
Category/actions dictionnary
@ -50,16 +50,26 @@ action_dict = {
user_add(args) function in lib/yunohost_user.py
"""
action_dict = {
'user' : {
'help' : 'Manage users',
'actions' : {
'list' : 'List users',
'add' : 'Add user'
'add' : 'Create user',
#'update' : 'Update user informations',
#'delete' : 'Delete user',
#'info' : 'Show user informations'
}
},
'domain' : {
'help' : 'Manage domains',
'actions' : {}
'actions' : {
#'list' : 'List domains',
#'add' : 'Add domain',
#'remove' : 'Remove domain',
#'info' : 'Show domain informations',
#'renewcert' : 'Renew certificate for a domain'
}
},
'app' : {
'help' : 'Manage apps',