Since there is no configuration file for cpt, the package manager is configured
through environment variables. These can be set per operation, or be set to your
shell configuration or ~/.profile. Here are the environment variables that
alter the behaviour of
Set the locations of your repositories. This is set similar to the
Unless this is set, the ~/.cache directory will be used instead.
The cache directory for
cpt. Default: $XDG_CACHE_HOME/cpt
If this is set to 0, a package installation will be aborted on conflicts. Default: 1
Program used to compress package tarballs. The values should be the default suffixes for the program. Available values are:
If this is set to 1, temporary build directories will not be removed after the given operation. Default: unset
If this is set to 0,
cpt-update will not fetch the repositories.
This behaviour can also be achieved by adding -n or --no-fetch
as an argument. Default: 0
If this is set to 1, some of the
cpt tools will continue regardless of
errors or skip certain checks. Here are some examples:
cpt-installwill install a package without verifying its manifest.
cpt-installwill install a package even when there are missing dependencies.
cpt-removewill remove packages even when there are other packages that depend on the current package.
This behaviour can also be achieved by adding -f or --force as an argument to those utilities.
Location for the hook file See Hooks. Default: unset
Normally, logs are deleted if the package is built successfully. If set to 1, logs will be kept even when the packages are built as intended. Default: 0
If this variable is set, the temporary files will be created with this variable
as the suffix, instead of the PID of the
cpt process. The advantage
is that you can know exactly where the build directory is located, while the
disadvantage is that there will be issues with multiple operations at the
same time. So the best way to use this variable is during one-time
CPT_PID=mesa cpt b mesa
By running the above, you will know that the created build directories will end with the *-mesa suffix.
If set to 0, the package manager will not prompt you for anything and will continue with the default action. This behaviour can also be achieved by adding -y or --no-prompt as an argument to some utilities. Default: 1
If this variable is set,
cpt will assume this as the system root, and
will install/remove/update/list packages assuming this is the system root.
This behaviour can also be achieved by adding --root as an argument to some utilities.
If set to 1,
cpt-build will run tests where a package has the
test build file. This behaviour can also be achieved by adding -t or --test
as an argument to
cpt-build. Default: 0
The directory to create the build files. This can be changed (for example to
/tmp) for building on RAM, saving SSD space, etc. Default: