strong_migrations 0.1.7 → 0.1.8

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: d3bfd4ef03a42fa57d69e5207d20f9e4f7d453ed
4
- data.tar.gz: d291ce32c88f47bfb42b1e34013c625cbdf44e8c
3
+ metadata.gz: c88f42b80893537a01f6af06975ecfb6f84c4fcf
4
+ data.tar.gz: '0439465af1f34f52226a12e86a049cf0ecaf6ae2'
5
5
  SHA512:
6
- metadata.gz: f10a0f58b62bed953fc0f066bcf032639386ca4db62c1fc0f23c63d849514176e402fc419453d8617232c3b613f907b743ed1b330a4249f6f37c66f634d6af4b
7
- data.tar.gz: 64c2d0ab3d3b0bc7cce8a0f7f0bd60f855d1f6e14ee720ce2e1af9a8dd402a72cbc2ecbb6ca99bf0a35b5f85334b4f4cd04daae6057207217e68ab21574c7ea9
6
+ metadata.gz: 6111b78f6cd45d6f94adcd03fb2759c2ac2f6e88680cd4e91bfc5559b3c1def917e9444295f31e75d1fa0387a1a79c59b55ea717c344dfaa424d2a382fb21814
7
+ data.tar.gz: 7436c59cb398da6e8c010e4eeeef1642820a040fa72ea4661374739fb27214e05415d24b1b91e3799c5a4b2fc92fa9f27fb66425997a32811554f1d6275ea83e
data/CHANGELOG.md CHANGED
@@ -1,3 +1,8 @@
1
+ ## 0.1.8
2
+
3
+ - Fixed error with `create_table`
4
+ - Added check for executing arbitrary SQL
5
+
1
6
  ## 0.1.7
2
7
 
3
8
  - Added check for `force` option with `create_table`
data/README.md CHANGED
@@ -21,6 +21,7 @@ gem 'strong_migrations'
21
21
  - renaming a table
22
22
  - renaming a column
23
23
  - removing a column
24
+ - executing arbitrary SQL
24
25
  - adding an index non-concurrently (Postgres only)
25
26
  - adding a `json` column to an existing table (Postgres only)
26
27
 
@@ -43,7 +43,7 @@ module StrongMigrations
43
43
  when :change_column
44
44
  raise_error :change_column
45
45
  when :create_table
46
- options = args[1]
46
+ options = args[1] || {}
47
47
  raise_error :create_table if options[:force]
48
48
  when :add_reference
49
49
  options = args[2] || {}
@@ -51,6 +51,8 @@ module StrongMigrations
51
51
  if postgresql? && index_value
52
52
  raise_error :add_reference
53
53
  end
54
+ when :execute
55
+ raise_error :execute
54
56
  end
55
57
  end
56
58
 
@@ -154,11 +156,15 @@ If you're sure this is what you want, wrap it in a safety_assured { ... } block.
154
156
  when :change_table
155
157
  "The strong_migrations gem does not support inspecting what happens inside a
156
158
  change_table block, so cannot help you here. Please make really sure that what
157
- you're doing is safe before proceding, then wrap it in a safety_assured { ... } block."
159
+ you're doing is safe before proceeding, then wrap it in a safety_assured { ... } block."
158
160
  when :create_table
159
161
  "The force option will destroy existing tables.
160
162
  If this is intended, drop the existing table first.
161
163
  Otherwise, remove the option."
164
+ when :execute
165
+ "The strong_migrations gem does not support inspecting what happens inside an
166
+ execute call, so cannot help you here. Please make really sure that what
167
+ you're doing is safe before proceeding, then wrap it in a safety_assured { ... } block."
162
168
  end
163
169
 
164
170
  wait_message = '
@@ -1,3 +1,3 @@
1
1
  module StrongMigrations
2
- VERSION = "0.1.7"
2
+ VERSION = "0.1.8"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: strong_migrations
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.7
4
+ version: 0.1.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Bob Remeika
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: exe
12
12
  cert_chain: []
13
- date: 2017-05-30 00:00:00.000000000 Z
13
+ date: 2017-05-31 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: activerecord