dev-centralize #1

Merged
jantytgat merged 11 commits from dev-centralize into main 2025-06-09 19:13:38 +00:00
31 changed files with 1140 additions and 35 deletions
Showing only changes of commit 4112e27ba5 - Show all commits

View File

@ -48,7 +48,7 @@ func (c Config) getRootCommand() (*cobra.Command, error) {
Long: long,
PersistentPreRunE: persistentPreRunFuncE,
PersistentPostRunE: persistentPostRunFuncE,
RunE: runFuncE,
RunE: RunCatchFuncE,
SilenceErrors: true,
SilenceUsage: true,
}
@ -69,9 +69,9 @@ func (c Config) getRootCommand() (*cobra.Command, error) {
return cmd, nil
}
func (c Config) ParseVersion() (semver.Version, error) {
return semver.Parse(c.Version.Full)
}
// func (c Config) ParseVersion() (semver.Version, error) {
// return semver.Parse(c.Version.Full)
// }
func (c Config) RegisterCommand(cmd Commander, f func(*cobra.Command)) {
appCmd.AddCommand(cmd.Initialize(f))

View File

@ -96,7 +96,7 @@ func persistentPostRunFuncE(cmd *cobra.Command, args []string) error {
return nil
}
// appRunE is an empty catch function to allow overrides through persistentPreRunE
func runFuncE(cmd *cobra.Command, args []string) error {
// RunCatchFuncE is an empty catch function to allow overrides through persistentPreRunE
func RunCatchFuncE(cmd *cobra.Command, args []string) error {
return nil
}