plant 1.1.0 → 1.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/plant/version.rb +1 -1
- data/lib/tasks/plant_tasks.rake +4 -1
- data/spec/lib/seed_spec.rb +1 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c9058cb3d727fda89439b7c96328d6125ac9d393
|
4
|
+
data.tar.gz: c5aae4d878e147bd07e8b3ba21df08a017bbfd0f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0da310735d7abb99165292db7125913295b0f8ad70b5fb753d8149be0e3829c59475c2d5df2b0814b8e8e68d090d100cfc71cf46d5ac2c3db9115dbb1466d43e
|
7
|
+
data.tar.gz: 172e00f962ef1e4d8ef091cfc77a016fda596c4fe6f5b36d200ab00beb4877dfa4df0cf430bbb69617e2ed0c522c3f34c16325da494c931fe4c3195b50a44642
|
data/lib/plant/version.rb
CHANGED
data/lib/tasks/plant_tasks.rake
CHANGED
@@ -2,11 +2,14 @@ namespace :plant do
|
|
2
2
|
desc 'Puts the content from the YAML files in app/content into the database'
|
3
3
|
task seed: :environment do
|
4
4
|
count = 0
|
5
|
+
added_nodes = []
|
5
6
|
Plant::Utils.load_all_yaml_files.each do |full_node, value|
|
6
7
|
add_object(full_node, value)
|
8
|
+
added_nodes << full_node
|
7
9
|
count += 1
|
8
10
|
end
|
9
|
-
|
11
|
+
none = Plant::Content.where.not(node_id: added_nodes).destroy_all.count
|
12
|
+
puts "Planted #{count} seeds and removed #{none} redundant seeds."
|
10
13
|
end
|
11
14
|
|
12
15
|
desc 'Puts the content from the YAML files in app/content into the database'
|
data/spec/lib/seed_spec.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: plant
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Yule
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2016-09-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|