guard-seeds 0.0.6 → 0.0.7

Sign up to get free protection for your applications and to get access to all the features.
data/README CHANGED
@@ -0,0 +1,4 @@
1
+ Guard-Seeds is a guard extension handling the rake db:seed when seeds.rb changes
2
+
3
+ Just put gem 'guard-seeds' to your Gemfile,
4
+ run 'bundle install', 'bundle exec guard init seeds' and edit your Guardfile
@@ -8,8 +8,8 @@ Gem::Specification.new do |s|
8
8
  s.authors = ["Dmitry Afanasyev"]
9
9
  s.email = ["dimarzio1986@gmail.com"]
10
10
  s.homepage = "https://github.com/icrowley/guard-seeds"
11
- s.summary = %q{Guard-Seeds: is a guard extension handling the rake db:seed when seeds.rb changes}
12
- s.description = %q{Guard-Seeds: is a guard extension handling the rake db:seed when seeds.rb changes}
11
+ s.summary = %q{Guard-Seeds is a guard extension handling the rake db:seed when seeds.rb changes}
12
+ s.description = %q{Guard-Seeds is a guard extension handling the rake db:seed when seeds.rb changes}
13
13
 
14
14
  s.files = `git ls-files`.split("\n")
15
15
  s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
@@ -43,11 +43,15 @@ module Guard
43
43
  def run_db_seeds
44
44
  UI.info "Guard::Seeds is running rake db:seed"
45
45
  started_at = Time.now
46
- @result = system("bundle exec rake db:seed") ? "Seed data loaded successfully" : "Error while loading seed data"
47
- UI.info @result
46
+ result, image = if system("bundle exec rake db:seed")
47
+ ["Seed data loaded successfully", :success]
48
+ else
49
+ ["Error while loading seed data", :failed]
50
+ end
51
+ UI.info result
48
52
  UI.info "rake db:seed ended #{Time.now - started_at} seconds"
49
- ::Guard::Notifier.notify(@result, :title => 'rake db:seed result', :image => :success) if notify?
50
- @result
53
+ ::Guard::Notifier.notify(result, :title => 'rake db:seed result', :image => image) if notify?
54
+ result
51
55
  end
52
56
 
53
57
  end
@@ -1,5 +1,5 @@
1
1
  module Guard
2
2
  module Seeds
3
- VERSION = "0.0.6"
3
+ VERSION = "0.0.7"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: guard-seeds
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.6
4
+ version: 0.0.7
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -13,7 +13,7 @@ date: 2011-12-25 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: guard
16
- requirement: &70353528920260 !ruby/object:Gem::Requirement
16
+ requirement: &70114553883160 !ruby/object:Gem::Requirement
17
17
  none: false
18
18
  requirements:
19
19
  - - ! '>='
@@ -21,9 +21,9 @@ dependencies:
21
21
  version: '0'
22
22
  type: :development
23
23
  prerelease: false
24
- version_requirements: *70353528920260
25
- description: ! 'Guard-Seeds: is a guard extension handling the rake db:seed when seeds.rb
26
- changes'
24
+ version_requirements: *70114553883160
25
+ description: Guard-Seeds is a guard extension handling the rake db:seed when seeds.rb
26
+ changes
27
27
  email:
28
28
  - dimarzio1986@gmail.com
29
29
  executables: []
@@ -62,7 +62,7 @@ rubyforge_project:
62
62
  rubygems_version: 1.8.13
63
63
  signing_key:
64
64
  specification_version: 3
65
- summary: ! 'Guard-Seeds: is a guard extension handling the rake db:seed when seeds.rb
66
- changes'
65
+ summary: Guard-Seeds is a guard extension handling the rake db:seed when seeds.rb
66
+ changes
67
67
  test_files: []
68
68
  has_rdoc: