Ğcli version 0.4.2 - shell auto-completion & ARM64 build

Added shell auto-completion & ARM64 build.

Full release notes (also available in the release page and in CHANGELOG.md):

[0.4.2] - 2025-05-16

Added / Changed

  • Extra command completion added which takes a --shell argument to generate a completions script for a specified shell.
    • Calling this command with gcli completion --help will provide detailed instructions to generate the completion script and register it for your shell (not necessary when using the .deb package that include and registers the completion scripts for bash, zsh and fish)

CI/CD

  • Adapted the Linux (amd64) build to:
    • generate the gcli-completion.bash, gcli-completion.zsh, gcli-completion.fish, gcli-completion.ps1 completion scripts
    • add the bash, zsh and fish completion scripts in the .deb package
  • Added the ARM64 build generating a binary and a .deb package that also include those completion scripts.

Fixed

  • None

Deprecated

  • Two commands are still deprecated and will be removed in a future release:
    • gcli vault list-files
    • gcli vault migrate

Removed

  • None
5 Likes

completion is great. Thanks

I notice json output is not effective yet

gcli vault list all --output-format json
error: unexpected argument '--output-format' found

NB : For “UPlanet v2”, I will use gcli through “batch processing” (and lots of derivation keys) so it needs “inline parameter” filling and “json output” for CLI

For the json output, it’s through a global argument (to be given before the first command):

-o, --output-format <OUTPUT_FORMAT>  Output format (human, json, ...) [default: human]

But it will only impact the commands that were adapted to take it into account.

This MR started by @poka contains adaptations for a lot of commands:

I can rebase it again and try to provide a release candidate version of it (there are a lot of the commands impacted I never used; so a bit harder to test).

Yes je viens de rebase la branche json-output sur master.
Ce serait bien de merger :slight_smile:

D’ailleurs je pense que ce serait bien de pouvoir switcher dans une config pour dire si on ne veut que des sorties json tous le temps par default ou non (mais pas obligatoire du tout).

Car gcli sera très utilisé dans des services SaaS.


Concernant les tests de relecture, je pense qu’on peut se permettre de relire le code pour voir si ça nous convient théoriquement, et pour ce qu’on ne sait pas tester, ce n’est peut être pas très grave, ce seront les users qui lèveront les bugs si il y en a.

2 Likes

J’ai fais une Release Candidate avec ces changements; n’hésitez pas à donner votre feedback.

Si aucun soucis majeur n’est rapporté d’ici quelque jours, on pourrait merger et faire une release normale.