MCPcopy Create free account
hub / github.com/cli/cli / removeCopilot

Function removeCopilot

pkg/cmd/copilot/copilot.go:470–480  ·  view source on GitHub ↗
(installDir string)

Source from the content-addressed store, hash-verified

468}
469
470func removeCopilot(installDir string) error {
471 if _, err := os.Stat(installDir); os.IsNotExist(err) {
472 return fmt.Errorf("failed to remove Copilot CLI: Copilot CLI not installed through `gh`")
473 }
474
475 if err := os.RemoveAll(installDir); err != nil {
476 return fmt.Errorf("failed to remove Copilot CLI: %w", err)
477 }
478
479 return nil
480}

Callers 2

TestRemoveCopilotFunction · 0.85
runCopilotFunction · 0.85

Calls 1

ErrorfMethod · 0.65

Tested by 1

TestRemoveCopilotFunction · 0.68