170316b84SAndreas Gohr<?php 270316b84SAndreas Gohr 370316b84SAndreas Gohruse splitbrain\phpcli\Options; 470316b84SAndreas Gohr 570316b84SAndreas Gohr/** 670316b84SAndreas Gohr * DokuWiki Plugin @@PLUGIN_NAME@@ (CLI Component) 770316b84SAndreas Gohr * 870316b84SAndreas Gohr * @license GPL 2 http://www.gnu.org/licenses/gpl-2.0.html 970316b84SAndreas Gohr * @author @@AUTHOR_NAME@@ <@@AUTHOR_MAIL@@> 1070316b84SAndreas Gohr */ 1170316b84SAndreas Gohrclass @@PLUGIN_COMPONENT_NAME@@ extends \dokuwiki\Extension\CLIPlugin 1270316b84SAndreas Gohr{ 1370316b84SAndreas Gohr /** @inheritDoc */ 1470316b84SAndreas Gohr protected function setup(Options $options) 1570316b84SAndreas Gohr { 1670316b84SAndreas Gohr $options->setHelp('FIXME: What does this CLI do?'); 1770316b84SAndreas Gohr 1870316b84SAndreas Gohr // main arguments 1970316b84SAndreas Gohr $options->registerArgument('FIXME:argumentName', 'FIXME:argument description', 'FIXME:required? true|false'); 2070316b84SAndreas Gohr 2170316b84SAndreas Gohr // options 22*fe060d0dSAndreas Gohr // $options->registerOption( 23*fe060d0dSAndreas Gohr // 'FIXME:longOptionName', 24*fe060d0dSAndreas Gohr // 'FIXME: helptext for option', 25*fe060d0dSAndreas Gohr // 'FIXME: optional shortkey', 26*fe060d0dSAndreas Gohr // 'FIXME:needs argument? true|false', 27*fe060d0dSAndreas Gohr // 'FIXME:if applies only to subcommand: subcommandName' 28*fe060d0dSAndreas Gohr // ); 2970316b84SAndreas Gohr 3070316b84SAndreas Gohr // sub-commands and their arguments 3170316b84SAndreas Gohr // $options->registerCommand('FIXME:subcommandName', 'FIXME:subcommand description'); 32*fe060d0dSAndreas Gohr // $options->registerArgument( 33*fe060d0dSAndreas Gohr // 'FIXME:subcommandArgumentName', 34*fe060d0dSAndreas Gohr // 'FIXME:subcommand-argument description', 35*fe060d0dSAndreas Gohr // 'FIXME:required? true|false', 36*fe060d0dSAndreas Gohr // 'FIXME:subcommandName' 37*fe060d0dSAndreas Gohr // ); 3870316b84SAndreas Gohr } 3970316b84SAndreas Gohr 4070316b84SAndreas Gohr /** @inheritDoc */ 4170316b84SAndreas Gohr protected function main(Options $options) 4270316b84SAndreas Gohr { 4370316b84SAndreas Gohr // $command = $options->getCmd() 4470316b84SAndreas Gohr // $arguments = $options->getArgs() 4570316b84SAndreas Gohr } 4670316b84SAndreas Gohr} 47