Skip to content
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

Make the default completion command accessible #1523

Closed

Commits on Nov 3, 2021

  1. Make the default completion accessible

    Fixes spf13#1507
    
    This allows a program to set whatever field it wants on the default
    completion command before calling rootCmd.Execute().  For example,
    
      cobra.CompletionCmd.Hidden = true  // To make the command hidden
    
    or/and
    
      cobra.CompletionCmd.Use = "shellcomplete" // To rename the command
    
    Signed-off-by: Marc Khouzam <marc.khouzam@montreal.ca>
    marckhouzam committed Nov 3, 2021
    Configuration menu
    Copy the full SHA
    3ae090b View commit details
    Browse the repository at this point in the history
  2. Allow overriding Run/RunE of comp cmds

    Signed-off-by: Marc Khouzam <marc.khouzam@montreal.ca>
    marckhouzam committed Nov 3, 2021
    Configuration menu
    Copy the full SHA
    9fa0b83 View commit details
    Browse the repository at this point in the history