-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
eb14c32
commit 486ec8a
Showing
2 changed files
with
56 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
<?php | ||
|
||
defined('BASEPATH') or exit('No direct script access allowed'); | ||
|
||
/** | ||
* Class Command | ||
* | ||
* @author 713uk13m <[email protected]> | ||
* @copyright 713uk13m <[email protected]> | ||
*/ | ||
class Command extends HungNG_CI_Base_Controllers | ||
{ | ||
public function __construct() | ||
{ | ||
parent::__construct(); | ||
$this->load->helper('directory'); | ||
} | ||
|
||
public function index(): void | ||
{ | ||
if (!is_cli()) { | ||
show_404(); | ||
} | ||
ResponseOutput::writeLn('CodeIgniter Command Interface'); | ||
} | ||
|
||
public function clean_cache() | ||
{ | ||
if (!is_cli()) { | ||
show_404(); | ||
} | ||
$this->command_clean_cache_file(); | ||
} | ||
|
||
public function clean_opcache() | ||
{ | ||
if (!is_cli()) { | ||
show_404(); | ||
} | ||
$this->opcache_flush_reset(); | ||
} | ||
|
||
public function flush_logs() | ||
{ | ||
if (!is_cli()) { | ||
show_404(); | ||
} | ||
$this->default_base_flush_logs(); | ||
} | ||
} |