MCPcopy Index your code
hub / github.com/celer-pkg/celer / changeDirOwnership

Method changeDirOwnership

pkgcache/cache_setup.go:239–246  ·  view source on GitHub ↗
(username string)

Source from the content-addressed store, hash-verified

237}
238
239func (n *NFSServerSetup) changeDirOwnership(username string) error {
240 if output, err := cmd.NewExecutor("", "chown", "-R", username+":"+username, n.nfsDir).ExecuteOutput(); err != nil {
241 return fmt.Errorf("failed to change ownership of %q to %q -> %s -> %w", n.nfsDir, username, output, err)
242 }
243
244 color.PrintHint("✔ change ownership of %q to %q", n.nfsDir, username)
245 return nil
246}
247
248func (n *NFSServerSetup) changeModeForDirsFiles() error {
249 dirPerm := fmt.Sprintf("%o", fileio.CacheDirPerm)

Callers 1

SetupMethod · 0.95

Calls 3

NewExecutorFunction · 0.92
PrintHintFunction · 0.92
ExecuteOutputMethod · 0.80

Tested by

no test coverage detected