X-Git-Url: https://yaffs.net/gitweb/?a=blobdiff_plain;f=vendor%2Fdrush%2Fdrush%2Fsrc%2FCommand%2FRemoteCommandProxy.php;fp=vendor%2Fdrush%2Fdrush%2Fsrc%2FCommand%2FRemoteCommandProxy.php;h=488f4033e378624e5baad735f85c6ea9002ee730;hb=af6d1fb995500ae68849458ee10d66abbdcfb252;hp=0000000000000000000000000000000000000000;hpb=680c79a86e3ed402f263faeac92e89fb6d9edcc0;p=yaffs-website diff --git a/vendor/drush/drush/src/Command/RemoteCommandProxy.php b/vendor/drush/drush/src/Command/RemoteCommandProxy.php new file mode 100644 index 000000000..488f4033e --- /dev/null +++ b/vendor/drush/drush/src/Command/RemoteCommandProxy.php @@ -0,0 +1,51 @@ +redispatchHook = $redispatchHook; + + // Put in a special input definition to avoid option validation errors. + $this->setDefinition(new IndiscriminateInputDefinition()); + + // Put in a placeholder array argument to avoid validation errors. + $this->addArgument( + 'arguments', + InputArgument::IS_ARRAY, + 'Proxy for command arguments' + ); + } + + protected function execute(InputInterface $input, OutputInterface $output) + { + $this->redispatchHook->redispatchIfRemote($input); + $name = $this->getName(); + throw new \Exception("Command $name could not be executed remotely."); + } +}