MCPcopy Index your code
hub / github.com/voidint/g / clean

Function clean

cli/clean.go:30–42  ·  view source on GitHub ↗
(*cli.Context)

Source from the content-addressed store, hash-verified

28)
29
30func clean(*cli.Context) (err error) {
31 entries, err := os.ReadDir(downloadsDir)
32 if err != nil {
33 return cli.Exit(errstring(err), 1)
34 }
35
36 for i := range entries {
37 if err = os.RemoveAll(filepath.Join(downloadsDir, entries[i].Name())); err == nil {
38 fmt.Println("Remove", entries[i].Name())
39 }
40 }
41 return nil
42}

Callers

nothing calls this directly

Calls 2

errstringFunction · 0.85
NameMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…