diff options
author | Ben Burwell <ben@benburwell.com> | 2019-08-13 12:24:10 -0400 |
---|---|---|
committer | Ben Burwell <ben@benburwell.com> | 2019-08-13 12:51:10 -0400 |
commit | 8df0e5aa7d4dc43b1384d91a820c9a748ccbea6b (patch) | |
tree | 35c444471794fe82a4d5a036a6174627b5ef61fa /main.go |
initial commit
Diffstat (limited to 'main.go')
-rw-r--r-- | main.go | 28 |
1 files changed, 28 insertions, 0 deletions
@@ -0,0 +1,28 @@ +package main + +import ( + "fmt" + "os" +) + +const ( + base = "/Users/ben/dotfiles" + dest = "/Users/ben" +) + +func main() { + if len(os.Args) < 2 { + fmt.Printf("usage: conf apply [files...]\n") + os.Exit(1) + } + switch os.Args[1] { + case "apply": + if err := apply(os.Args[2:]); err != nil { + fmt.Printf("%v\n", err) + os.Exit(1) + } + default: + fmt.Printf("unrecognized command: %s\n", os.Args[1]) + os.Exit(1) + } +} |