-
Notifications
You must be signed in to change notification settings - Fork 27
/
package.json
92 lines (92 loc) · 4.43 KB
/
package.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
{
"name": "civil-services-us-governors",
"version": "1.0.1",
"description": "United States Governors. Demographics, Headshots, Legislator Data & Social Media Links ( JSON, XML, CSV, SQL, XLSX & YML formats )",
"license": "MIT",
"keywords": [
"Civil Services",
"US",
"United States",
"Congress",
"Governors",
"government",
"data",
"json",
"csv",
"yml",
"sql",
"xml",
"xlsx",
"headshots",
"pictures",
"photos",
"map",
"state",
"votesmart",
"party",
"pronunciation",
"gender",
"ethnicity",
"religion",
"openley_lgbtq",
"date_of_birth",
"entered_office",
"term_end",
"biography",
"phone",
"fax",
"latitude",
"longitude",
"address",
"website",
"contact_page",
"facebook_url",
"twitter_url",
"photo_url"
],
"main": "us-governors/data/us-governors.json",
"homepage": "https://civilserviceusa.github.io/us-governors/",
"repository": {
"type": "git",
"url": "git+https://github.com/civilserviceusa/us-governors.git"
},
"bugs": {
"url": "https://github.com/civilserviceusa/us-governors/issues"
},
"author": {
"name": "Civil Services",
"email": "[email protected]",
"url": "https://civil.services"
},
"scripts": {
"update-csv": "curl -o ./source/us-governors.csv 'https://docs.google.com/spreadsheets/d/1AMwiClcbogCc1LoIlwX8M2vFGNzGK3NQWY5Qrk6sNuc/export?format=csv&id=1AMwiClcbogCc1LoIlwX8M2vFGNzGK3NQWY5Qrk6sNuc&gid=284703522'",
"json-to-yml": "if ( test -e ./us-governors/data/us-governors.json ); then ./node_modules/.bin/json2yaml ./us-governors/data/us-governors.json > ./us-governors/data/us-governors.yml && echo '✓ Updated us-governors/data/us-governors.yml'; else echo '\n× Missing ./us-governors/data/us-governors.json ( npm run -s convert-csv )\n'; fi",
"json-to-xml": "if ( test -e ./us-governors/data/us-governors.json ); then node ./.scripts/json-to-xml.js && echo '✓ Updated us-governors/data/us-governors.xml'; else echo '\n× Missing ./us-governors/data/us-governors.json ( npm run -s convert-csv )\n'; fi",
"csv-to-sql": "if ( test -e ./us-governors/data/us-governors.json ); then node ./.scripts/csv-to-sql.js && echo '✓ Updated us-governors/data/us-governors.sql'; else echo '\n× Missing ./us-governors/data/us-governors.json ( npm run -s convert-csv )\n'; fi",
"csv-to-json": "if ( test -e ./us-governors/data/us-governors.csv ); then ./node_modules/.bin/csvtojson ./us-governors/data/us-governors.csv > ./us-governors/data/us-governors.json && json-pretty-print ./us-governors/data/us-governors.json ./us-governors/data/us-governors.json && sed -i '' 's/\"\"/null/g' ./us-governors/data/us-governors.json && sed -i '' 's/\"true\",/true,/g' ./us-governors/data/us-governors.json && sed -i '' 's/\"false\",/false,/g' ./us-governors/data/us-governors.json && sed -i '' 's/\"district\": 0/\"district\": null/g' ./us-governors/data/us-governors.json && echo '✓ Updated us-governors/data/us-governors.json'; else echo '\n× Missing ./us-governors/data/us-governors.csv ( npm run -s convert-csv )\n'; fi",
"resize-headshots": "node ./.scripts/resize-headshots.js",
"resize-backgrounds": "node ./.scripts/resize-backgrounds.js",
"console-headshots": "node ./.scripts/console-headshots.js",
"convert-csv": "if ( test -e ./source/us-governors.csv ); then node ./.scripts/convert-csv.js; else echo '\n× Missing ./source/us-governors.csv ( see ./source/README.md )\n'; fi",
"build-images": "npm run -s resize-headshots && npm run -s resize-backgrounds && echo '\n☆ Image Conversion Complete\n'",
"build-data": "if ( test -e ./us-governors/data/us-governors.csv ); then npm run -s csv-to-json && npm run -s json-to-yml && npm run -s json-to-xml && npm run -s csv-to-sql && echo '\n☆ Data Conversion Complete\n'; else echo '\n× Missing ./us-governors/data/us-governors.csv\n'; fi",
"build": "npm run -s convert-csv && npm run -s build && npm run -s build-images && echo '\n☆ヽ(´▽`)ノ All Done \n'"
},
"devDependencies": {
"bluebird": "^3.4.7",
"csvtojson": "^1.1.2",
"fast-csv": "^2.3.0",
"glob": "^7.1.1",
"gm": "^1.23.0",
"htmlparser2": "^3.9.2",
"js2xmlparser": "^2.0.2",
"json-pretty-print": "0.0.4",
"json2csv": "^3.7.3",
"json2yaml": "^1.1.0",
"node-jsdom": "^3.1.5",
"object.values": "^1.0.4",
"parse-address": "0.0.10",
"slug": "^0.9.1",
"stream-replace": "^1.0.0"
}
}