From f9ebe2d1e920df001be2dd543a63677f8728f53d Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Thu, 8 Mar 2018 16:50:59 +0200 Subject: Handle command line project/packages discovery --- bdep/init.cxx | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) (limited to 'bdep/init.cxx') diff --git a/bdep/init.cxx b/bdep/init.cxx index 3e7998f..1e850b8 100644 --- a/bdep/init.cxx +++ b/bdep/init.cxx @@ -4,6 +4,7 @@ #include +#include #include using namespace std; @@ -15,10 +16,17 @@ namespace bdep { tracer trace ("init"); - //@@ TODO: validate project/config options for subcommands. + //@@ TODO: validate project/config options for sub-modes. + //@@ TODO: print project/package(s) being initialized. - for (const string& n: o.config_name ()) - text << n; + project_packages pp ( + find_project_packages (o, + o.empty () /* ignore_packages */)); + + text << pp.project; + + for (const dir_path& d: pp.packages) + text << " " << (pp.project / d); return 0; } -- cgit v1.1