Command-line interface for Harbor.
Project description
harbor-cli
Table of Contents
Features
- 150+ commands
- Beautiful command-line interface powered by Typer and Rich.
- REPL mode (
harbor repl
) - TUI mode (
harbor tui
) - Tab completion for commands and options.
- Automatic retrying of failed requests
- Multiple output formats:
- Table
- JSON
- Large number of configuration options
- Authentication methods
- Table styling
- Output formats
- ... and more
Installation
It is highly recommended to install harbor-cli
with pipx. pipx installs the application in an isolated environment to avoid dependency conflicts, and makes it easy to upgrade or uninstall it afterwards.
MacOS
Install as a pipx app:
pipx install harbor-cli
or through Homebrew:
brew tap add unioslo/harbor-cli
brew install harbor-cli
Keyring functionality should work out of the box on MacOS >=11 with Python >=3.8.7.
Linux
pipx install harbor-cli
Depending on your Linux flavor and choice of keyring backend, you may need to install additional packages to enable keyring functionality. See the keyring documentation for more information.
If you need to inject a package into the application's pipx environment, use the pipx inject
command:
pipx inject harbor-cli <package to inject>
Windows
pipx install harbor-cli
Keyring functionality is untested on Windows, but should work out of the box. If you run into any issues, consult the keyring documentation for more information. Otherwise, please open an issue.
Documentation
Documentation can be found here.
The documentation includes extensive setup and usage guides, as well as a list of all commands and their options.
Usage
Installing the application puts harbor
in your PATH
, and can be invoked by typing harbor
in your terminal:
$ harbor --help
0.3.0 - 2024-06-26
Added
- Command:
project repos
to list repositories in a project. A more intuitive way to list repositories for a project than going throughrepository list
. --sbom-generation
option forproject create
andproject update
commands to enable automatic SBOM generation for the project.
Changed
- Styling of multiline help text in commands.
Removed
- Mentions of valid values from
project {create,update}
commands.
Fixed
- REPL closing when certain errors are raised.
artifact list
for artifacts with no extra attributes.
0.2.2 - 2024-03-01
Fixed
- Configuration option
verify_ssl
not having any effect.
0.2.1 - 2024-02-02
Added
- Help for MacOS users if Keychain is returning a
-25244
errSecInvalidOwnerEdit
error. self keyring
command to manage the keyring.self keyring status
to see information about the keyring used.
self config
command to manage the configuration file.- Has the same commands as
cli-config
, which is now deprecated.
- Has the same commands as
Changed
- Prompts are now printed to stderr instead of stdout for POSIX compliance.
- Newlines are now logged as spaces in the log file.
Fixed
- Coroutines not being properly cancelled when the application exits abnormally.
- Password not being stored in keyring after user is prompted for missing authentication info.
- Repeated keyring warnings if keyring is not available.
Deprecated
cli-config
command. Useself config
0.2.0 - 2023-12-21
Changed
- Automatic datetime log file naming now uses the tag
{dt}
(was{time}
). - Log file is now named
harbor-cli.log
by default (no longer includes datetime).- Automatic datetime naming is now opt-in instead of being the default.
Deprecated
{time}
tag for automatic datetime log file naming. Use{dt}
instead.[cache]
section in configuration file. Caching of API responses has been removed.
Removed
- Caching of API responses. This was a premature optimization that caused more problems than it solved. It will be re-introduced in a future release.
Fixed
- Double printing of messages in terminal if logging wasn't properly configured.
0.1.0 - 2023-12-06
Added
- Initial release.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file harbor_cli-0.3.0.tar.gz
.
File metadata
- Download URL: harbor_cli-0.3.0.tar.gz
- Upload date:
- Size: 3.6 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.12.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 721df57d861ba2afff0a1ca3805c8a08a718e65cc928283ffaa4c22e8159fa1e |
|
MD5 | b8895d6973e76db94aeabb938e665293 |
|
BLAKE2b-256 | b8ad03d8fcdf69d159adadfefeaac603588e5e55ba8cd0f0b4121ab3bac1293c |
File details
Details for the file harbor_cli-0.3.0-py3-none-any.whl
.
File metadata
- Download URL: harbor_cli-0.3.0-py3-none-any.whl
- Upload date:
- Size: 139.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.12.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | f90f674b2e550eb5427ed4cc7993e6c5f3355330224ddcb1fa0f81107e6f86b4 |
|
MD5 | 7a2c9e5662887f18617d1b8fdb4f81d5 |
|
BLAKE2b-256 | 72d17ceb3d3a0bb25c27dbec9236f4b8738db8e71e52051643c904b54d8e0951 |