2018-11-13 21:55:59 +01:00
|
|
|
"""WordOps base controller."""
|
|
|
|
|
|
|
|
|
|
from cement.core.controller import CementBaseController, expose
|
|
|
|
|
from wo.core.variables import WOVariables
|
|
|
|
|
VERSION = WOVariables.wo_version
|
|
|
|
|
|
|
|
|
|
BANNER = """
|
|
|
|
|
WordOps v%s
|
2019-03-02 20:38:31 +01:00
|
|
|
Copyright (c) 2019 WordOps.
|
2018-11-13 21:55:59 +01:00
|
|
|
""" % VERSION
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class WOBaseController(CementBaseController):
|
|
|
|
|
class Meta:
|
|
|
|
|
label = 'base'
|
|
|
|
|
description = ("WordOps is the commandline tool to manage your"
|
|
|
|
|
" websites based on WordPress and Nginx with easy to"
|
|
|
|
|
" use commands")
|
|
|
|
|
arguments = [
|
|
|
|
|
(['-v', '--version'], dict(action='version', version=BANNER)),
|
|
|
|
|
]
|
|
|
|
|
|
|
|
|
|
@expose(hide=True)
|
|
|
|
|
def default(self):
|
|
|
|
|
self.app.args.print_help()
|