Skip to content

Commit

Permalink
optional repodata packages.conda
Browse files Browse the repository at this point in the history
  • Loading branch information
AntoinePrv committed Aug 31, 2023
1 parent 15f7bf6 commit 698c420
Showing 1 changed file with 7 additions and 17 deletions.
24 changes: 7 additions & 17 deletions libmamba/src/core/repo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -489,25 +489,15 @@ namespace mamba
// An temporary buffer for managing null terminated strings
std::string tmp_buffer = {};

set_repo_solvables(
m_pool,
srepo(*this),
m_metadata.url,
default_subdir,
repodata.at("packages"),
tmp_buffer
);
if (auto iter = repodata.find("packages"); (iter != repodata.end()) && iter->is_object())
{
set_repo_solvables(m_pool, srepo(*this), m_metadata.url, default_subdir, *iter, tmp_buffer);
}

if (!Context::instance().use_only_tar_bz2)
if (auto iter = repodata.find("packages.conda");
(iter != repodata.end()) && iter->is_object() && !Context::instance().use_only_tar_bz2)
{
set_repo_solvables(
m_pool,
srepo(*this),
m_metadata.url,
default_subdir,
repodata.at("packages.conda"),
tmp_buffer
);
set_repo_solvables(m_pool, srepo(*this), m_metadata.url, default_subdir, *iter, tmp_buffer);
}
}

Expand Down

0 comments on commit 698c420

Please sign in to comment.