yaddl 0.1.1 → 0.1.2

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.
Files changed (3) hide show
  1. data/lib/yaddl.rb +2 -2
  2. data/lib/yaddl/version.rb +1 -1
  3. metadata +1 -1
@@ -202,12 +202,12 @@ class Generator
202
202
  v2 = verb == "Add" ? "To" : "On"
203
203
  if changes.count > 0
204
204
  index = ""
205
- while Dir.glob("#{Rails.root}/db/migrate/*_#{summary}#{v2}#{name.pluralize}#{index}".underscore.downcase+".rb").count > 0
205
+ while Dir.glob("#{Rails.root}/db/migrate/*" + "_" + "#{summary}#{v2}#{name.pluralize}#{index}".underscore.downcase+".rb").count > 0
206
206
  index = 1 if index == ""
207
207
  index += 1
208
208
  end
209
209
 
210
- puts DateTime.now.strftime("%Y%m%d%H%M%S") + "_#{summary}#{v2}#{name.pluralize}#{index}".underscore.downcase + ".rb"
210
+ puts DateTime.now.strftime("%Y%m%d%H%M%S") + "_" + "#{summary}#{v2}#{name.pluralize}#{index}".underscore.downcase + ".rb"
211
211
  File.write("#{Rails.root}/db/migrate/" + DateTime.now.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 ")}
@@ -1,3 +1,3 @@
1
1
  module Yaddl
2
- VERSION = "0.1.1"
2
+ VERSION = "0.1.2"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: yaddl
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: