fortify / fcli

fcli is a command-line utility for interacting with various Fortify products
https://fortify.github.io/fcli/
Other
31 stars 18 forks source link

Reconsider FoD command aliases #362

Closed rsenden closed 1 year ago

rsenden commented 1 year ago

Some FoD commands have aliases for which it is questionable whether they provide any benefit or will ever be used. In particular:

kadraman commented 1 year ago

I agree on the naming and thought the aliases were a bit clunky- I think we agree on "app", "release" and "microservice"?

lookup-items is a weird one because it is just a dumping ground for types that appear across various FoD operations. Its not really a user-level entity as you don't need to know it exists if using the UI. In theory we shouldn't need to expose it as the individual commands should be able to refer to its types/vales as individual options as some do. However we don't have complete API coverage and allow users to do simple fod rest call in which case they might want to refer to its values - and hence why its probably good to keep it the same as exposed via the API?

rsenden commented 1 year ago

Agree on app, release and microservice.

As for lookup-items, are you saying that this is only useful for the fcli fod rest call command, not any of the other fcli fod <entity> commands? In that case, what about moving this functionality to fcli fod rest lookup <name> or something similar?

rsenden commented 1 year ago

When removing command aliases, please make sure that these aliases are no longer being referenced in the resource bundles, both for these commands themselves, as in the descriptions of other commands/options. For example, the fcli fod app update command description refers to the app-rel and app-ms aliases:

image

rsenden commented 1 year ago

Also, please make sure that any option names referencing those entities only use the new, single entity name. For example, the fcli fod user update has an --add-apps / --add-applications option; we should probably only have --add-apps (same of course for --remove-applications, ...)

rsenden commented 1 year ago

Also, please make sure class names are consistent with entity names. For example, if we have release as the entity name, then the corresponding classes should be named FoDReleaseCommands and FoDRelease*Command.