New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

custom-rss

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

custom-rss - npm Package Compare versions

Comparing version 0.4.0 to 0.4.1

2

app.js

@@ -0,1 +1,3 @@

'use strict';
var app = require('connect')();

@@ -2,0 +4,0 @@ var createRepostGuard = require('./src/repost-guard');

29

config.json

@@ -11,3 +11,4 @@ {

"tokens": [
"Get a job", "Sponsored", "Angry Birds", "Pokémon", "PS4", "Xbox"
"Get a job", "Sponsored", "Video: ",
"Angry Birds", "Pokémon", "PS4", "Xbox"
]

@@ -37,3 +38,3 @@ },

"LaTeX", "Vim", "Azure", "DuckDuckGo", "Mesos", "Raspberry\\s?Pi",
"Surface Pro", "Material Design"
"Surface Pro", "Material Design", "Vitamin D"
]

@@ -125,29 +126,9 @@ },

"tokens": [
"Video Tutorial", "Open Call For Applications"
"Announcing", "Available", "Open Call For Applications", "Opportunity: ",
"Podcast", "Sale", "SUBSCRIBER", "Video Tutorial"
]
}
]
},
{
"name": "yahoo-tech",
"filters": [
{
"name": "uninteresting-topics",
"type": "blacklist",
"tokens": [
"iPhone", "Playstation", "Raspberry\\s?Pi", "Xbox",
"Deal of the Day"
]
},
{
"name": "tired-topics",
"type": "blacklist",
"tokens": [
"Trump", "Bernie", "Hillary", "San Bernardino", "hoverboard"
]
}
]
}
]
}
{
"name": "custom-rss",
"version": "0.4.0",
"version": "0.4.1",
"description": "Filtering RSS because Zapier is too expensive.",

@@ -17,8 +17,8 @@ "main": "src/feeds/index.js",

"scripts": {
"start": "NODE_ENV=production node --use_strict app.js",
"develop": "supervisor --watch . --debug -- --use_strict app.js",
"start": "NODE_ENV=production node app.js",
"develop": "supervisor --watch . --debug -- app.js",
"deploy:pre": "rm -rf node_modules/* && npm install --production",
"deploy:post": "npm install && to_server",
"deploy": "npm run deploy:pre && git push && npm run deploy:post",
"test": "node --use_strict tests/index.js"
"test": "node tests/index.js"
},

@@ -25,0 +25,0 @@ "devDependencies": {

@@ -30,3 +30,2 @@ # Custom RSS

$ npm run deploy
$ git push origin master

@@ -86,3 +85,2 @@ $ ssh <production>

- [x] NYTimes Business
- [x] Yahoo Tech
- [x] Ray Wenderlich

@@ -89,0 +87,0 @@ - [x] Gama Sutra

@@ -0,1 +1,3 @@

'use strict';
var path = require('path');

@@ -2,0 +4,0 @@ var util = require('./util');

@@ -0,1 +1,3 @@

'use strict';
var fetchFeed = require('../fetch-feed');

@@ -2,0 +4,0 @@ var filterFeed = require('../filter-feed');

@@ -0,1 +1,3 @@

'use strict';
var fetchFeed = require('../fetch-feed');

@@ -2,0 +4,0 @@ var filterFeed = require('../filter-feed');

@@ -7,3 +7,2 @@ module.exports = {

rayWenderlich: require('./ray-wenderlich'),
yahooTech: require('./yahoo-tech')
};

@@ -0,1 +1,5 @@

'use strict';
// NOTE: Unused, unmaintained.
var fetchFeed = require('../fetch-feed');

@@ -2,0 +6,0 @@ var filterFeed = require('../filter-feed');

@@ -0,1 +1,3 @@

'use strict';
var fetchFeed = require('../fetch-feed');

@@ -10,3 +12,3 @@ var filterFeed = require('../filter-feed');

module.exports = function(config, request, response) {
config.originalURL = 'https://qz.com/feed/';
config.originalURL = 'https://cms.qz.com/feed/';
config.url = url.format({

@@ -13,0 +15,0 @@ protocol: 'http', host: request.headers.host, pathname: config.name

@@ -0,1 +1,3 @@

'use strict';
var fetchFeed = require('../fetch-feed');

@@ -9,2 +11,9 @@ var filterFeed = require('../filter-feed');

function transformTitle(entry) {
function replace(match) {
return match.replace(' [FREE]', '');
}
entry.transformContent('title', { to: replace });
}
module.exports = function(config, request, response) {

@@ -24,5 +33,5 @@ config.originalURL = 'https://www.raywenderlich.com/feed?max-results=1';

data: data,
findEntry: function(root) { return root.find('item'); },
findId: function(entry) { return entry.find('guid'); },
findId: function(entry) { return entry.find('id'); },
guardReposts: false,
transformEntry: transformTitle,
transformMeta: transformMeta,

@@ -29,0 +38,0 @@ verbose: true,

@@ -0,1 +1,3 @@

'use strict';
var util = require('./util');

@@ -2,0 +4,0 @@

@@ -0,1 +1,3 @@

'use strict';
var createEntryLogger = require('./entry-logger');

@@ -35,3 +37,3 @@ var createRepostGuard = require('./repost-guard');

var skip = filters.reduce(function(skip, filter) {
var input, matches;
var input, isMatch;
if (skip) {

@@ -51,4 +53,4 @@ return skip;

}
matches = filter.pattern.test(input);
if (matches && filter.type === 'graylist') {
isMatch = filter.pattern.test(input);
if (isMatch && filter.type === 'graylist') {
switch (filter.input) {

@@ -64,3 +66,3 @@ case 'title':

}
return matches;
return isMatch;
}, false);

@@ -67,0 +69,0 @@ if (skip) { skip = 'blocked'; }

@@ -0,1 +1,3 @@

'use strict';
var path = require('path');

@@ -2,0 +4,0 @@ var util = require('./util');

@@ -0,1 +1,3 @@

'use strict';
var fs = require('fs');

@@ -5,2 +7,7 @@ var log = require('util').log;

var protocolModules = {
http: require('http'),
https: require('https')
};
// section: debugging

@@ -79,3 +86,3 @@

// http/s (`Error: Protocol "https:" not supported. Expected "http:".`)
module = require(protocol.replace(':', ''));
module = protocolModules[protocol.replace(':', '')];
return module.request.apply(null, arguments);

@@ -82,0 +89,0 @@ };

@@ -0,1 +1,3 @@

'use strict';
var log = require('./util').log;

@@ -25,3 +27,3 @@ var rAttrs = {};

// Opening tag, allows whitespace and breaks.
'<'+ tagName +'[^]*?>\\s*' +
'<'+ tagName +'[^]*?>\\s*' +
// Content, lazy, allows whitespace and breaks.

@@ -28,0 +30,0 @@ '([^]+?)' +

@@ -0,1 +1,3 @@

'use strict';
var assert = require('assert');

@@ -2,0 +4,0 @@ var fs = require('fs');

@@ -0,1 +1,3 @@

'use strict';
var assert = require('assert');

@@ -2,0 +4,0 @@ var runner = require('./lib/runner');

@@ -0,1 +1,3 @@

'use strict';
var afterEach, beforeEach, failed, total;

@@ -2,0 +4,0 @@ failed = total = 0;

@@ -0,1 +1,3 @@

'use strict';
var assert = require('assert');

@@ -2,0 +4,0 @@ var fs = require('fs');

@@ -0,1 +1,3 @@

'use strict';
var assert = require('assert');

@@ -2,0 +4,0 @@ var runner = require('./lib/runner');

@@ -0,1 +1,3 @@

'use strict';
var assert = require('assert');

@@ -2,0 +4,0 @@ var runner = require('./lib/runner');

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc