Giter VIP home page Giter VIP logo

pyfeedproc's Introduction

This is a simple feed-processing framework, written in Python.

Allows you to programatically modify an RSS feed. It uses feedparser to parse the feeds.

Processors are classes, which inherent the FeedProc class. The processor uses specifically named functions to determine which item to modify. For example, proc_enteries_title will process each feed item's "title".

Each function is given two arguments, the first is the original value, the second is the entire element (with entries, this is the entire news <item>). Each function simply returns the desired new value.

As a simple example processor, to truncate every RSS item's title to 20 characters:


from feedproc import FeedProc

class ExampleProcessor(FeedProc):
    proc_enteries_title(self, orig_title, full_item):
        truncated_title = orig_title[20:]
        return truncated_title

The whole system is quite simple. It is intended to remove annoyances from RSS feeds, such as adverts, similar to what "Yahoo Pipes" is, but FeedProc is *much* simpler and does not depend on third-party servers. It is also much more flexible (as processors are simple Python classes)

pyfeedproc's People

Contributors

dbr avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.