sass 3.1.0 → 3.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/CONTRIBUTING +1 -1
- data/MIT-LICENSE +2 -2
- data/README.md +29 -17
- data/Rakefile +43 -9
- data/VERSION +1 -1
- data/VERSION_DATE +1 -0
- data/VERSION_NAME +1 -1
- data/bin/sass +6 -1
- data/bin/sass-convert +6 -1
- data/bin/scss +6 -1
- data/ext/mkrf_conf.rb +27 -0
- data/lib/sass/cache_stores/base.rb +7 -3
- data/lib/sass/cache_stores/chain.rb +3 -2
- data/lib/sass/cache_stores/filesystem.rb +5 -7
- data/lib/sass/cache_stores/memory.rb +1 -1
- data/lib/sass/cache_stores/null.rb +2 -2
- data/lib/sass/callbacks.rb +2 -1
- data/lib/sass/css.rb +168 -53
- data/lib/sass/engine.rb +502 -174
- data/lib/sass/environment.rb +151 -111
- data/lib/sass/error.rb +7 -7
- data/lib/sass/exec.rb +176 -60
- data/lib/sass/features.rb +40 -0
- data/lib/sass/importers/base.rb +46 -7
- data/lib/sass/importers/deprecated_path.rb +51 -0
- data/lib/sass/importers/filesystem.rb +113 -30
- data/lib/sass/importers.rb +1 -0
- data/lib/sass/logger/base.rb +30 -0
- data/lib/sass/logger/log_level.rb +45 -0
- data/lib/sass/logger.rb +12 -0
- data/lib/sass/media.rb +213 -0
- data/lib/sass/plugin/compiler.rb +194 -104
- data/lib/sass/plugin/configuration.rb +18 -25
- data/lib/sass/plugin/merb.rb +1 -1
- data/lib/sass/plugin/staleness_checker.rb +37 -11
- data/lib/sass/plugin.rb +10 -13
- data/lib/sass/railtie.rb +2 -1
- data/lib/sass/repl.rb +5 -6
- data/lib/sass/script/css_lexer.rb +8 -4
- data/lib/sass/script/css_parser.rb +5 -2
- data/lib/sass/script/functions.rb +1547 -618
- data/lib/sass/script/lexer.rb +122 -72
- data/lib/sass/script/parser.rb +304 -135
- data/lib/sass/script/tree/funcall.rb +306 -0
- data/lib/sass/script/{interpolation.rb → tree/interpolation.rb} +43 -13
- data/lib/sass/script/tree/list_literal.rb +77 -0
- data/lib/sass/script/tree/literal.rb +45 -0
- data/lib/sass/script/tree/map_literal.rb +64 -0
- data/lib/sass/script/{node.rb → tree/node.rb} +30 -12
- data/lib/sass/script/{operation.rb → tree/operation.rb} +33 -21
- data/lib/sass/script/{string_interpolation.rb → tree/string_interpolation.rb} +14 -4
- data/lib/sass/script/{unary_operation.rb → tree/unary_operation.rb} +21 -9
- data/lib/sass/script/tree/variable.rb +57 -0
- data/lib/sass/script/tree.rb +15 -0
- data/lib/sass/script/value/arg_list.rb +36 -0
- data/lib/sass/script/value/base.rb +238 -0
- data/lib/sass/script/value/bool.rb +40 -0
- data/lib/sass/script/{color.rb → value/color.rb} +256 -74
- data/lib/sass/script/value/deprecated_false.rb +55 -0
- data/lib/sass/script/value/helpers.rb +155 -0
- data/lib/sass/script/value/list.rb +128 -0
- data/lib/sass/script/value/map.rb +70 -0
- data/lib/sass/script/value/null.rb +49 -0
- data/lib/sass/script/{number.rb → value/number.rb} +115 -62
- data/lib/sass/script/{string.rb → value/string.rb} +9 -11
- data/lib/sass/script/value.rb +12 -0
- data/lib/sass/script.rb +35 -9
- data/lib/sass/scss/css_parser.rb +2 -12
- data/lib/sass/scss/parser.rb +657 -230
- data/lib/sass/scss/rx.rb +17 -12
- data/lib/sass/scss/static_parser.rb +37 -6
- data/lib/sass/scss.rb +0 -1
- data/lib/sass/selector/abstract_sequence.rb +35 -3
- data/lib/sass/selector/comma_sequence.rb +29 -14
- data/lib/sass/selector/sequence.rb +371 -74
- data/lib/sass/selector/simple.rb +28 -13
- data/lib/sass/selector/simple_sequence.rb +163 -36
- data/lib/sass/selector.rb +138 -36
- data/lib/sass/shared.rb +3 -5
- data/lib/sass/source/map.rb +196 -0
- data/lib/sass/source/position.rb +39 -0
- data/lib/sass/source/range.rb +41 -0
- data/lib/sass/stack.rb +126 -0
- data/lib/sass/supports.rb +228 -0
- data/lib/sass/tree/at_root_node.rb +82 -0
- data/lib/sass/tree/comment_node.rb +34 -29
- data/lib/sass/tree/content_node.rb +9 -0
- data/lib/sass/tree/css_import_node.rb +60 -0
- data/lib/sass/tree/debug_node.rb +3 -3
- data/lib/sass/tree/directive_node.rb +33 -3
- data/lib/sass/tree/each_node.rb +9 -9
- data/lib/sass/tree/extend_node.rb +20 -6
- data/lib/sass/tree/for_node.rb +6 -6
- data/lib/sass/tree/function_node.rb +12 -4
- data/lib/sass/tree/if_node.rb +2 -15
- data/lib/sass/tree/import_node.rb +11 -5
- data/lib/sass/tree/media_node.rb +27 -11
- data/lib/sass/tree/mixin_def_node.rb +15 -4
- data/lib/sass/tree/mixin_node.rb +27 -7
- data/lib/sass/tree/node.rb +69 -35
- data/lib/sass/tree/prop_node.rb +47 -31
- data/lib/sass/tree/return_node.rb +4 -3
- data/lib/sass/tree/root_node.rb +20 -4
- data/lib/sass/tree/rule_node.rb +37 -26
- data/lib/sass/tree/supports_node.rb +38 -0
- data/lib/sass/tree/trace_node.rb +33 -0
- data/lib/sass/tree/variable_node.rb +10 -4
- data/lib/sass/tree/visitors/base.rb +5 -8
- data/lib/sass/tree/visitors/check_nesting.rb +67 -52
- data/lib/sass/tree/visitors/convert.rb +134 -53
- data/lib/sass/tree/visitors/cssize.rb +245 -51
- data/lib/sass/tree/visitors/deep_copy.rb +102 -0
- data/lib/sass/tree/visitors/extend.rb +68 -0
- data/lib/sass/tree/visitors/perform.rb +331 -105
- data/lib/sass/tree/visitors/set_options.rb +125 -0
- data/lib/sass/tree/visitors/to_css.rb +259 -95
- data/lib/sass/tree/warn_node.rb +3 -3
- data/lib/sass/tree/while_node.rb +3 -3
- data/lib/sass/util/cross_platform_random.rb +19 -0
- data/lib/sass/util/multibyte_string_scanner.rb +157 -0
- data/lib/sass/util/normalized_map.rb +130 -0
- data/lib/sass/util/ordered_hash.rb +192 -0
- data/lib/sass/util/subset_map.rb +11 -2
- data/lib/sass/util/test.rb +9 -0
- data/lib/sass/util.rb +565 -39
- data/lib/sass/version.rb +27 -15
- data/lib/sass.rb +39 -4
- data/test/sass/cache_test.rb +15 -0
- data/test/sass/compiler_test.rb +223 -0
- data/test/sass/conversion_test.rb +901 -107
- data/test/sass/css2sass_test.rb +94 -0
- data/test/sass/engine_test.rb +1059 -164
- data/test/sass/exec_test.rb +86 -0
- data/test/sass/extend_test.rb +933 -837
- data/test/sass/fixtures/test_staleness_check_across_importers.css +1 -0
- data/test/sass/fixtures/test_staleness_check_across_importers.scss +1 -0
- data/test/sass/functions_test.rb +995 -136
- data/test/sass/importer_test.rb +338 -18
- data/test/sass/logger_test.rb +58 -0
- data/test/sass/more_results/more_import.css +2 -2
- data/test/sass/plugin_test.rb +114 -30
- data/test/sass/results/cached_import_option.css +3 -0
- data/test/sass/results/filename_fn.css +3 -0
- data/test/sass/results/import.css +2 -2
- data/test/sass/results/import_charset.css +1 -0
- data/test/sass/results/import_charset_1_8.css +1 -0
- data/test/sass/results/import_charset_ibm866.css +1 -0
- data/test/sass/results/import_content.css +1 -0
- data/test/sass/results/script.css +1 -1
- data/test/sass/results/scss_import.css +2 -2
- data/test/sass/results/units.css +2 -2
- data/test/sass/script_conversion_test.rb +43 -1
- data/test/sass/script_test.rb +380 -36
- data/test/sass/scss/css_test.rb +257 -75
- data/test/sass/scss/scss_test.rb +2322 -110
- data/test/sass/source_map_test.rb +887 -0
- data/test/sass/templates/_cached_import_option_partial.scss +1 -0
- data/test/sass/templates/_double_import_loop2.sass +1 -0
- data/test/sass/templates/_filename_fn_import.scss +11 -0
- data/test/sass/templates/_imported_content.sass +3 -0
- data/test/sass/templates/_same_name_different_partiality.scss +1 -0
- data/test/sass/templates/bork5.sass +3 -0
- data/test/sass/templates/cached_import_option.scss +3 -0
- data/test/sass/templates/double_import_loop1.sass +1 -0
- data/test/sass/templates/filename_fn.scss +18 -0
- data/test/sass/templates/import_charset.sass +2 -0
- data/test/sass/templates/import_charset_1_8.sass +2 -0
- data/test/sass/templates/import_charset_ibm866.sass +2 -0
- data/test/sass/templates/import_content.sass +4 -0
- data/test/sass/templates/same_name_different_ext.sass +2 -0
- data/test/sass/templates/same_name_different_ext.scss +1 -0
- data/test/sass/templates/same_name_different_partiality.scss +1 -0
- data/test/sass/templates/single_import_loop.sass +1 -0
- data/test/sass/templates/subdir/import_up1.scss +1 -0
- data/test/sass/templates/subdir/import_up2.scss +1 -0
- data/test/sass/test_helper.rb +1 -1
- data/test/sass/util/multibyte_string_scanner_test.rb +147 -0
- data/test/sass/util/normalized_map_test.rb +51 -0
- data/test/sass/util_test.rb +183 -0
- data/test/sass/value_helpers_test.rb +181 -0
- data/test/test_helper.rb +45 -5
- data/vendor/listen/CHANGELOG.md +228 -0
- data/vendor/listen/CONTRIBUTING.md +38 -0
- data/vendor/listen/Gemfile +30 -0
- data/vendor/listen/Guardfile +8 -0
- data/vendor/{fssm → listen}/LICENSE +1 -1
- data/vendor/listen/README.md +315 -0
- data/vendor/listen/Rakefile +47 -0
- data/vendor/listen/Vagrantfile +96 -0
- data/vendor/listen/lib/listen/adapter.rb +214 -0
- data/vendor/listen/lib/listen/adapters/bsd.rb +112 -0
- data/vendor/listen/lib/listen/adapters/darwin.rb +85 -0
- data/vendor/listen/lib/listen/adapters/linux.rb +113 -0
- data/vendor/listen/lib/listen/adapters/polling.rb +67 -0
- data/vendor/listen/lib/listen/adapters/windows.rb +87 -0
- data/vendor/listen/lib/listen/dependency_manager.rb +126 -0
- data/vendor/listen/lib/listen/directory_record.rb +371 -0
- data/vendor/listen/lib/listen/listener.rb +225 -0
- data/vendor/listen/lib/listen/multi_listener.rb +143 -0
- data/vendor/listen/lib/listen/turnstile.rb +28 -0
- data/vendor/listen/lib/listen/version.rb +3 -0
- data/vendor/listen/lib/listen.rb +40 -0
- data/vendor/listen/listen.gemspec +22 -0
- data/vendor/listen/spec/listen/adapter_spec.rb +183 -0
- data/vendor/listen/spec/listen/adapters/bsd_spec.rb +36 -0
- data/vendor/listen/spec/listen/adapters/darwin_spec.rb +37 -0
- data/vendor/listen/spec/listen/adapters/linux_spec.rb +47 -0
- data/vendor/listen/spec/listen/adapters/polling_spec.rb +68 -0
- data/vendor/listen/spec/listen/adapters/windows_spec.rb +30 -0
- data/vendor/listen/spec/listen/dependency_manager_spec.rb +107 -0
- data/vendor/listen/spec/listen/directory_record_spec.rb +1225 -0
- data/vendor/listen/spec/listen/listener_spec.rb +169 -0
- data/vendor/listen/spec/listen/multi_listener_spec.rb +174 -0
- data/vendor/listen/spec/listen/turnstile_spec.rb +56 -0
- data/vendor/listen/spec/listen_spec.rb +73 -0
- data/vendor/listen/spec/spec_helper.rb +21 -0
- data/vendor/listen/spec/support/adapter_helper.rb +629 -0
- data/vendor/listen/spec/support/directory_record_helper.rb +55 -0
- data/vendor/listen/spec/support/fixtures_helper.rb +29 -0
- data/vendor/listen/spec/support/listeners_helper.rb +156 -0
- data/vendor/listen/spec/support/platform_helper.rb +15 -0
- metadata +344 -271
- data/lib/sass/less.rb +0 -382
- data/lib/sass/script/bool.rb +0 -18
- data/lib/sass/script/funcall.rb +0 -162
- data/lib/sass/script/list.rb +0 -76
- data/lib/sass/script/literal.rb +0 -245
- data/lib/sass/script/variable.rb +0 -54
- data/lib/sass/scss/sass_parser.rb +0 -11
- data/test/sass/less_conversion_test.rb +0 -653
- data/vendor/fssm/README.markdown +0 -55
- data/vendor/fssm/Rakefile +0 -59
- data/vendor/fssm/VERSION.yml +0 -5
- data/vendor/fssm/example.rb +0 -9
- data/vendor/fssm/fssm.gemspec +0 -77
- data/vendor/fssm/lib/fssm/backends/fsevents.rb +0 -36
- data/vendor/fssm/lib/fssm/backends/inotify.rb +0 -26
- data/vendor/fssm/lib/fssm/backends/polling.rb +0 -25
- data/vendor/fssm/lib/fssm/backends/rubycocoa/fsevents.rb +0 -131
- data/vendor/fssm/lib/fssm/monitor.rb +0 -26
- data/vendor/fssm/lib/fssm/path.rb +0 -91
- data/vendor/fssm/lib/fssm/pathname.rb +0 -502
- data/vendor/fssm/lib/fssm/state/directory.rb +0 -57
- data/vendor/fssm/lib/fssm/state/file.rb +0 -24
- data/vendor/fssm/lib/fssm/support.rb +0 -63
- data/vendor/fssm/lib/fssm/tree.rb +0 -176
- data/vendor/fssm/lib/fssm.rb +0 -33
- data/vendor/fssm/profile/prof-cache.rb +0 -40
- data/vendor/fssm/profile/prof-fssm-pathname.html +0 -1231
- data/vendor/fssm/profile/prof-pathname.rb +0 -68
- data/vendor/fssm/profile/prof-plain-pathname.html +0 -988
- data/vendor/fssm/profile/prof.html +0 -2379
- data/vendor/fssm/spec/path_spec.rb +0 -75
- data/vendor/fssm/spec/root/duck/quack.txt +0 -0
- data/vendor/fssm/spec/root/file.css +0 -0
- data/vendor/fssm/spec/root/file.rb +0 -0
- data/vendor/fssm/spec/root/file.yml +0 -0
- data/vendor/fssm/spec/root/moo/cow.txt +0 -0
- data/vendor/fssm/spec/spec_helper.rb +0 -14
@@ -1,176 +0,0 @@
|
|
1
|
-
module FSSM::Tree
|
2
|
-
module NodeBase
|
3
|
-
def initialize
|
4
|
-
@children = {}
|
5
|
-
end
|
6
|
-
|
7
|
-
protected
|
8
|
-
|
9
|
-
def child(segment)
|
10
|
-
@children["#{segment}"]
|
11
|
-
end
|
12
|
-
|
13
|
-
def child!(segment)
|
14
|
-
(@children["#{segment}"] ||= Node.new)
|
15
|
-
end
|
16
|
-
|
17
|
-
def has_child?(segment)
|
18
|
-
@children.has_key?("#{segment}")
|
19
|
-
end
|
20
|
-
|
21
|
-
def remove_child(segment)
|
22
|
-
@children.delete("#{segment}")
|
23
|
-
end
|
24
|
-
|
25
|
-
def remove_children
|
26
|
-
@children.clear
|
27
|
-
end
|
28
|
-
end
|
29
|
-
|
30
|
-
module NodeEnumerable
|
31
|
-
include NodeBase
|
32
|
-
include Enumerable
|
33
|
-
|
34
|
-
def each(prefix=nil, &block)
|
35
|
-
@children.each do |segment, node|
|
36
|
-
cprefix = prefix ?
|
37
|
-
FSSM::Pathname.for(prefix).join(segment) :
|
38
|
-
FSSM::Pathname.for(segment)
|
39
|
-
block.call([cprefix, node])
|
40
|
-
node.each(cprefix, &block)
|
41
|
-
end
|
42
|
-
end
|
43
|
-
end
|
44
|
-
|
45
|
-
module NodeInsertion
|
46
|
-
include NodeBase
|
47
|
-
|
48
|
-
def unset(path)
|
49
|
-
key = key_segments(path)
|
50
|
-
|
51
|
-
if key.empty?
|
52
|
-
remove_children
|
53
|
-
return nil
|
54
|
-
end
|
55
|
-
|
56
|
-
segment = key.pop
|
57
|
-
node = descendant(key)
|
58
|
-
|
59
|
-
return unless node
|
60
|
-
|
61
|
-
node.remove_child(segment)
|
62
|
-
|
63
|
-
nil
|
64
|
-
end
|
65
|
-
|
66
|
-
def set(path)
|
67
|
-
node = descendant!(path)
|
68
|
-
node.from_path(path).mtime
|
69
|
-
end
|
70
|
-
|
71
|
-
protected
|
72
|
-
|
73
|
-
def key_segments(key)
|
74
|
-
return key if key.is_a?(Array)
|
75
|
-
FSSM::Pathname.for(key).segments
|
76
|
-
end
|
77
|
-
|
78
|
-
def descendant(path)
|
79
|
-
recurse(path, false)
|
80
|
-
end
|
81
|
-
|
82
|
-
def descendant!(path)
|
83
|
-
recurse(path, true)
|
84
|
-
end
|
85
|
-
|
86
|
-
def recurse(key, create=false)
|
87
|
-
key = key_segments(key)
|
88
|
-
node = self
|
89
|
-
|
90
|
-
until key.empty?
|
91
|
-
segment = key.shift
|
92
|
-
node = create ? node.child!(segment) : node.child(segment)
|
93
|
-
return nil unless node
|
94
|
-
end
|
95
|
-
|
96
|
-
node
|
97
|
-
end
|
98
|
-
end
|
99
|
-
|
100
|
-
module CacheDebug
|
101
|
-
def set(path)
|
102
|
-
FSSM.dbg("Cache#set(#{path})")
|
103
|
-
super
|
104
|
-
end
|
105
|
-
|
106
|
-
def unset(path)
|
107
|
-
FSSM.dbg("Cache#unset(#{path})")
|
108
|
-
super
|
109
|
-
end
|
110
|
-
|
111
|
-
def ftype(ft)
|
112
|
-
FSSM.dbg("Cache#ftype(#{ft})")
|
113
|
-
super
|
114
|
-
end
|
115
|
-
end
|
116
|
-
|
117
|
-
class Node
|
118
|
-
include NodeBase
|
119
|
-
include NodeEnumerable
|
120
|
-
|
121
|
-
attr_accessor :mtime
|
122
|
-
attr_accessor :ftype
|
123
|
-
|
124
|
-
def <=>(other)
|
125
|
-
return unless other.is_a?(::FSSM::Tree::Node)
|
126
|
-
self.mtime <=> other.mtime
|
127
|
-
end
|
128
|
-
|
129
|
-
def from_path(path)
|
130
|
-
path = FSSM::Pathname.for(path)
|
131
|
-
@ftype = path.ftype
|
132
|
-
# this handles bad symlinks without failing. why handle bad symlinks at
|
133
|
-
# all? well, we could still be interested in their creation and deletion.
|
134
|
-
@mtime = path.symlink? ? Time.at(0) : path.mtime
|
135
|
-
self
|
136
|
-
end
|
137
|
-
end
|
138
|
-
|
139
|
-
class Cache
|
140
|
-
include NodeBase
|
141
|
-
include NodeEnumerable
|
142
|
-
include NodeInsertion
|
143
|
-
include CacheDebug if $DEBUG
|
144
|
-
|
145
|
-
def set(path)
|
146
|
-
# all paths set from this level need to be absolute
|
147
|
-
# realpath will fail on broken links
|
148
|
-
path = FSSM::Pathname.for(path).expand_path
|
149
|
-
super(path)
|
150
|
-
end
|
151
|
-
|
152
|
-
def files
|
153
|
-
ftype('file')
|
154
|
-
end
|
155
|
-
|
156
|
-
def directories
|
157
|
-
ftype('directory')
|
158
|
-
end
|
159
|
-
|
160
|
-
def links
|
161
|
-
ftype('link')
|
162
|
-
end
|
163
|
-
|
164
|
-
alias symlinks links
|
165
|
-
|
166
|
-
private
|
167
|
-
|
168
|
-
def ftype(ft)
|
169
|
-
inject({}) do |hash, (path, node)|
|
170
|
-
hash["#{path}"] = node.mtime if node.ftype == ft
|
171
|
-
hash
|
172
|
-
end
|
173
|
-
end
|
174
|
-
end
|
175
|
-
|
176
|
-
end
|
data/vendor/fssm/lib/fssm.rb
DELETED
@@ -1,33 +0,0 @@
|
|
1
|
-
dir = File.dirname(__FILE__)
|
2
|
-
$LOAD_PATH.unshift dir unless $LOAD_PATH.include?(dir)
|
3
|
-
|
4
|
-
module FSSM
|
5
|
-
FileNotFoundError = Class.new(StandardError)
|
6
|
-
CallbackError = Class.new(StandardError)
|
7
|
-
|
8
|
-
class << self
|
9
|
-
def dbg(msg=nil)
|
10
|
-
STDERR.puts(msg)
|
11
|
-
end
|
12
|
-
|
13
|
-
def monitor(*args, &block)
|
14
|
-
monitor = FSSM::Monitor.new
|
15
|
-
FSSM::Support.use_block(args.empty? ? monitor : monitor.path(*args), block)
|
16
|
-
|
17
|
-
monitor.run
|
18
|
-
end
|
19
|
-
end
|
20
|
-
end
|
21
|
-
|
22
|
-
require 'thread'
|
23
|
-
|
24
|
-
require 'fssm/pathname'
|
25
|
-
require 'fssm/support'
|
26
|
-
require 'fssm/tree'
|
27
|
-
require 'fssm/path'
|
28
|
-
require 'fssm/state/directory'
|
29
|
-
require 'fssm/state/file'
|
30
|
-
require 'fssm/monitor'
|
31
|
-
|
32
|
-
require "fssm/backends/#{FSSM::Support.backend.downcase}"
|
33
|
-
FSSM::Backends::Default = FSSM::Backends.const_get(FSSM::Support.backend)
|
@@ -1,40 +0,0 @@
|
|
1
|
-
$:.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
|
2
|
-
|
3
|
-
require 'fssm'
|
4
|
-
|
5
|
-
require 'rubygems'
|
6
|
-
require 'ruby-prof'
|
7
|
-
|
8
|
-
$test_path = FSSM::Pathname.new('..').expand_path
|
9
|
-
$test_files = FSSM::Pathname.glob(File.join($test_path, '**', '*'))
|
10
|
-
|
11
|
-
RubyProf.start
|
12
|
-
RubyProf.pause
|
13
|
-
|
14
|
-
cache = FSSM::Tree::Cache.new
|
15
|
-
|
16
|
-
5000.times do |num|
|
17
|
-
iteration = "%-5d" % (num + 1)
|
18
|
-
print "iteration #{iteration}"
|
19
|
-
|
20
|
-
print '!'
|
21
|
-
RubyProf.resume
|
22
|
-
cache.unset($test_path)
|
23
|
-
RubyProf.pause
|
24
|
-
print '!'
|
25
|
-
|
26
|
-
$test_files.each do |fn|
|
27
|
-
print '.'
|
28
|
-
RubyProf.resume
|
29
|
-
cache.set(fn)
|
30
|
-
RubyProf.pause
|
31
|
-
end
|
32
|
-
|
33
|
-
print "\n\n"
|
34
|
-
end
|
35
|
-
|
36
|
-
result = RubyProf.stop
|
37
|
-
output = File.new('prof.html', 'w+')
|
38
|
-
|
39
|
-
printer = RubyProf::GraphHtmlPrinter.new(result)
|
40
|
-
printer.print(output, :min_percent => 1)
|