python-tuf/docs/CLI.md
Vladimir Diaz 1b4c276ad0
Add more info to --verbose section of CLI.md
Signed-off-by: Vladimir Diaz <vladimir.v.diaz@gmail.com>
2018-01-30 16:11:35 -05:00

1.7 KiB

CLI examples

Note: This is a work in progress and subject to change.

Create a repository

Create a TUF repository in the current working directory. A cryptographic key is created and set for each top-level role. The Targets role does not sign for any targets nor does it delegate trust to any roles.

$ repo.py --init

Note: Support for arbitrary repo paths will be added in the near future. $ repo.py --init --path </path/to/repo>

By default, pw is used to encrypt the top-level key files created with --init. Instead, the user can enter a password on the command line, or be prompted for one.

$ repo.py --init --pw my_pw
$ repo.py --init --pw
Enter a password for the top-level role keys:
Confirm:

Create a TUF repository in the current working directory. A cryptographic key is not created nor set for each top-level role.

$ repo.py --init --bare

Create a TUF repository with consistent snapshots enabled. If enabled, all target filenames have their hash prepended.

$ repo.py --init --consistent_snapshot

Add a target file

More than one target file may be specified.

$ repo.py --add <foo.tar.gz> <bar.tar.gz>

Note: Support for directories will be added in the near future. $ repo.py --add </path/to/dir> [--recursive]

Verbosity

Set the verbosity of the logger (2, by default). Logger messages are saved to tuf.log in the current working directory.

$ repo.py --verbose <0-5>

Clean

Remove the files created via repo.py --init.

$ repo.py --clean