// file : bpkg/drop.cxx -*- C++ -*- // copyright : Copyright (c) 2014-2015 Code Synthesis Ltd // license : MIT; see accompanying LICENSE file #include #include // cout #include // reverse_iterate() #include #include #include #include #include #include #include #include #include #include #include using namespace std; using namespace butl; namespace bpkg { void drop (const drop_options& o, cli::scanner& args) { tracer trace ("drop"); const dir_path& c (o.directory ()); level4 ([&]{trace << "configuration: " << c;}); if (!args.more ()) fail << "package name argument expected" << info << "run 'bpkg help drop' for more information"; database db (open (c, trace)); // Note that the session spans all our transactions. The idea here is // that selected_package objects in the satisfied_packages list below // will be cached in this session. When subsequent transactions modify // any of these objects, they will modify the cached instance, which // means our list will always "see" their updated state. // session s; } }