package function import ( "strings" "tangled.org/cosmeak.tngl.sh/weave/internal/generator" ) func (f Function) Emit()(generator.File, error) { content := strings.Join(f.commands, "\n") return generator.File{ Path: "data/%namespace%/function/" + f.name + ".mcfunction", Content: []byte(content), }, nil }