snowpack 1.0.0.alpha6 → 1.0.0.alpha7

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
  SHA256:
3
- metadata.gz: de5e85aa75aec4ab2fbbfcb88ee043315c68b1a359d55d7821e081e399fc8fca
4
- data.tar.gz: 9bef2e815f516ccce2ca3017314120f7ea55d30fa944adc457479d7c0d6c562e
3
+ metadata.gz: c59d2bc6fd8981d38159383506f2e8bcd0cbc8f2d3c812ecce4432d4d6fe662a
4
+ data.tar.gz: ee6907ee86d324484ff6421b2b150cd458804bd5c2996bbd31ae2521b254c241
5
5
  SHA512:
6
- metadata.gz: 13e7f05d932ffa9cc00da4ce3afbb772b44e257ef33649db33b45900cb8cbc355f7366beff569a92a1b8c3141fe701742734734234516cbad9943c6a99e0117e
7
- data.tar.gz: dd09630835fcc9a23684398ca70515802973a96c48c640f910cb75e07ecef4b8f15a2b7291a58ae172fa0b45f383594352cbd5e071f6dd626f004896e4ddc5af
6
+ metadata.gz: 4b09235dd7654fb12ed8f7d845e93de0786cdf053065d0d12f59b6e0719250796213c6496ab01707eadfd6cc7d88d2c392fe16135aa77a8d507c6de0d4937245
7
+ data.tar.gz: 16abf19ddb7bbd1ca6b7c3f5204577ad8587ca430b91aee3362f5277090331e553be7303bdb8ce89c055c3e09c13b78dddf4fa0289cb0f0b4447e4591f5b0205
@@ -1,5 +1,12 @@
1
1
  # Changelog
2
2
 
3
+ ## [1.0.0.alpha7] - 2019-12-03
4
+
5
+ ### Fixed
6
+
7
+ - Set up :sql notification event before enabling SQL logging
8
+ - CLI `db migrate` task can now run when no migration files are present
9
+
3
10
  ## [1.0.0.alpha6] - 2019-10-22
4
11
 
5
12
  ### Added
@@ -15,6 +15,8 @@ module Snowpack
15
15
  option :target, desc: "Target migration number", aliases: ["-t"]
16
16
 
17
17
  def call(target: nil, **)
18
+ return if Dir[application.root.join("db/migrate/*.rb")].empty?
19
+
18
20
  measure "database #{database.name} migrated" do
19
21
  if target
20
22
  run_migrations(target: Integer(target))
@@ -28,7 +30,7 @@ module Snowpack
28
30
 
29
31
  private
30
32
 
31
- def run_migrations(**options )
33
+ def run_migrations(**options)
32
34
  ROM::SQL.with_gateway(database.gateway) do
33
35
  database.migrator.run(options)
34
36
  end
@@ -4,6 +4,7 @@
4
4
  end
5
5
 
6
6
  start do
7
+ notifications.register_event :sql
7
8
  Dry::Monitor::SQL::Logger.new(logger).subscribe(notifications)
8
9
  end
9
10
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Snowpack
4
- VERSION = "1.0.0.alpha6"
4
+ VERSION = "1.0.0.alpha7"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: snowpack
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0.alpha6
4
+ version: 1.0.0.alpha7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tim Riley
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: exe
11
11
  cert_chain: []
12
- date: 2019-10-22 00:00:00.000000000 Z
12
+ date: 2019-12-03 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: dry-inflector