diff --git a/pj1-go/pj1.go b/pj1-go/pj1.go index 2012544..45e320a 100644 --- a/pj1-go/pj1.go +++ b/pj1-go/pj1.go @@ -10,16 +10,16 @@ import ( "git.bonsai.cool/kayprish/pj1/pj1-go/util" ) -// func main() { -// if len(os.Args) > 2 { -// fmt.Println("Usage: pj1-go [script]") -// os.Exit(64) -// } else if len(os.Args) == 2 { -// runFile(os.Args[0]) -// } else { -// runPrompt() -// } -// } +func main() { + if len(os.Args) > 2 { + fmt.Println("Usage: pj1-go [script]") + os.Exit(64) + } else if len(os.Args) == 2 { + runFile(os.Args[0]) + } else { + runPrompt() + } +} func runFile(path string) { bytes, err := ioutil.ReadFile(path)