aboutsummaryrefslogtreecommitdiff
path: root/cmd/vartan/root.go
blob: 3dda70ce1a6d6bb26f3776723fcecee0d87f0414 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
package main

import (
	"os"
)

func Execute() error {
	cmd := os.Args[1]
	args := os.Args[2:]

	if cmd == "compile" {
		return runCompile(args)
	} else if cmd == "parse" {
		return runParse(args)
	} else if cmd == "show" {
		return runShow(args)
	} else if cmd == "test" {
		return runTest(args)
	}

	return nil // FIXME
}