learn_create 0.0.8 → 0.0.9
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/learn_create.rb +9 -6
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e0632a9b6828b2a51708d93d57a9003c1f54681efcfd85257862e576da10653a
|
4
|
+
data.tar.gz: 7275c70220e8e6d76944a5055315e19fe7f35ffd18b4b64ddc55a7c56b2649aa
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 792350be3024c1fd3287e997aca6d60b447ecfd1bccfbe44a720b92b16239d5c28a76a083f69014b9d56824a5e4c1bb6b71f59f3ee482913898c3530c25f05dc
|
7
|
+
data.tar.gz: 95bdcad9486e72f1619824d68b8362eb84d3bb4a8f0eb75113b00ef577123c7337700540ec12fff71f7f27d1fd0c7b44800a4f36944a17fe55811bff3069ce68
|
data/lib/learn_create.rb
CHANGED
@@ -78,14 +78,17 @@ class LearnCreate
|
|
78
78
|
end
|
79
79
|
|
80
80
|
def create_local_lesson(type = 'readme', language = nil)
|
81
|
-
|
81
|
+
if !language
|
82
|
+
puts "Creating #{type}..."
|
83
|
+
template_folder = "/templates/#{type}_template"
|
84
|
+
else
|
85
|
+
puts "Creating #{language} #{type}..."
|
86
|
+
template_folder = "/templates/#{language}_#{type}_template"
|
87
|
+
end
|
88
|
+
|
82
89
|
gem_template_location = File.dirname(__FILE__)
|
83
|
-
template_folder = if !language
|
84
|
-
"/templates/#{type}_template"
|
85
|
-
else
|
86
|
-
"/templates/#{language}_#{type}_template"
|
87
|
-
end
|
88
90
|
template_path = File.expand_path(gem_template_location) + template_folder
|
91
|
+
|
89
92
|
copy_template(template_path)
|
90
93
|
end
|
91
94
|
|