for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace LaravelLangBundler\Commands;
use Illuminate\Console\Command;
use Illuminate\Filesystem\Filesystem;
class LaravelLangBundlerCommand extends Command
{
/**
* Filesystem instance.
*
* @var \Illuminate\Filesystem\Filesystem
*/
protected $filesystem;
* Set up command dependencies.
protected function setUp()
$this->filesystem = new Filesystem();
}
* Build path from path array.
* @param array $pathArray
* @param string $path
* @return string
protected function buildPath($pathArray, $path)
foreach ($pathArray as $directory) {
$path .= $directory.DIRECTORY_SEPARATOR;
if (!$this->filesystem->exists($path)) {
$this->filesystem->makeDirectory($path);
return $path;