X-Git-Url: https://git.cweiske.de/shpub.git/blobdiff_plain/059c6ab77b8e63210b9afc266d62c9f543d4d7ae..6c791f2d0c159d56c570802c8d9bd3612262aa9e:/src/shpub/Command/Reply.php diff --git a/src/shpub/Command/Reply.php b/src/shpub/Command/Reply.php index 6b3bc94..61e4c59 100644 --- a/src/shpub/Command/Reply.php +++ b/src/shpub/Command/Reply.php @@ -6,6 +6,8 @@ class Command_Reply extends Command_AbstractProps public static function opts(\Console_CommandLine $optParser) { $cmd = $optParser->addCommand('reply'); + $cmd->description = 'Create a reply'; + static::addOptHtml($cmd); static::optsGeneric($cmd); $cmd->addArgument( 'url', @@ -18,7 +20,7 @@ class Command_Reply extends Command_AbstractProps 'text', [ 'optional' => false, - 'multiple' => true, + 'multiple' => false, 'description' => 'Reply text', ] ); @@ -33,8 +35,8 @@ class Command_Reply extends Command_AbstractProps $req = new Request($this->cfg->host, $this->cfg); $req->setType('entry'); - $req->addProperty('content', implode(' ', $cmdRes->args['text'])); $req->addProperty('in-reply-to', $url); + $req->addContent($cmdRes->args['text'], $cmdRes->options['html']); $this->handleGenericOptions($cmdRes, $req); $res = $req->send();