diff options
Diffstat (limited to 'loader')
-rw-r--r-- | loader/buildfile | 2 | ||||
-rw-r--r-- | loader/loader.cxx | 14 |
2 files changed, 15 insertions, 1 deletions
diff --git a/loader/buildfile b/loader/buildfile index d4e4678..bb5684e 100644 --- a/loader/buildfile +++ b/loader/buildfile @@ -15,6 +15,6 @@ loader = cxx{loader} cli.cxx{options} exe{brep-loader}: $loader ../brep/libso{brep} $libs cli.options += -I $src_root --include-with-brackets --include-prefix loader \ ---guard-prefix LOADER +--guard-prefix LOADER --cli-namespace brep::cli cli.cxx{options}: cli{options} diff --git a/loader/loader.cxx b/loader/loader.cxx index ee3e5fa..e9f5566 100644 --- a/loader/loader.cxx +++ b/loader/loader.cxx @@ -426,6 +426,20 @@ load_repositories (const shared_ptr<repository>& rp, database& db) // rp->url = move (rm.url); + // @@ Should we throw if url is not available for external repository ? + // Can, basically, repository be available on the web but have no web + // interface associated ? + // + if (rp->url) + { + // Normalize web interface url adding trailing '/' if not present. + // + auto& u (*rp->url); + assert (!u.empty ()); + if (u.back () != '/') + u += '/'; + } + if (rp->internal) { rp->email = move (rm.email); |