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

Function siteOutputToTarget

cmd/site.go:627–637  ·  view source on GitHub ↗
(content string)

Source from the content-addressed store, hash-verified

625}
626
627func siteOutputToTarget(content string) {
628 if siteOutput != "" {
629 if err := os.WriteFile(siteOutput, []byte(content+"\n"), 0644); err != nil {
630 Error(fmt.Sprintf("Failed to write to %s: %s", siteOutput, err))
631 os.Exit(1)
632 }
633 Info(fmt.Sprintf("Output written to %s", siteOutput))
634 } else {
635 fmt.Println(content)
636 }
637}
638
639func splitAndTrimSite(s string) []string {
640 parts := strings.Split(s, ",")

Callers 6

site.goFile · 0.85
renderQueryTableFunction · 0.85
renderAggregationTableFunction · 0.85
renderBreakdownTableFunction · 0.85
renderTimeseriesTableFunction · 0.85
renderErrorGroupsTableFunction · 0.85

Calls 2

ErrorFunction · 0.85
InfoFunction · 0.85

Tested by

no test coverage detected