invoiceninja/app/Console/Commands/GenerateResources.php

64 lines
1 KiB
PHP
Raw Normal View History

2017-01-30 21:40:43 +02:00
<?php
namespace App\Console\Commands;
2016-02-22 10:30:14 +02:00
use File;
use Illuminate\Console\Command;
/**
2017-01-30 21:40:43 +02:00
* Class GenerateResources.
*/
2016-02-22 10:30:14 +02:00
class GenerateResources extends Command
{
/**
* @var string
*/
2016-02-22 10:30:14 +02:00
protected $name = 'ninja:generate-resources';
/**
* @var string
*/
2016-02-22 10:30:14 +02:00
protected $description = 'Generate Resouces';
/**
* Create a new command instance.
*/
public function __construct()
{
parent::__construct();
}
/**
* Execute the command.
*
* @return void
*/
public function fire()
{
$texts = File::getRequire(base_path() . '/resources/lang/en/texts.php');
foreach ($texts as $key => $value) {
if (is_array($value)) {
echo $key;
} else {
echo "$key => $value\n";
}
}
}
/**
* @return array
*/
2016-02-22 10:30:14 +02:00
protected function getArguments()
{
return [];
2016-02-22 10:30:14 +02:00
}
/**
* @return array
*/
2016-02-22 10:30:14 +02:00
protected function getOptions()
{
return [];
2016-02-22 10:30:14 +02:00
}
}