aboutsummaryrefslogtreecommitdiff
path: root/bpkg/rep-add.hxx
blob: 3ad18411e95a213481ff36cfa43e84da3d617b86 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
// file      : bpkg/rep-add.hxx -*- C++ -*-
// copyright : Copyright (c) 2014-2019 Code Synthesis Ltd
// license   : MIT; see accompanying LICENSE file

#ifndef BPKG_REP_ADD_HXX
#define BPKG_REP_ADD_HXX

#include <libbpkg/manifest.hxx>

#include <bpkg/types.hxx>
#include <bpkg/forward.hxx> // transaction, repository
#include <bpkg/utility.hxx>

#include <bpkg/rep-add-options.hxx>

namespace bpkg
{
  int
  rep_add (const rep_add_options&, cli::scanner& args);

  // Create the new repository if it is not in the database yet or update its
  // location if it differs. Then add it as a complement to the root
  // repository if it is not already.
  //
  shared_ptr<repository>
  rep_add (const common_options&, transaction&, const repository_location&);
}

#endif // BPKG_REP_ADD_HXX