usda-nutrient-database 0.6.0 → 0.7.0
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5bd17f02eed2f395e8f952043fbdefa139bccec3
|
4
|
+
data.tar.gz: 2a65d9b31e2a8c27232e0a4942b1eb2476c4df04
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: df47134fa7024b7690ea229df7b1e5d67e49c99251c2d8596bbb5dfc34adf93a9af28b440d658662719cbccfee64dd8c4339d10a2c59ddacc646e021fd2e2004
|
7
|
+
data.tar.gz: 7d525913e661f9956a5e343738b140b4e6e32c51aeea55c63f1376dce9c747768dcb88523e9ded0090e85554a8cce2fe1e3d668162e9ca009045354b481a90a4
|
@@ -4,14 +4,14 @@ namespace :usda do
|
|
4
4
|
UsdaNutrientDatabase::Importer.new('tmp/usda', 'sr25').import
|
5
5
|
end
|
6
6
|
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
7
|
+
[
|
8
|
+
'Weights', 'Footnotes', 'FoodGroups', 'Foods', 'FoodsNutrients',
|
9
|
+
'Nutrients'
|
10
|
+
].each do |importer_name|
|
11
|
+
desc "Import the USDA #{importer_name} table"
|
12
|
+
task import_weights: :environment do
|
13
|
+
download_and_import(importer_name)
|
14
|
+
end
|
15
15
|
end
|
16
16
|
|
17
17
|
def download_and_import(importer_name)
|