Giter Site home page Giter Site logo

go-rss's Introduction

go-rss

Simple RSS parser, tested with various feeds.

Usage

See the example folder.

go-rss's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

go-rss's Issues

XML Parser does not takes xml namespaces into account

Feed: http://feeds.5by5.tv/changelog

Here, the go-rss package fails to parse the link tag of the channel items. It is always empty.

package main

import (
  "fmt"
  rss "github.com/ungerik/go-rss"
)

func main() {
  feed, _ := rss.Read("http://feeds.5by5.tv/changelog")
  fmt.Printf("%v\n", feed.Item[0].Link) // This is empty!
}

I guess the xml parser gets confused because there are two link tags in that stream (snippet):

...
<item>
...
<link>http://5by5.tv/changelog/107</link>
<atom:link rel="payment" type="text/html" href="https://flattr.com/submit/auto?url=http%3A%2F%2F5by5.tv%2Fchangelog%2F107&user_id=danbenjamin"/>
</item>
...

Any idea how this could be fixed?

Add examples

Works as intented.. but..a lot of the golang community are newbies (i am in the bandwagon too)
I understood how to use the channel given back by the Read thanks to #2

adding a couple lines to the readme can't be so bad, altough i may complile a PR as soon as i've really grasped it

Please support multiple struct ItemEnclosure in Item struct

Currently there is only support for 1 ItemEnclosure
however Wordpress feeds can have [] ItemEnclosures

The way I solved it temporary is this way:
in the Item struct:
Enclosure []ItemEnclosure xml:"enclosure"

It works and passes the test

Thank you for this great package :)

CI

Could you enable CI in for example travis-ci to ensure that the code get tested on every commit and could you add a build badge to the readme?

Could you add a LICENSE file?

In the README a license is mentioned. Could you add a LICENSE file as well so the license type will appear on the top right too?

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.