MCPcopy Create free account
hub / github.com/cronitorio/cronitor-cli / maintenanceOutputToTarget

Function maintenanceOutputToTarget

cmd/maintenance.go:400–410  ·  view source on GitHub ↗
(content string)

Source from the content-addressed store, hash-verified

398}
399
400func maintenanceOutputToTarget(content string) {
401 if maintenanceOutput != "" {
402 if err := os.WriteFile(maintenanceOutput, []byte(content+"\n"), 0644); err != nil {
403 Error(fmt.Sprintf("Failed to write to %s: %s", maintenanceOutput, err))
404 os.Exit(1)
405 }
406 Info(fmt.Sprintf("Output written to %s", maintenanceOutput))
407 } else {
408 fmt.Println(content)
409 }
410}

Callers 1

maintenance.goFile · 0.85

Calls 2

ErrorFunction · 0.85
InfoFunction · 0.85

Tested by

no test coverage detected