aboutsummaryrefslogtreecommitdiff
path: root/bpkg/pkg-fetch.hxx
diff options
context:
space:
mode:
Diffstat (limited to 'bpkg/pkg-fetch.hxx')
-rw-r--r--bpkg/pkg-fetch.hxx17
1 files changed, 11 insertions, 6 deletions
diff --git a/bpkg/pkg-fetch.hxx b/bpkg/pkg-fetch.hxx
index cdd5256..8607178 100644
--- a/bpkg/pkg-fetch.hxx
+++ b/bpkg/pkg-fetch.hxx
@@ -1,5 +1,4 @@
// file : bpkg/pkg-fetch.hxx -*- C++ -*-
-// copyright : Copyright (c) 2014-2019 Code Synthesis Ltd
// license : MIT; see accompanying LICENSE file
#ifndef BPKG_PKG_FETCH_HXX
@@ -19,12 +18,12 @@ namespace bpkg
int
pkg_fetch (const pkg_fetch_options&, cli::scanner& args);
- // Fetch the package as an archive file and commit the transaction. Can
- // return a new selected package object, replacing the existing one.
+ // Fetch the package as an archive file and commit the transaction. Return
+ // the selected package object which may replace the existing one.
//
shared_ptr<selected_package>
pkg_fetch (const common_options&,
- const dir_path& configuration,
+ database&,
transaction&,
path archive,
bool replace,
@@ -32,12 +31,18 @@ namespace bpkg
bool simulate);
// Fetch the package from an archive-based repository and commit the
- // transaction. Can return a new selected package object, replacing the
+ // transaction. Return the selected package object which may replace the
// existing one.
//
+ // Note that both package and repository information configurations need to
+ // be passed.
+ //
+ // Also note that it should be called in session.
+ //
shared_ptr<selected_package>
pkg_fetch (const common_options&,
- const dir_path& configuration,
+ database& pdb,
+ database& rdb,
transaction&,
package_name,
version,