MCPcopy Create free account
hub / github.com/256dpi/gcode / writeFileString

Function writeFileString

cmd/gcode/helpers.go:45–60  ·  view source on GitHub ↗
(path string, s string)

Source from the content-addressed store, hash-verified

43}
44
45func writeFileString(path string, s string) {
46 // create g-code file
47 file, err := os.Create(path)
48 if err != nil {
49 panic(err)
50 }
51
52 // make sure file gets closed
53 defer file.Close()
54
55 // parse file
56 _, err = file.WriteString(s)
57 if err != nil {
58 panic(err)
59 }
60}

Callers 1

svgFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected