aboutsummaryrefslogtreecommitdiff
path: root/main.go
diff options
context:
space:
mode:
authorBen Burwell <ben@benburwell.com>2019-08-13 12:24:10 -0400
committerBen Burwell <ben@benburwell.com>2019-08-13 12:51:10 -0400
commit8df0e5aa7d4dc43b1384d91a820c9a748ccbea6b (patch)
tree35c444471794fe82a4d5a036a6174627b5ef61fa /main.go
initial commit
Diffstat (limited to 'main.go')
-rw-r--r--main.go28
1 files changed, 28 insertions, 0 deletions
diff --git a/main.go b/main.go
new file mode 100644
index 0000000..27a4abb
--- /dev/null
+++ b/main.go
@@ -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)
+ }
+}