From 3ff749c98c4593ff35b2f82de222db9f97954f29 Mon Sep 17 00:00:00 2001 From: Dimitri Sokolyuk Date: Sun, 18 Sep 2016 19:17:50 +0200 Subject: Move to cmd --- ps/main.go | 34 ---------------------------------- 1 file changed, 34 deletions(-) delete mode 100644 ps/main.go (limited to 'ps/main.go') diff --git a/ps/main.go b/ps/main.go deleted file mode 100644 index 478e52c..0000000 --- a/ps/main.go +++ /dev/null @@ -1,34 +0,0 @@ -package main - -import ( - "io/ioutil" - "log" - "os" - "strings" - - "dim13.org/robo/gc" - "github.com/llgcode/ps" -) - -var postscriptContent string - -func main() { - src, err := os.OpenFile("tiger.ps", 0, 0) - if err != nil { - log.Println("can't find postscript file.") - return - } - defer src.Close() - bytes, err := ioutil.ReadAll(src) - postscriptContent = string(bytes) - if err != nil { - panic(err) - } - - GC := gc.NewGraphicContext() - - interpreter := ps.NewInterpreter(GC) - reader := strings.NewReader(postscriptContent) - interpreter.Execute(reader) - -} -- cgit v1.2.3