Skip to content

Commit

Permalink
master export: also export branches with no matching doil repo
Browse files Browse the repository at this point in the history
  • Loading branch information
daniwe4 committed Sep 5, 2024
1 parent fd82225 commit c326071
Showing 1 changed file with 5 additions and 8 deletions.
13 changes: 5 additions & 8 deletions app/src/Commands/Pack/ExportCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -270,14 +270,6 @@ protected function exportProjectConfig(OutputInterface $output, string $path, st
return $this->repo_manager->repoUrlExists($repo);
});

if (count($local_repos) == 0 && count($global_repos) == 0) {
$this->writer->error(
$output,
"Can't find branch '$branch' inside the available remotes inside directory '$path/volumes/ilias'."
);
return self::FAILURE;
}

$local_cat_ilias_repos = [];
if (count($local_repos) > 0) {
$local_cat_ilias_repos = array_filter($local_repos, function(Repo $local_repo) {
Expand Down Expand Up @@ -310,6 +302,11 @@ protected function exportProjectConfig(OutputInterface $output, string $path, st

if (!$found && count($global_repos)) {
$repo = array_shift($global_repos);
$found = true;
}

if (!$found && count($repos) > 0) {
$repo = array_shift($repos);
}
}

Expand Down

0 comments on commit c326071

Please sign in to comment.