golf 0.1.2 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/golf/cli.rb +7 -3
- data/lib/golf/version.rb +1 -1
- metadata +1 -1
data/lib/golf/cli.rb
CHANGED
@@ -11,9 +11,13 @@ module Golf
|
|
11
11
|
File.expand_path("../../../", __FILE__)
|
12
12
|
end
|
13
13
|
|
14
|
-
desc "new [NAME]", "Creates new golf app"
|
15
|
-
def new(name)
|
16
|
-
|
14
|
+
desc "new [NAME] (optional)[TEMPLATE]", "Creates new golf app, takes NAME and optionally TEMPLATE"
|
15
|
+
def new(name, template = false)
|
16
|
+
unless template
|
17
|
+
directory("templates/new", name)
|
18
|
+
else
|
19
|
+
directory("templates/#{template}", name)
|
20
|
+
end
|
17
21
|
end
|
18
22
|
|
19
23
|
desc "server", "Run the golf app"
|
data/lib/golf/version.rb
CHANGED