yaddl 0.1.4 → 0.1.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/lib/yaddl.rb +3 -2
- data/lib/yaddl/version.rb +1 -1
- metadata +1 -1
data/lib/yaddl.rb
CHANGED
|
@@ -207,13 +207,14 @@ class Generator
|
|
|
207
207
|
index += 1
|
|
208
208
|
end
|
|
209
209
|
|
|
210
|
-
puts
|
|
211
|
-
File.write("#{Rails.root}/db/migrate/" +
|
|
210
|
+
puts Time.now.utc.strftime("%Y%m%d%H%M%S") + "_" + "#{summary}#{v2}#{name.pluralize}#{index}".underscore.downcase + ".rb"
|
|
211
|
+
File.write("#{Rails.root}/db/migrate/" + Time.now.utc.strftime("%Y%m%d%H%M%S") + "_#{summary}#{v2}#{name.pluralize}#{index}".underscore.downcase+".rb", "class #{summary}#{v2}#{ name.pluralize }#{index} < ActiveRecord::Migration
|
|
212
212
|
def change
|
|
213
213
|
#{changes.join("\n ")}
|
|
214
214
|
end
|
|
215
215
|
end
|
|
216
216
|
")
|
|
217
|
+
sleep(1)
|
|
217
218
|
end
|
|
218
219
|
end
|
|
219
220
|
|
data/lib/yaddl/version.rb
CHANGED