From d7f30907ed6ea25adfbb525c42417c74cd60f912 Mon Sep 17 00:00:00 2001 From: Mark McGranaghan Date: Sun, 23 Sep 2012 19:38:04 -0700 Subject: [PATCH] generalize --- tool/generate.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tool/generate.go b/tool/generate.go index b8316eb..2629140 100644 --- a/tool/generate.go +++ b/tool/generate.go @@ -16,7 +16,7 @@ func check(err error) { } } -func markdown(path, source string) string { +func pipedCmd(path, source string) string { cmd := exec.Command(path) in, err := cmd.StdinPipe() check(err) @@ -46,7 +46,7 @@ func main() { // binaries, remember their paths. markdownPath, err := exec.LookPath("markdown"); check(err) - fmt.Print(markdown(markdownPath, "## wat")) + fmt.Print(pipedCmd(markdownPath, "## wat")) // pygmentizePath, err := exec.LookPath("pygmentize") // check(err)