diff --git a/arfc/main.go b/arfc/main.go new file mode 100644 index 0000000..99de746 --- /dev/null +++ b/arfc/main.go @@ -0,0 +1,21 @@ +package arfc + +import "os" +import "fmt" +import "github.com/sashakoshka/arf" + +func main () { + if len(os.Args) != 2 { + fmt.Println("XXX please specify module path and output path") + } + + inPath := os.Args[0] + outPath := os.Args[1] + file := os.OpenFile(outPath, os.WRONLY | os.CREATE, 0655) + + err := arf.CompileModule(inPath, outFile) + if err != nil { + fmt.Println(err) + os.Exit(1) + } +}