Skip to content

Commit

Permalink
fix bugs, add electron-packager to devDependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
dbackowski committed Aug 20, 2015
1 parent 171854f commit 03a7444
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 9 deletions.
12 changes: 3 additions & 9 deletions api.js
Expand Up @@ -17,13 +17,8 @@ var onError = function (error) {
var Datastore = require('nedb');

var db = {};
db.sites = new Datastore();
db.feeds = new Datastore();

var sites = [
{ title: 'Wykop.pl', url: 'http://www.wykop.pl/rss' },
{ title: 'Antyweb.pl', url : 'http://feeds2.feedburner.com/Antyweb' }
];
db.sites = new Datastore({ filename: path.join(__dirname,'sites'), autoload: true });
db.feeds = new Datastore({ filename: path.join(__dirname,'feeds'), autoload: true });

var saveFeedData = function(feed) {
db.feeds.find({ guid: feed.guid, site_id: feed.site_id }, function (err, feeds) {
Expand Down Expand Up @@ -179,8 +174,7 @@ app.get('*', function(req, res) {

module.exports = {
start: function() {
sites.forEach(initSampleSites);
setInterval(getFeeds, 1000 * 10);
setInterval(getFeeds, 1000 * 30);

var server = app.listen(8080, function () {
var port = server.address().port;
Expand Down
Binary file added icon.icns
Binary file not shown.
4 changes: 4 additions & 0 deletions package.json
Expand Up @@ -5,6 +5,7 @@
"main": "electron.js",
"scripts": {
"start": "node app.js",
"package": "electron-packager ./ BackRSS --platform=darwin,linux --icon=./icon.icns --arch=x64 --version=0.30.4",
"test": "echo \"Error: no test specified\" && exit 1"
},
"author": "Damian Baćkowski",
Expand All @@ -17,5 +18,8 @@
"nedb": "^1.1.2",
"request": "^2.54.0",
"underscore": "^1.8.3"
},
"devDependencies": {
"electron-packager": "^5.0.1"
}
}

0 comments on commit 03a7444

Please sign in to comment.