Skip to content

Hhfab usability #463

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 7 commits into
base: master
Choose a base branch
from
Draft

Hhfab usability #463

wants to merge 7 commits into from

Conversation

pau-hedgehog
Copy link
Contributor

Minor improvements in hhfab generate and versions

@pau-hedgehog pau-hedgehog self-assigned this Mar 15, 2025
@pau-hedgehog pau-hedgehog force-pushed the hhfab_usability branch 3 times, most recently from 6347a9d to 207f4f1 Compare March 31, 2025 16:14
When no fab.yaml is found, the versions command shows the
release versions instead of an error

If there are overrides in fab.yaml, they are shown

Signed-off-by: Pau Capdevila <[email protected]>
Previously, only the file name was logged, leaving users
unaware of the wiring diagram exact location

Signed-off-by: Pau Capdevila <[email protected]>
Previously, multiple files present in include dir could be
loaded and, in some cases error, leaving users unaware of
additional files containing errors

Signed-off-by: Pau Capdevila <[email protected]>
migrates to urfave/v3 and uses urfave/cli-docs/v3

Signed-off-by: Pau Capdevila <[email protected]>
Signed-off-by: Pau Capdevila <[email protected]>
Signed-off-by: Pau Capdevila <[email protected]>
Hides help command and version

There was duplicity between help and --help
And versions and --version

help command still shows in completion

Signed-off-by: Pau Capdevila <[email protected]>
@pau-hedgehog
Copy link
Contributor Author

Versions improved:

16:33:16 INF Printing versions of all components (overridden←→release)
fabric:
  agent: v0.72.0-pre-bcm-order-fix-2←→v0.71.4
  alloy: v1.1.1
  api: v0.72.0-pre-bcm-order-fix-2←→v0.71.4
  boot: v0.72.0-pre-bcm-order-fix-2←→v0.71.4
  controller: v0.72.0-pre-bcm-order-fix-2←→v0.71.4
  ctl: v0.72.0-pre-bcm-order-fix-2←→v0.71.4
  dhcpd: v0.72.0-pre-bcm-order-fix-2←→v0.71.4
  nos:
    sonic-bcm-base: v4.4.0←→v4.4.2
    sonic-bcm-campus: v4.4.0←→v4.4.2
    sonic-bcm-vs: v4.4.0←→v4.4.2
  proxy: 1.9.1
  proxyChart: v0.72.0-pre-bcm-order-fix-2←→v0.71.4
...

Autocompletion:

$ hhfab vlab <TAB><TAB>
generate           inspect-switches   serial             setup-peerings     show-tech          switch             up                 
help               release-test       seriallog          setup-vpcs         ssh                test-connectivity  wait-switches

Autogenerated doc:

$ hhfab doc
19:28:53 INF Hedgehog Fabricator version=v0.36.0-7-gd9af8f5b-dirty-2C1824 workdir="" cache=""
Documentation generated at docs/hhfab.md

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants