Adding mysql deps, cleaning up json generation on scraper
This commit is contained in:
parent
e2b77d366b
commit
2b3dd0b13a
@ -1,4 +1,4 @@
|
||||
var DATA_RECORDS = [
|
||||
[
|
||||
{
|
||||
"name": "Levain Bakery",
|
||||
"relativeUrl": "/Restaurant_Review-g60763-d783460-Reviews-Levain_Bakery-New_York_City_New_York.html",
|
||||
|
@ -9,7 +9,8 @@
|
||||
"author": "",
|
||||
"license": "BSD-2-Clause",
|
||||
"dependencies": {
|
||||
"underscore": "~1.6.0",
|
||||
"cheerio": "~0.17.0"
|
||||
"cheerio": "~0.17.0",
|
||||
"mysql": "^2.5.0",
|
||||
"underscore": "~1.6.0"
|
||||
}
|
||||
}
|
||||
|
@ -133,7 +133,7 @@ function main() {
|
||||
});
|
||||
|
||||
process.on('exit', function() {
|
||||
var strData = 'var DATA_RECORDS = ' + JSON.stringify(results, null, 4);
|
||||
var strData = JSON.stringify(results, null, 4);
|
||||
fs.writeFileSync(databasePath, strData);
|
||||
});
|
||||
}
|
||||
|
@ -11,6 +11,7 @@
|
||||
"license": "BSD-2-Clause",
|
||||
"dependencies": {
|
||||
"express": "~4.5.1",
|
||||
"mysql": "^2.5.0",
|
||||
"underscore": "^1.6.0"
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user