~robertgzr/yamlfs

c6875f71b9c0dc4c07fe5ab2350ff2e0145e17c1 — Robert Günzler 1 year, 9 months ago cba22b0 master
print only actual debug logs to stderr
1 files changed, 3 insertions(+), 3 deletions(-)

M cmd/yamlfs/main.go
M cmd/yamlfs/main.go => cmd/yamlfs/main.go +3 -3
@@ 113,7 113,7 @@ func main() {
		}
	}
	if len(undefinedVariables) > 0 {
		fmt.Fprintf(os.Stderr, "missing %d variables\n", len(undefinedVariables))
		fmt.Fprintf(os.Stdout, "missing %d variables\n", len(undefinedVariables))
		os.Exit(1)
	}
	var buf bytes.Buffer


@@ 125,7 125,7 @@ func main() {
		}
	}
	if debug {
		fmt.Fprintf(os.Stderr, "--- TEMPLATE ---\n%s\n---\n", buf.String())
		fmt.Fprintf(os.Stdout, "--- TEMPLATE ---\n%s\n---\n", buf.String())
	}
	// parse the yaml
	tree, err := yamlfs.NewTreeFromReader(&buf)


@@ 140,7 140,7 @@ func main() {
	}

	if listActions {
		fmt.Fprintf(os.Stderr, "--- TREE ---\n%s------------\n", yamlfs.TreeToString(tree))
		fmt.Fprintf(os.Stdout, "--- TREE ---\n%s------------\n", yamlfs.TreeToString(tree))
		os.Exit(0)
	}