nydp-html 0.0.4 → 0.0.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/nydp/html.rb +5 -2
- data/lib/nydp/html/version.rb +1 -1
- data/nydp-html.gemspec +3 -4
- metadata +10 -10
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 582943cc0cc6d9903b8b0d02c8e73abc15537867
|
4
|
+
data.tar.gz: 80f5a959d8673b4cba45780ddfaa8ffd3082173b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 41533c53511e93911b827cecb15a063241d011ac15877711fdb88c2f3692185a1f887a58f7f69e019cb791bf6130fbfe5f7896c5e6bcff2fa26848a5d119c702
|
7
|
+
data.tar.gz: b58e56fecc8f5642fe08c9cb2ffce0311f1d76e397bb93ecc98c46c4d3d28edbe6be7e38b430bf076cb210926dcb81f4ce7190ec4ded9713acbe49ce9e233cf1
|
data/lib/nydp/html.rb
CHANGED
@@ -2,6 +2,7 @@ require "haml"
|
|
2
2
|
require "redcloth"
|
3
3
|
require "nydp"
|
4
4
|
require "nydp/literal"
|
5
|
+
require "nydp/builtin"
|
5
6
|
require "nydp/html/version"
|
6
7
|
|
7
8
|
module Nydp
|
@@ -32,6 +33,7 @@ module Nydp
|
|
32
33
|
end
|
33
34
|
|
34
35
|
class HamlToHtml
|
36
|
+
include Nydp::Builtin::Base
|
35
37
|
def normalise_indentation txt
|
36
38
|
lines = txt.split(/\n/).select { |line| line.strip != "" }
|
37
39
|
return txt if lines.length == 0
|
@@ -55,13 +57,14 @@ module Nydp
|
|
55
57
|
end
|
56
58
|
end
|
57
59
|
|
58
|
-
def
|
60
|
+
def builtin_invoke vm, args
|
59
61
|
vm.push_arg Nydp::StringAtom.new convert_from_haml(args.car.to_s)
|
60
62
|
end
|
61
63
|
end
|
62
64
|
|
63
65
|
class TextileToHtml
|
64
|
-
|
66
|
+
include Nydp::Builtin::Base
|
67
|
+
def builtin_invoke vm, args
|
65
68
|
src = args.car.to_s
|
66
69
|
rc = RedCloth.new(src)
|
67
70
|
rc.no_span_caps = true
|
data/lib/nydp/html/version.rb
CHANGED
data/nydp-html.gemspec
CHANGED
@@ -19,13 +19,12 @@ Gem::Specification.new do |spec|
|
|
19
19
|
spec.require_paths = ["lib"]
|
20
20
|
|
21
21
|
spec.add_development_dependency "bundler", "~> 1.7"
|
22
|
-
spec.add_development_dependency "rake",
|
22
|
+
spec.add_development_dependency "rake", "~> 10.0"
|
23
23
|
|
24
24
|
spec.add_development_dependency 'rspec', '~> 2.9'
|
25
25
|
spec.add_development_dependency 'rspec_numbering_formatter'
|
26
26
|
|
27
|
-
spec.add_dependency 'nydp'
|
28
|
-
spec.add_dependency 'haml'
|
27
|
+
spec.add_dependency 'nydp', '~> 0.0.12'
|
28
|
+
spec.add_dependency 'haml', '~> 4.0'
|
29
29
|
spec.add_dependency 'RedCloth'
|
30
|
-
|
31
30
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: nydp-html
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Conan Dalton
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-09-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -70,30 +70,30 @@ dependencies:
|
|
70
70
|
name: nydp
|
71
71
|
requirement: !ruby/object:Gem::Requirement
|
72
72
|
requirements:
|
73
|
-
- - "
|
73
|
+
- - "~>"
|
74
74
|
- !ruby/object:Gem::Version
|
75
|
-
version:
|
75
|
+
version: 0.0.12
|
76
76
|
type: :runtime
|
77
77
|
prerelease: false
|
78
78
|
version_requirements: !ruby/object:Gem::Requirement
|
79
79
|
requirements:
|
80
|
-
- - "
|
80
|
+
- - "~>"
|
81
81
|
- !ruby/object:Gem::Version
|
82
|
-
version:
|
82
|
+
version: 0.0.12
|
83
83
|
- !ruby/object:Gem::Dependency
|
84
84
|
name: haml
|
85
85
|
requirement: !ruby/object:Gem::Requirement
|
86
86
|
requirements:
|
87
|
-
- - "
|
87
|
+
- - "~>"
|
88
88
|
- !ruby/object:Gem::Version
|
89
|
-
version: '0'
|
89
|
+
version: '4.0'
|
90
90
|
type: :runtime
|
91
91
|
prerelease: false
|
92
92
|
version_requirements: !ruby/object:Gem::Requirement
|
93
93
|
requirements:
|
94
|
-
- - "
|
94
|
+
- - "~>"
|
95
95
|
- !ruby/object:Gem::Version
|
96
|
-
version: '0'
|
96
|
+
version: '4.0'
|
97
97
|
- !ruby/object:Gem::Dependency
|
98
98
|
name: RedCloth
|
99
99
|
requirement: !ruby/object:Gem::Requirement
|