Skip to content

Commit

Permalink
GitException if no custom section is available in config file
Browse files Browse the repository at this point in the history
  • Loading branch information
ticktackk committed Apr 13, 2018
1 parent 86dda48 commit a6e0dc6
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
use Symfony\Component\Console\Input\InputOption;
use Symfony\Component\Console\Output\OutputInterface;
use Symfony\Component\Console\Question\Question;
use TickTackk\DeveloperTools\Git\GitException;
use TickTackk\DeveloperTools\Git\GitRepository;
use XF\Cli\Command\AddOnActionTrait;
use XF\Util\File;
Expand Down Expand Up @@ -92,11 +93,18 @@ protected function execute(InputInterface $input, OutputInterface $output)
File::writeFile($repoRoot . $ds . '.gitignore', $globalGitIgnore, false);
}

$customSubDir = $git->config()->get('custom.subdir')->execute();
if (!empty($customSubDir))
try
{
$repoRoot .= ($ds . $customSubDir);
$customSubDir = $git->config()->get('custom.subdir')->execute();
if (!empty($customSubDir))
{
$repoRoot .= ($ds . $customSubDir);
}
}
catch (GitException $e)
{
}

$uploadDirectory = $repoRoot . $ds . 'upload';

if (is_dir($repoRoot))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"admin/developerTools_developer_options.html": {
"version_id": 1000031,
"version_string": "1.0.0 Beta 1",
"hash": "d1cdb294e23965d662ad5cf39bc54682"
"hash": "cfe751e70061c56e1b5ddf3ede0f2128"
},
"admin/developerTools_template_modification_edit_style_id.html": {
"version_id": 1000012,
Expand Down

0 comments on commit a6e0dc6

Please sign in to comment.