wbzyl-rack-htmltidy 0.0.6 → 0.0.8
Sign up to get free protection for your applications and to get access to all the features.
- data/README.markdown +4 -4
- data/VERSION.yml +2 -2
- data/lib/rack/htmltidy.rb +1 -4
- metadata +2 -2
data/README.markdown
CHANGED
@@ -12,7 +12,7 @@ The idea of using middleware to validate HTML belongs to
|
|
12
12
|
Marcin Kulik, [Rack middleware using HTML
|
13
13
|
Tidy](http://sickill.net/blog/2009/05/10/rack-middleware-using-html-tidy.html).
|
14
14
|
|
15
|
-
**Limitations of [TidyLib](http://tidy.sourceforge.net/libintro.html)
|
15
|
+
**Limitations** of [TidyLib](http://tidy.sourceforge.net/libintro.html):
|
16
16
|
Currently, all character encoding support is hard wired into the
|
17
17
|
library. This means we do a poor job of supporting many popular
|
18
18
|
encodings such as GB2312, euc-kr, eastern European languages,
|
@@ -44,7 +44,7 @@ In order to use include the following in a Rails application
|
|
44
44
|
require 'rack/htmltidy'
|
45
45
|
|
46
46
|
Rails::Initializer.run do |config|
|
47
|
-
config.gem "rack-htmltidy"
|
47
|
+
config.gem "wbzyl-rack-htmltidy"
|
48
48
|
config.middleware.use(Rack::HTMLTidy,
|
49
49
|
:errors => true,
|
50
50
|
:diagnostics => true,
|
@@ -60,11 +60,11 @@ Remember to update the `:path` option to the location of *TidyLib* on your syste
|
|
60
60
|
|
61
61
|
## Miscellaneous stuff
|
62
62
|
|
63
|
-
To install *TidyLib* on Fedora 9 and above:
|
63
|
+
1\. To install *TidyLib* on Fedora 9 and above:
|
64
64
|
|
65
65
|
yum install libtidy libtidy-devel
|
66
66
|
|
67
|
-
To fix
|
67
|
+
2\. To fix the bug: `tidybuf.rb:40: [BUG] Segmentation fault`,
|
68
68
|
clone, build and install the *tidy* gem from here:
|
69
69
|
|
70
70
|
git://github.com/ak47/tidy.git
|
data/VERSION.yml
CHANGED
data/lib/rack/htmltidy.rb
CHANGED
@@ -1,14 +1,11 @@
|
|
1
|
-
gem 'rack'
|
2
1
|
require 'rack/utils'
|
3
|
-
|
4
|
-
gem 'tidy'
|
5
2
|
require 'tidy'
|
6
3
|
|
7
4
|
module Rack
|
8
5
|
class HTMLTidy
|
9
6
|
include Rack::Utils
|
10
7
|
|
11
|
-
FORMAT = %{|| Tidy: %s - [%s] "%s %s%s %s"\n%s}
|
8
|
+
FORMAT = %{\n|| Tidy: %s - [%s] "%s %s%s %s"\n%s}
|
12
9
|
|
13
10
|
def initialize(app, opts={})
|
14
11
|
@app = app
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: wbzyl-rack-htmltidy
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Wlodek Bzyl
|
@@ -9,7 +9,7 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2009-
|
12
|
+
date: 2009-07-26 00:00:00 -07:00
|
13
13
|
default_executable:
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|