Skip to content

Instantly share code, notes, and snippets.

@bosunski
Last active September 30, 2018 21:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bosunski/d760f3471915ab835e70fe1c666c98ee to your computer and use it in GitHub Desktop.
Save bosunski/d760f3471915ab835e70fe1c666c98ee to your computer and use it in GitHub Desktop.
CommandBoilerplate.php
<?php
/**
* Joomla! Content Management System
*
* @copyright Copyright (C) 2005 - 2018 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
namespace Joomla\CMS\Console;
defined('JPATH_PLATFORM') or die;
use Joomla\Console\AbstractCommand;
/**
* Console command for checking if there are pending extension updates
*
* @since 4.0.0
*/
class SampleCommand extends AbstractCommand
{
/**
* Execute the command.
*
* @return integer The exit code for the command.
*
* @since 4.0.0
*/
public function execute(): int
{
return 0;
}
/**
* Initialise the command.
*
* @return void
*
* @since 4.0.0
*/
protected function initialise()
{
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment