From b7763416f8a1e4940a10336d3a8b9fbbb879f414 Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Mon, 12 Feb 2018 17:30:16 +0300 Subject: Clone and fetch git repositories --- bpkg/package.hxx | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-) (limited to 'bpkg/package.hxx') diff --git a/bpkg/package.hxx b/bpkg/package.hxx index 00a54d6..322fb2b 100644 --- a/bpkg/package.hxx +++ b/bpkg/package.hxx @@ -200,25 +200,28 @@ namespace bpkg // repository_location // - #pragma db value struct _repository_location { - string url; + repository_url url; repository_type type; }; - // Note that the type() call fails for an empty repository location. - // - #pragma db map type(repository_location) as(_repository_location) \ - to({(?).string (), \ - (?).empty () ? bpkg::repository_type::bpkg : (?).type ()}) \ - from(bpkg::repository_location ((?).url, (?).type)) + #pragma db map type(repository_url) as(string) \ + to((?).string ()) \ + from(bpkg::repository_url (?)) #pragma db map type(repository_type) as(string) \ to(to_string (?)) \ from(bpkg::to_repository_type (?)) + // Note that the type() call fails for an empty repository location. + // + #pragma db map type(repository_location) as(_repository_location) \ + to({(?).url (), \ + (?).empty () ? bpkg::repository_type::bpkg : (?).type ()}) \ + from(bpkg::repository_location (std::move ((?).url), (?).type)) + // repository // #pragma db object pointer(shared_ptr) session @@ -629,8 +632,9 @@ namespace bpkg // certificate // // Information extracted from a repository X.509 certificate. The actual - // certificate is stored on disk as .bpkg/certs/.pem (we have - // to store it as a file because that's the only way to pass it to openssl). + // certificate is stored on disk as .bpkg/certificates/.pem (we + // have to store it as a file because that's the only way to pass it to + // openssl). // // If a repository is not authenticated (has no certificate/signature, // called unauth from now on), then we ask for the user's confirmation and -- cgit v1.1