NAME

bdep-config – manage project build configurations

SYNOPSIS

bdep config add    [options] [prj-spec] [@cfg-name] cfg-dir
bdep config create [options] [prj-spec] [@cfg-name] cfg-dir [cfg-args]
bdep config list   [options] [prj-spec] [cfg-spec...]
bdep config move   [options] [prj-spec] cfg-spec cfg-dir
bdep config rename [options] [prj-spec] cfg-spec cfg-name
bdep config remove [options] [prj-spec] cfg-spec... | --all|-a
bdep config set    [options] [prj-spec] cfg-spec... | --all|-a
                   [--[no-]default]
                   [--[no-]forward]
                   [--[no-]auto-sync]

cfg-spec = @cfg-name | --config|-c cfg-dir
prj-spec = --directory|-d prj-dir
cfg-args = [bpkg-options] [--existing|-e | (module | cfg-var)...]

DESCRIPTION

The config command provides the following subcommands for managing project's build configurations. If no project directory is specified, then the current working directory is assumed.

CONFIG SUBCOMMANDS

add
create
The add subcommand adds an existing bpkg(1) build configuration in directory cfg-dir to the project's build configuration set. The create subcommand creates a new configuration in directory cfg-dir by executing the bpkg-cfg-create(1) command and passing to it cfg-args, if any. It then proceeds as add by adding the new configuration to the project's build configuration set.

In both subcommands, if cfg-name is specified, then the added configuration is given this name. Several bdep commands can use such names as a more convenient way to specify build configurations (see bdep-projects-configs(1) for details).

As a shortcut, if cfg-name is not specified and cfg-dir is a simple path that starts with @, then it is treated as the name and the configuration directory is assumed to be prj-dir-cfg-name. Note that in case of create, cfg-dir must be preceded with -- (double dash) option to disambiguate it from @cfg-name. For example, assuming the project directory is hello:

$ bdep config add @clang                        # ../hello-clang
$ bdep config create -- @gcc cc config.cxx=g++  # ../hello-gcc

Unless the --no-default option is specified, the first added or created build configuration is designated as the default. Several bdep commands use such a configuration by default if no configuration was specified explicitly (see bdep-projects-configs(1) for details). To make a subsequently added configuration the default use the --default option.

The default build configuration is also designated as forwarded unless the --no-forward option is specified or another configuration is already designated as forwarded. When a project is initialized in a forwarded build configuration, its source directory is configured to forward to this configuration (see b(1) for details on forwarded configurations). To forward to a non-default configuration use the --forward option.

Unless the --no-auto-sync option is specified, an added or created build configuration will be automatically synchronized on every build system invocation. Note that this flag affects the entire build configuration and if multiple projects share the same configuration, then they must have a consistent auto-synchronization setting.

list
The list subcommand prints the list of build configurations associated with the project. Unless one or more configurations are specified explicitly, list prints all the associate configurations. Note that the output is written to STDOUT, not STDERR.
move
The move subcommand assigns the specified build configuration a new directory. It is normally used after moving/renaming the configuration directory. Note that an explicit bdep-sync(1) command is required for this change to take effect. See bdep-projects-configs(1) for various ways to specify a build configuration.
rename
The rename subcommand gives the specified build configuration a new name. See bdep-projects-configs(1) for various ways to specify a build configuration.
remove
The remove subcommand removes one or more build configurations from the project's build configuration set. Note that only configurations that have no initialized packages can be removed. See bdep-projects-configs(1) for various ways to specify build configurations.
set
The set subcommand modifies various properties of one or more build configurations associated with the project. See bdep-projects-configs(1) for various ways to specify build configurations.

The properties that can be modified include the default (--[no-]default), forward (--[no-]forward), and auto-synchronization (--[no-]auto-sync) flags. Note that changing any of these flags requires an explicit bdep-sync(1) command to take effect.

CONFIG OPTIONS

--default
Make the added or created configuration the default.
--no-default
Don't make the first added or created configuration the default.
--forward
Make the added or created configuration forwarded.
--no-forward
Don't make the added or created configuration forwarded.
--auto-sync
Make the added or created configuration automatically synchronized.
--no-auto-sync
Don't make the added or created configuration automatically synchronized.
--existing|-e
Initialize a bpkg configuration based on an existing build system configuration.
--wipe
Wipe the configuration directory clean before creating the new configuration.
--all|-a
Use all build configurations.
--config|-c dir
Specify the build configuration as a directory.
--directory|-d dir
Assume project/package is in the specified directory rather than in the current working directory.
--config-name|-n name
Specify the build configuration as a name.
--config-id num
Specify the build configuration as an id.

COMMON OPTIONS

The common options are summarized below with a more detailed description available in bdep-common-options(1).

-v
Print essential underlying commands being executed.
-V
Print all underlying commands being executed.
--quiet|-q
Run quietly, only printing error messages.
--verbose level
Set the diagnostics verbosity to level between 0 and 6.
--jobs|-j num
Number of jobs to perform in parallel.
--no-progress
Suppress progress indicators for long-lasting operations, such as network transfers, building, etc.
--bpkg path
The package manager program to be used for build configuration management.
--bpkg-option opt
Additional option to be passed to the package manager program.
--build path
The build program to be used to build packages.
--build-option opt
Additional option to be passed to the build program.
--curl path
The curl program to be used for network operations.
--curl-option opt
Additional option to be passed to the curl program.
--pager path
The pager program to be used to show long text.
--pager-option opt
Additional option to be passed to the pager program.
--options-file file
Read additional options from file.

BUGS

Send bug reports to the users@build2.org mailing list.