ruby-feedparser 0.9.4 → 0.9.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/Rakefile +3 -2
- data/lib/feedparser/feedparser.rb +3 -3
- data/lib/feedparser/textconverters.rb +1 -1
- data/lib/feedparser/version.rb +3 -0
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 30ce2c89bc526bbf1927909ac7bbab3dd9c7e8c3b317353ac527b4bbabe77116
|
4
|
+
data.tar.gz: cfd6026cc5d326a0dc2a930a3ed9264d24efccb8eec2c694d21353a4c07316ad
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 173b692e31b7cdbf2b73ee0c500b215ce99e7f5e49d48b931e42a77cda729cd7808e4e450bb63c903dae77fbb7d9caeeb5880723ef43f87424f5be8ebe077b66
|
7
|
+
data.tar.gz: 1e6202dd2473a3b29c4f91e6e4fb83294e848af56778bebba2f97d846737874985865ba3c267e4d6473f7745491d92d5650ccd796a070e70243c00b393506ae1
|
data/Rakefile
CHANGED
@@ -3,10 +3,11 @@ require 'rdoc/task'
|
|
3
3
|
require 'rubygems/package_task'
|
4
4
|
require 'rake'
|
5
5
|
require 'find'
|
6
|
+
require_relative 'lib/feedparser/version.rb'
|
6
7
|
|
7
8
|
# Globals
|
8
9
|
PKG_NAME = 'ruby-feedparser'
|
9
|
-
PKG_VERSION =
|
10
|
+
PKG_VERSION = FeedParser::VERSION
|
10
11
|
|
11
12
|
PKG_FILES = [ 'ChangeLog.md', 'README', 'COPYING', 'LICENSE', 'setup.rb', 'Rakefile']
|
12
13
|
Find.find('lib/', 'test/', 'tools/') do |f|
|
@@ -87,5 +88,5 @@ task :release => :repackage do
|
|
87
88
|
sh 'git', 'tag', 'v' + PKG_VERSION
|
88
89
|
sh 'git', 'push'
|
89
90
|
sh 'git', 'push', '--tags'
|
90
|
-
sh 'gem' 'push', Dir['pkg/*.gem']
|
91
|
+
sh 'gem' 'push', Dir['pkg/*.gem'].first
|
91
92
|
end
|
@@ -1,16 +1,16 @@
|
|
1
|
+
require 'cgi'
|
1
2
|
require 'rexml/document'
|
2
3
|
require 'time'
|
3
4
|
require 'feedparser/textconverters'
|
4
5
|
require 'feedparser/rexml_patch'
|
5
6
|
require 'feedparser/text-output'
|
7
|
+
require 'feedparser/version'
|
6
8
|
require 'base64'
|
7
9
|
require 'magic'
|
8
10
|
require 'uri'
|
9
11
|
|
10
12
|
module FeedParser
|
11
13
|
|
12
|
-
VERSION = "0.9.4"
|
13
|
-
|
14
14
|
class UnknownFeedTypeException < RuntimeError
|
15
15
|
end
|
16
16
|
|
@@ -233,7 +233,7 @@ module FeedParser
|
|
233
233
|
|
234
234
|
def link
|
235
235
|
if @link
|
236
|
-
uri = URI.parse(
|
236
|
+
uri = URI.parse(CGI.escape(@link))
|
237
237
|
if uri.hostname && uri.scheme
|
238
238
|
@link
|
239
239
|
elsif feed && feed.origin
|
@@ -59,7 +59,7 @@ end
|
|
59
59
|
text.gsub!(/\A\s*(.*)\Z/m, '<p>\1</p>')
|
60
60
|
text.gsub!(/\s*\n(\s*\n)+\s*/, "</p>\n<p>")
|
61
61
|
# uris
|
62
|
-
text.gsub!(/([^'"])(#{URI::
|
62
|
+
text.gsub!(/([^'"])(#{URI::DEFAULT_PARSER.make_regexp(['http','ftp','https'])})/,
|
63
63
|
'\1<a href="\2">\2</a>')
|
64
64
|
end
|
65
65
|
# Handle broken hrefs in <a> and <img>
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ruby-feedparser
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.9.
|
4
|
+
version: 0.9.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Lucas Nussbaum
|
8
8
|
autorequire: feedparser
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2021-01-14 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: magic
|
@@ -44,6 +44,7 @@ files:
|
|
44
44
|
- lib/feedparser/sgml-parser.rb
|
45
45
|
- lib/feedparser/text-output.rb
|
46
46
|
- lib/feedparser/textconverters.rb
|
47
|
+
- lib/feedparser/version.rb
|
47
48
|
- setup.rb
|
48
49
|
- test/tc_feed_parse.rb
|
49
50
|
- test/tc_html2text_parser.rb
|
@@ -73,8 +74,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
73
74
|
version: '0'
|
74
75
|
requirements:
|
75
76
|
- none
|
76
|
-
|
77
|
-
rubygems_version: 2.5.1
|
77
|
+
rubygems_version: 3.2.5
|
78
78
|
signing_key:
|
79
79
|
specification_version: 4
|
80
80
|
summary: Ruby library to parse ATOM and RSS feeds
|