Adds class var options to some system commands

CmdPy, CmdScripts, CmdService, CmdServerLoad and 
plural of Switch is Switches in docstring
This commit is contained in:
BlauFeuer 2018-03-02 07:31:33 -05:00 committed by GitHub
parent cd0283d4e7
commit 8cd21defca

View file

@ -245,6 +245,7 @@ class CmdPy(COMMAND_DEFAULT_CLASS):
""" """
key = "@py" key = "@py"
aliases = ["!"] aliases = ["!"]
options = ("time", "edit")
locks = "cmd:perm(py) or perm(Developer)" locks = "cmd:perm(py) or perm(Developer)"
help_category = "System" help_category = "System"
@ -328,6 +329,7 @@ class CmdScripts(COMMAND_DEFAULT_CLASS):
""" """
key = "@scripts" key = "@scripts"
aliases = ["@globalscript", "@listscripts"] aliases = ["@globalscript", "@listscripts"]
options = ("start", "stop", "kill", "validate")
locks = "cmd:perm(listscripts) or perm(Admin)" locks = "cmd:perm(listscripts) or perm(Admin)"
help_category = "System" help_category = "System"
@ -521,6 +523,7 @@ class CmdService(COMMAND_DEFAULT_CLASS):
key = "@service" key = "@service"
aliases = ["@services"] aliases = ["@services"]
options = ("list", "start", "stop", "delete")
locks = "cmd:perm(service) or perm(Developer)" locks = "cmd:perm(service) or perm(Developer)"
help_category = "System" help_category = "System"
@ -672,7 +675,7 @@ class CmdServerLoad(COMMAND_DEFAULT_CLASS):
Usage: Usage:
@server[/mem] @server[/mem]
Switch: Switches:
mem - return only a string of the current memory usage mem - return only a string of the current memory usage
flushmem - flush the idmapper cache flushmem - flush the idmapper cache
@ -703,6 +706,7 @@ class CmdServerLoad(COMMAND_DEFAULT_CLASS):
""" """
key = "@server" key = "@server"
aliases = ["@serverload", "@serverprocess"] aliases = ["@serverload", "@serverprocess"]
options = ("mem", "flushmem")
locks = "cmd:perm(list) or perm(Developer)" locks = "cmd:perm(list) or perm(Developer)"
help_category = "System" help_category = "System"