smart_diff 0.0.1
Sign up to get free protection for your applications and to get access to all the features.
- data/README.md +38 -0
- data/Rakefile +13 -0
- data/bin/smart_diff +69 -0
- data/doc/Htmlize.html +1209 -0
- data/doc/SmartDiff.html +790 -0
- data/doc/Tag.html +484 -0
- data/doc/Utils.html +370 -0
- data/doc/_index.html +149 -0
- data/doc/class_list.html +53 -0
- data/doc/css/common.css +1 -0
- data/doc/css/full_list.css +57 -0
- data/doc/css/style.css +338 -0
- data/doc/file.README.html +127 -0
- data/doc/file_list.html +55 -0
- data/doc/frames.html +28 -0
- data/doc/index.html +127 -0
- data/doc/js/app.js +214 -0
- data/doc/js/full_list.js +178 -0
- data/doc/js/jquery.js +4 -0
- data/doc/method_list.html +250 -0
- data/doc/top-level-namespace.html +114 -0
- data/example/bar.rb +52 -0
- data/example/foo.rb +51 -0
- data/foo.rb-bar.rb.html +498 -0
- data/lib/smart_diff/htmlize.rb +181 -0
- data/lib/smart_diff/utils.rb +29 -0
- data/lib/smart_diff.rb +49 -0
- data/spec/smart_diff/htmlize_spec.rb +33 -0
- data/spec/smart_diff/utils_spec.rb +34 -0
- data/spec/smart_diff_spec.rb +31 -0
- data/web/diff.css +96 -0
- data/web/nav.js +275 -0
- metadata +133 -0
@@ -0,0 +1,250 @@
|
|
1
|
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
2
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
3
|
+
<html>
|
4
|
+
<head>
|
5
|
+
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
6
|
+
|
7
|
+
<link rel="stylesheet" href="css/full_list.css" type="text/css" media="screen" charset="utf-8" />
|
8
|
+
|
9
|
+
<link rel="stylesheet" href="css/common.css" type="text/css" media="screen" charset="utf-8" />
|
10
|
+
|
11
|
+
|
12
|
+
|
13
|
+
<script type="text/javascript" charset="utf-8" src="js/jquery.js"></script>
|
14
|
+
|
15
|
+
<script type="text/javascript" charset="utf-8" src="js/full_list.js"></script>
|
16
|
+
|
17
|
+
|
18
|
+
<base id="base_target" target="_parent" />
|
19
|
+
</head>
|
20
|
+
<body>
|
21
|
+
<script type="text/javascript" charset="utf-8">
|
22
|
+
if (window.top.frames.main) {
|
23
|
+
document.getElementById('base_target').target = 'main';
|
24
|
+
document.body.className = 'frames';
|
25
|
+
}
|
26
|
+
</script>
|
27
|
+
<div id="content">
|
28
|
+
<h1 id="full_list_header">Method List</h1>
|
29
|
+
<div id="nav">
|
30
|
+
|
31
|
+
<span><a target="_self" href="class_list.html">
|
32
|
+
Classes
|
33
|
+
</a></span>
|
34
|
+
|
35
|
+
<span><a target="_self" href="method_list.html">
|
36
|
+
Methods
|
37
|
+
</a></span>
|
38
|
+
|
39
|
+
<span><a target="_self" href="file_list.html">
|
40
|
+
Files
|
41
|
+
</a></span>
|
42
|
+
|
43
|
+
</div>
|
44
|
+
<div id="search">Search: <input type="text" /></div>
|
45
|
+
|
46
|
+
<ul id="full_list" class="method">
|
47
|
+
|
48
|
+
|
49
|
+
<li class="r1 ">
|
50
|
+
<span class='object_link'><a href="Htmlize.html#apply_tags-instance_method" title="Htmlize#apply_tags (method)">#apply_tags</a></span>
|
51
|
+
<small>Htmlize</small>
|
52
|
+
</li>
|
53
|
+
|
54
|
+
|
55
|
+
<li class="r2 ">
|
56
|
+
<span class='object_link'><a href="Htmlize.html#change_class-instance_method" title="Htmlize#change_class (method)">#change_class</a></span>
|
57
|
+
<small>Htmlize</small>
|
58
|
+
</li>
|
59
|
+
|
60
|
+
|
61
|
+
<li class="r1 ">
|
62
|
+
<span class='object_link'><a href="Htmlize.html#change_tags-instance_method" title="Htmlize#change_tags (method)">#change_tags</a></span>
|
63
|
+
<small>Htmlize</small>
|
64
|
+
</li>
|
65
|
+
|
66
|
+
|
67
|
+
<li class="r2 ">
|
68
|
+
<span class='object_link'><a href="Htmlize.html#clear_uid-instance_method" title="Htmlize#clear_uid (method)">#clear_uid</a></span>
|
69
|
+
<small>Htmlize</small>
|
70
|
+
</li>
|
71
|
+
|
72
|
+
|
73
|
+
<li class="r1 ">
|
74
|
+
<span class='object_link'><a href="SmartDiff.html#code_one-instance_method" title="SmartDiff#code_one (method)">#code_one</a></span>
|
75
|
+
<small>SmartDiff</small>
|
76
|
+
</li>
|
77
|
+
|
78
|
+
|
79
|
+
<li class="r2 ">
|
80
|
+
<span class='object_link'><a href="SmartDiff.html#code_two-instance_method" title="SmartDiff#code_two (method)">#code_two</a></span>
|
81
|
+
<small>SmartDiff</small>
|
82
|
+
</li>
|
83
|
+
|
84
|
+
|
85
|
+
<li class="r1 ">
|
86
|
+
<span class='object_link'><a href="Htmlize.html#create_html-instance_method" title="Htmlize#create_html (method)">#create_html</a></span>
|
87
|
+
<small>Htmlize</small>
|
88
|
+
</li>
|
89
|
+
|
90
|
+
|
91
|
+
<li class="r2 ">
|
92
|
+
<span class='object_link'><a href="SmartDiff.html#diff-instance_method" title="SmartDiff#diff (method)">#diff</a></span>
|
93
|
+
<small>SmartDiff</small>
|
94
|
+
</li>
|
95
|
+
|
96
|
+
|
97
|
+
<li class="r1 ">
|
98
|
+
<span class='object_link'><a href="SmartDiff.html#file_one-instance_method" title="SmartDiff#file_one (method)">#file_one</a></span>
|
99
|
+
<small>SmartDiff</small>
|
100
|
+
</li>
|
101
|
+
|
102
|
+
|
103
|
+
<li class="r2 ">
|
104
|
+
<span class='object_link'><a href="SmartDiff.html#file_two-instance_method" title="SmartDiff#file_two (method)">#file_two</a></span>
|
105
|
+
<small>SmartDiff</small>
|
106
|
+
</li>
|
107
|
+
|
108
|
+
|
109
|
+
<li class="r1 ">
|
110
|
+
<span class='object_link'><a href="Utils.html#get_install_path-class_method" title="Utils.get_install_path (method)">get_install_path</a></span>
|
111
|
+
<small>Utils</small>
|
112
|
+
</li>
|
113
|
+
|
114
|
+
|
115
|
+
<li class="r2 ">
|
116
|
+
<span class='object_link'><a href="Htmlize.html#html_footer-instance_method" title="Htmlize#html_footer (method)">#html_footer</a></span>
|
117
|
+
<small>Htmlize</small>
|
118
|
+
</li>
|
119
|
+
|
120
|
+
|
121
|
+
<li class="r1 ">
|
122
|
+
<span class='object_link'><a href="Htmlize.html#html_header-instance_method" title="Htmlize#html_header (method)">#html_header</a></span>
|
123
|
+
<small>Htmlize</small>
|
124
|
+
</li>
|
125
|
+
|
126
|
+
|
127
|
+
<li class="r2 ">
|
128
|
+
<span class='object_link'><a href="Tag.html#idx-instance_method" title="Tag#idx (method)">#idx</a></span>
|
129
|
+
<small>Tag</small>
|
130
|
+
</li>
|
131
|
+
|
132
|
+
|
133
|
+
<li class="r1 ">
|
134
|
+
<span class='object_link'><a href="SmartDiff.html#initialize-instance_method" title="SmartDiff#initialize (method)">#initialize</a></span>
|
135
|
+
<small>SmartDiff</small>
|
136
|
+
</li>
|
137
|
+
|
138
|
+
|
139
|
+
<li class="r2 ">
|
140
|
+
<span class='object_link'><a href="Htmlize.html#initialize-instance_method" title="Htmlize#initialize (method)">#initialize</a></span>
|
141
|
+
<small>Htmlize</small>
|
142
|
+
</li>
|
143
|
+
|
144
|
+
|
145
|
+
<li class="r1 ">
|
146
|
+
<span class='object_link'><a href="Tag.html#initialize-instance_method" title="Tag#initialize (method)">#initialize</a></span>
|
147
|
+
<small>Tag</small>
|
148
|
+
</li>
|
149
|
+
|
150
|
+
|
151
|
+
<li class="r2 ">
|
152
|
+
<span class='object_link'><a href="Utils.html#inside_anchor%3F-class_method" title="Utils.inside_anchor? (method)">inside_anchor?</a></span>
|
153
|
+
<small>Utils</small>
|
154
|
+
</li>
|
155
|
+
|
156
|
+
|
157
|
+
<li class="r1 ">
|
158
|
+
<span class='object_link'><a href="Htmlize.html#link_start-instance_method" title="Htmlize#link_start (method)">#link_start</a></span>
|
159
|
+
<small>Htmlize</small>
|
160
|
+
</li>
|
161
|
+
|
162
|
+
|
163
|
+
<li class="r2 ">
|
164
|
+
<span class='object_link'><a href="SmartDiff.html#node_diff-instance_method" title="SmartDiff#node_diff (method)">#node_diff</a></span>
|
165
|
+
<small>SmartDiff</small>
|
166
|
+
</li>
|
167
|
+
|
168
|
+
|
169
|
+
<li class="r1 ">
|
170
|
+
<span class='object_link'><a href="Utils.html#node_end-class_method" title="Utils.node_end (method)">node_end</a></span>
|
171
|
+
<small>Utils</small>
|
172
|
+
</li>
|
173
|
+
|
174
|
+
|
175
|
+
<li class="r2 ">
|
176
|
+
<span class='object_link'><a href="Utils.html#node_start-class_method" title="Utils.node_start (method)">node_start</a></span>
|
177
|
+
<small>Utils</small>
|
178
|
+
</li>
|
179
|
+
|
180
|
+
|
181
|
+
<li class="r1 ">
|
182
|
+
<span class='object_link'><a href="SmartDiff.html#parse-instance_method" title="SmartDiff#parse (method)">#parse</a></span>
|
183
|
+
<small>SmartDiff</small>
|
184
|
+
</li>
|
185
|
+
|
186
|
+
|
187
|
+
<li class="r2 ">
|
188
|
+
<span class='object_link'><a href="Htmlize.html#qs-instance_method" title="Htmlize#qs (method)">#qs</a></span>
|
189
|
+
<small>Htmlize</small>
|
190
|
+
</li>
|
191
|
+
|
192
|
+
|
193
|
+
<li class="r1 ">
|
194
|
+
<span class='object_link'><a href="SmartDiff.html#read-instance_method" title="SmartDiff#read (method)">#read</a></span>
|
195
|
+
<small>SmartDiff</small>
|
196
|
+
</li>
|
197
|
+
|
198
|
+
|
199
|
+
<li class="r2 ">
|
200
|
+
<span class='object_link'><a href="Htmlize.html#span_start-instance_method" title="Htmlize#span_start (method)">#span_start</a></span>
|
201
|
+
<small>Htmlize</small>
|
202
|
+
</li>
|
203
|
+
|
204
|
+
|
205
|
+
<li class="r1 ">
|
206
|
+
<span class='object_link'><a href="Tag.html#start-instance_method" title="Tag#start (method)">#start</a></span>
|
207
|
+
<small>Tag</small>
|
208
|
+
</li>
|
209
|
+
|
210
|
+
|
211
|
+
<li class="r2 ">
|
212
|
+
<span class='object_link'><a href="Tag.html#tag-instance_method" title="Tag#tag (method)">#tag</a></span>
|
213
|
+
<small>Tag</small>
|
214
|
+
</li>
|
215
|
+
|
216
|
+
|
217
|
+
<li class="r1 ">
|
218
|
+
<span class='object_link'><a href="Tag.html#to_s-instance_method" title="Tag#to_s (method)">#to_s</a></span>
|
219
|
+
<small>Tag</small>
|
220
|
+
</li>
|
221
|
+
|
222
|
+
|
223
|
+
<li class="r2 ">
|
224
|
+
<span class='object_link'><a href="Htmlize.html#uid-instance_method" title="Htmlize#uid (method)">#uid</a></span>
|
225
|
+
<small>Htmlize</small>
|
226
|
+
</li>
|
227
|
+
|
228
|
+
|
229
|
+
<li class="r1 ">
|
230
|
+
<span class='object_link'><a href="Htmlize.html#uid_count-instance_method" title="Htmlize#uid_count (method)">#uid_count</a></span>
|
231
|
+
<small>Htmlize</small>
|
232
|
+
</li>
|
233
|
+
|
234
|
+
|
235
|
+
<li class="r2 ">
|
236
|
+
<span class='object_link'><a href="Htmlize.html#uid_hash-instance_method" title="Htmlize#uid_hash (method)">#uid_hash</a></span>
|
237
|
+
<small>Htmlize</small>
|
238
|
+
</li>
|
239
|
+
|
240
|
+
|
241
|
+
<li class="r1 ">
|
242
|
+
<span class='object_link'><a href="Htmlize.html#write_html-instance_method" title="Htmlize#write_html (method)">#write_html</a></span>
|
243
|
+
<small>Htmlize</small>
|
244
|
+
</li>
|
245
|
+
|
246
|
+
|
247
|
+
</ul>
|
248
|
+
</div>
|
249
|
+
</body>
|
250
|
+
</html>
|
@@ -0,0 +1,114 @@
|
|
1
|
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
2
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
3
|
+
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
4
|
+
<head>
|
5
|
+
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
6
|
+
<title>
|
7
|
+
Top Level Namespace
|
8
|
+
|
9
|
+
— Documentation by YARD 0.8.6.1
|
10
|
+
|
11
|
+
</title>
|
12
|
+
|
13
|
+
<link rel="stylesheet" href="css/style.css" type="text/css" charset="utf-8" />
|
14
|
+
|
15
|
+
<link rel="stylesheet" href="css/common.css" type="text/css" charset="utf-8" />
|
16
|
+
|
17
|
+
<script type="text/javascript" charset="utf-8">
|
18
|
+
hasFrames = window.top.frames.main ? true : false;
|
19
|
+
relpath = '';
|
20
|
+
framesUrl = "frames.html#!" + escape(window.location.href);
|
21
|
+
</script>
|
22
|
+
|
23
|
+
|
24
|
+
<script type="text/javascript" charset="utf-8" src="js/jquery.js"></script>
|
25
|
+
|
26
|
+
<script type="text/javascript" charset="utf-8" src="js/app.js"></script>
|
27
|
+
|
28
|
+
|
29
|
+
</head>
|
30
|
+
<body>
|
31
|
+
<div id="header">
|
32
|
+
<div id="menu">
|
33
|
+
|
34
|
+
<a href="_index.html">Index</a> »
|
35
|
+
|
36
|
+
|
37
|
+
<span class="title">Top Level Namespace</span>
|
38
|
+
|
39
|
+
|
40
|
+
<div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div>
|
41
|
+
</div>
|
42
|
+
|
43
|
+
<div id="search">
|
44
|
+
|
45
|
+
<a class="full_list_link" id="class_list_link"
|
46
|
+
href="class_list.html">
|
47
|
+
Class List
|
48
|
+
</a>
|
49
|
+
|
50
|
+
<a class="full_list_link" id="method_list_link"
|
51
|
+
href="method_list.html">
|
52
|
+
Method List
|
53
|
+
</a>
|
54
|
+
|
55
|
+
<a class="full_list_link" id="file_list_link"
|
56
|
+
href="file_list.html">
|
57
|
+
File List
|
58
|
+
</a>
|
59
|
+
|
60
|
+
</div>
|
61
|
+
<div class="clear"></div>
|
62
|
+
</div>
|
63
|
+
|
64
|
+
<iframe id="search_frame"></iframe>
|
65
|
+
|
66
|
+
<div id="content"><h1>Top Level Namespace
|
67
|
+
|
68
|
+
|
69
|
+
|
70
|
+
</h1>
|
71
|
+
|
72
|
+
<dl class="box">
|
73
|
+
|
74
|
+
|
75
|
+
|
76
|
+
|
77
|
+
|
78
|
+
|
79
|
+
|
80
|
+
|
81
|
+
</dl>
|
82
|
+
<div class="clear"></div>
|
83
|
+
|
84
|
+
<h2>Defined Under Namespace</h2>
|
85
|
+
<p class="children">
|
86
|
+
|
87
|
+
|
88
|
+
<strong class="modules">Modules:</strong> <span class='object_link'><a href="Utils.html" title="Utils (module)">Utils</a></span>
|
89
|
+
|
90
|
+
|
91
|
+
|
92
|
+
<strong class="classes">Classes:</strong> <span class='object_link'><a href="Htmlize.html" title="Htmlize (class)">Htmlize</a></span>, <span class='object_link'><a href="SmartDiff.html" title="SmartDiff (class)">SmartDiff</a></span>, <span class='object_link'><a href="Tag.html" title="Tag (class)">Tag</a></span>
|
93
|
+
|
94
|
+
|
95
|
+
</p>
|
96
|
+
|
97
|
+
|
98
|
+
|
99
|
+
|
100
|
+
|
101
|
+
|
102
|
+
|
103
|
+
|
104
|
+
|
105
|
+
</div>
|
106
|
+
|
107
|
+
<div id="footer">
|
108
|
+
Generated on Fri Sep 13 17:10:49 2013 by
|
109
|
+
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
110
|
+
0.8.6.1 (ruby-2.0.0).
|
111
|
+
</div>
|
112
|
+
|
113
|
+
</body>
|
114
|
+
</html>
|
data/example/bar.rb
ADDED
@@ -0,0 +1,52 @@
|
|
1
|
+
require "pathname"
|
2
|
+
require "filetree/simple_tree"
|
3
|
+
|
4
|
+
class Pathname
|
5
|
+
alias :_parent :parent
|
6
|
+
alias :_children :children
|
7
|
+
end
|
8
|
+
|
9
|
+
class FileTree < Pathname
|
10
|
+
include SimpleTree
|
11
|
+
|
12
|
+
attr_accessor :name, :id, :identifier
|
13
|
+
|
14
|
+
#
|
15
|
+
# See {http://rubydoc.info/stdlib/pathname/Pathname:parent Pathname.parent}
|
16
|
+
#
|
17
|
+
# @return [FileTree] The directory immediately above self.
|
18
|
+
#
|
19
|
+
def parent
|
20
|
+
ft = FileTree.new(_parent)
|
21
|
+
return ft
|
22
|
+
end
|
23
|
+
|
24
|
+
def id
|
25
|
+
@id ||= self.inspect
|
26
|
+
puts @id
|
27
|
+
end
|
28
|
+
|
29
|
+
def name
|
30
|
+
@name ||= self.inspect
|
31
|
+
end
|
32
|
+
|
33
|
+
#
|
34
|
+
# See {http://rubydoc.info/stdlib/pathname/Pathname:children Pathname.children}
|
35
|
+
#
|
36
|
+
# @return [Array] an Array of all entries contained in self.
|
37
|
+
#
|
38
|
+
def children(*args)
|
39
|
+
if self.directory?
|
40
|
+
_children(*args)
|
41
|
+
else
|
42
|
+
[]
|
43
|
+
end
|
44
|
+
end
|
45
|
+
|
46
|
+
def identifier
|
47
|
+
@identifier ||= self.inspect
|
48
|
+
end
|
49
|
+
|
50
|
+
end
|
51
|
+
|
52
|
+
puts "Some stuff"
|
data/example/foo.rb
ADDED
@@ -0,0 +1,51 @@
|
|
1
|
+
require "pathname"
|
2
|
+
require "filetree/simple_tree"
|
3
|
+
|
4
|
+
class Pathname
|
5
|
+
alias :_parent :parent
|
6
|
+
alias :_children :children
|
7
|
+
end
|
8
|
+
|
9
|
+
class FileTree < Pathname
|
10
|
+
include SimpleTree
|
11
|
+
|
12
|
+
attr_accessor :name, :id, :identifier
|
13
|
+
|
14
|
+
def name
|
15
|
+
@name ||= self.inspect
|
16
|
+
end
|
17
|
+
|
18
|
+
def id
|
19
|
+
@id ||= self.inspect
|
20
|
+
end
|
21
|
+
|
22
|
+
def identifier
|
23
|
+
@identifier ||= self.inspect
|
24
|
+
end
|
25
|
+
|
26
|
+
#
|
27
|
+
# See {http://rubydoc.info/stdlib/pathname/Pathname:parent Pathname.parent}
|
28
|
+
#
|
29
|
+
# @return [FileTree] The directory immediately above self.
|
30
|
+
#
|
31
|
+
def parent
|
32
|
+
puts "Here's Johnny!"
|
33
|
+
FileTree.new(_parent)
|
34
|
+
end
|
35
|
+
|
36
|
+
#
|
37
|
+
# See {http://rubydoc.info/stdlib/pathname/Pathname:children Pathname.children}
|
38
|
+
#
|
39
|
+
# @return [Array] an Array of all entries contained in self.
|
40
|
+
#
|
41
|
+
def children(*args)
|
42
|
+
if self.directory?
|
43
|
+
_children(*args)
|
44
|
+
else
|
45
|
+
[]
|
46
|
+
end
|
47
|
+
end
|
48
|
+
|
49
|
+
end
|
50
|
+
|
51
|
+
puts "And now for something completely different"
|