---
name: "cfgtool"
section: "8"
platform: "linux"
package: "cfgtool"
version: "1.5-1"
release: "Debian 1.3 (Bo)"
platforms: ["linux"]
url: "https://new.carta.tech/cfgtool"
---

# cfgtool(8)

manipulate system configuration variables

## NAME

cfgtool - manipulate system configuration variables

## SYNOPSIS

**cfgtool** \[--create variable value\] \[--destroy variable\] \[--get variable\] \[--set variable value\] \[--is-true variable\] \[--is-false variable\] \[--exists variable\] \[--lock\] \[--unlock\] \[--locked\] \[--list-all\] \[--create-all\] \[--set-all\] \[--repository directory\] \[--init-repository directory\]

## DESCRIPTION

**cfgtool** manages a database of system configuration variables.

This should not be used to configure application type programs. Applications should use their own configuration file, because **cfgtool** is not portable.

## OPTIONS

- *--init-repository directory*

  Create and initialize the repository. The directory is where the variables will be stored.

- *--get variable*

  Print value of  *variable* to stdout.

- *--set variable value*

  Set value of *variable* to  *value* The variable must exist.

- *--create variable value*

  Create a new variable and set its initial value. It is not an error for the variable to exist already. If it does, nothing happens; the value of the variable is *not* changed.

- *--destroy variable*

  Destroy a variable.

- *--is-true variable*

  Check whether variable exists and contains the value "yes". Don't output anything, just set the exit code.

- *--is-false variable*

  Opposite of --is-true: condition is true, if variable exists and contains the value "no" (actually, any value but "yes").

- *--lock*

  Lock variable repository. This is needed only when you need to lock the repository over several invocations of  **cfgtool**. The repository is locked automatically, if it hasn't already been locked, but an implicit lock is also removed automatically. Avoid locking the repository for long periods of time.

- *--unlock*

  Unlock variable repository.

- *--locked*

  The variable repository was locked by an earlier process, but we own the lock. This prevents creating an implicit lock. If we created an explicit lock with --lock already, the implicit lock fails and then the whole operation fails. This must be the first option, except for --repository, if it used at all.

- *--list*

  List all existing variable names, one per line.

- *--exists variable*

  Test whether a variable exists.

- *--list-all*

  Output octet stream to stdout that contains all variables in repository.

- *--create-all file*

  Read octet stream from file *file* (use "-" for stdin) and create all missing variables.

- *--set-all file*

  Like --create-all, but also sets existing variables.

- *--repository directory*

  Use *directory* as the repository, instead of default location. Must be first.

## BUGS

Nothing that involves help files is currently working.
