From 1ab83e42e24dcc8f6e7f0abb6d76bb5c06a8f189 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Sun, 31 Jan 2016 12:48:40 +0200 Subject: Add support for man page generation/install/dist --- load/.gitignore | 4 ++-- load/buildfile | 8 +++---- load/load.cli | 72 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ load/load.cxx | 2 +- load/options.cli | 72 -------------------------------------------------------- 5 files changed, 79 insertions(+), 79 deletions(-) create mode 100644 load/load.cli delete mode 100644 load/options.cli (limited to 'load') diff --git a/load/.gitignore b/load/.gitignore index 2f464c5..49afbe2 100644 --- a/load/.gitignore +++ b/load/.gitignore @@ -1,3 +1,3 @@ -options -options.?xx +*-options +*-options.?xx brep-load diff --git a/load/buildfile b/load/buildfile index c3a324f..6b72dae 100644 --- a/load/buildfile +++ b/load/buildfile @@ -9,12 +9,12 @@ import libs += libodb%lib{odb} include ../brep/ -exe{brep-load}: \ -{ cxx}{ load } \ -{hxx ixx cxx}{ options } \ +exe{brep-load}: \ +{ cxx}{ load } \ +{hxx ixx cxx}{ load-options } \ ../brep/lib{brep} $libs cli.options += -I $src_root --include-with-brackets --include-prefix load \ --guard-prefix LOAD -{hxx ixx cxx}{options}: cli{options} +{hxx ixx cxx}{load-options}: cli{load} diff --git a/load/load.cli b/load/load.cli new file mode 100644 index 0000000..751d1bd --- /dev/null +++ b/load/load.cli @@ -0,0 +1,72 @@ +// file : load/load.cli +// copyright : Copyright (c) 2014-2016 Code Synthesis Ltd +// license : MIT; see accompanying LICENSE file + +include ; +include ; // uint16_t + +"\section=1" +"\name=brep-load" +"\summary=load build2 repositories into database" + +{ + " ", + + "\h|SYNOPSIS| + + \cb{brep-load --help}\n + \cb{brep-load --version}\n + \c{\b{brep-load} [] } + + \h|DESCRIPTION| + + \cb{brep-load} reads the list of repositories from the specified + configuration , fetches their manifest files, and loads the repository + and package information into the database, suitable for consumption by the + \cb{brep} web module. + + Note that \cb{brep-load} expects the database schema to have already been + created using \l{brep-migrate(1)}." +} + +class options +{ + "\h|OPTIONS|" + + std::string --db-user|-u + { + "", + "Database user name. If not specified, then operating system (login) + name is used." + } + + std::string --db-password + { + "", + "Database password. If not specified, then login without password is + expected to work." + } + + std::string --db-name|-n = "brep" + { + "", + "Database name. If not specified, then '\cb{brep}' is used by default." + } + + std::string --db-host|-h + { + "", + "Database host name, address, or socket. If not specified, then connect + to \cb{localhost} using the operating system-default mechanism + (Unix-domain socket, etc)." + } + + std::uint16_t --db-port|-p = 0 + { + "", + "Database port number. If not specified, the default port is used." + } + + bool --help {"Print usage information and exit."} + bool --version {"Print version and exit."} +}; diff --git a/load/load.cxx b/load/load.cxx index e2a318c..993de7e 100644 --- a/load/load.cxx +++ b/load/load.cxx @@ -28,7 +28,7 @@ #include #include -#include +#include using namespace std; using namespace odb::core; diff --git a/load/options.cli b/load/options.cli deleted file mode 100644 index df91606..0000000 --- a/load/options.cli +++ /dev/null @@ -1,72 +0,0 @@ -// file : load/options.cli -// copyright : Copyright (c) 2014-2016 Code Synthesis Ltd -// license : MIT; see accompanying LICENSE file - -include ; -include ; // uint16_t - -"\section=1" -"\name=brep-load" -"\summary=load repositories into database" - -{ - " ", - - "\h|SYNOPSIS| - - \cb{brep-load --help}\n - \cb{brep-load --version}\n - \c{\b{brep-load} [] } - - \h|DESCRIPTION| - - \cb{brep-load} reads the list of repositories from the specified - configuration , fetches their manifest files, and loads the repository - and package information into the database, suitable for consumption by the - \cb{brep} web module. - - Note that \cb{brep-load} expects the database schema to have already been - created using \l{brep-migrate(1)}." -} - -class options -{ - "\h|OPTIONS|" - - std::string --db-user|-u - { - "", - "Database user name. If not specified, then operating system (login) - name is used." - } - - std::string --db-password - { - "", - "Database password. If not specified, then login without password is - expected to work." - } - - std::string --db-name|-n = "brep" - { - "", - "Database name. If not specified, then '\cb{brep}' is used by default." - } - - std::string --db-host|-h - { - "", - "Database host name, address, or socket. If not specified, then connect - to \cb{localhost} using the operating system-default mechanism - (Unix-domain socket, etc)." - } - - std::uint16_t --db-port|-p = 0 - { - "", - "Database port number. If not specified, the default port is used." - } - - bool --help {"Print usage information and exit."} - bool --version {"Print version and exit."} -}; -- cgit v1.1