sauce_whisk 0.0.10 → 0.0.11

Sign up to get free protection for your applications and to get access to all the features.
Files changed (54) hide show
  1. checksums.yaml +6 -14
  2. data/.ruby-version +1 -1
  3. data/Gemfile +1 -4
  4. data/README.md +23 -8
  5. data/lib/sauce_whisk/tunnels.rb +0 -1
  6. data/lib/sauce_whisk/version.rb +1 -1
  7. data/lib/sauce_whisk.rb +7 -0
  8. metadata +19 -65
  9. data/vendor/psych/lib/psych/class_loader.rb +0 -101
  10. data/vendor/psych/lib/psych/coder.rb +0 -94
  11. data/vendor/psych/lib/psych/core_ext.rb +0 -35
  12. data/vendor/psych/lib/psych/deprecated.rb +0 -85
  13. data/vendor/psych/lib/psych/exception.rb +0 -13
  14. data/vendor/psych/lib/psych/handler.rb +0 -249
  15. data/vendor/psych/lib/psych/handlers/document_stream.rb +0 -22
  16. data/vendor/psych/lib/psych/handlers/recorder.rb +0 -39
  17. data/vendor/psych/lib/psych/json/ruby_events.rb +0 -19
  18. data/vendor/psych/lib/psych/json/stream.rb +0 -16
  19. data/vendor/psych/lib/psych/json/tree_builder.rb +0 -12
  20. data/vendor/psych/lib/psych/json/yaml_events.rb +0 -29
  21. data/vendor/psych/lib/psych/nodes/alias.rb +0 -18
  22. data/vendor/psych/lib/psych/nodes/document.rb +0 -60
  23. data/vendor/psych/lib/psych/nodes/mapping.rb +0 -56
  24. data/vendor/psych/lib/psych/nodes/node.rb +0 -55
  25. data/vendor/psych/lib/psych/nodes/scalar.rb +0 -67
  26. data/vendor/psych/lib/psych/nodes/sequence.rb +0 -81
  27. data/vendor/psych/lib/psych/nodes/stream.rb +0 -37
  28. data/vendor/psych/lib/psych/nodes.rb +0 -77
  29. data/vendor/psych/lib/psych/omap.rb +0 -4
  30. data/vendor/psych/lib/psych/parser.rb +0 -51
  31. data/vendor/psych/lib/psych/scalar_scanner.rb +0 -149
  32. data/vendor/psych/lib/psych/set.rb +0 -4
  33. data/vendor/psych/lib/psych/stream.rb +0 -37
  34. data/vendor/psych/lib/psych/streaming.rb +0 -27
  35. data/vendor/psych/lib/psych/syntax_error.rb +0 -21
  36. data/vendor/psych/lib/psych/tree_builder.rb +0 -96
  37. data/vendor/psych/lib/psych/visitors/depth_first.rb +0 -26
  38. data/vendor/psych/lib/psych/visitors/emitter.rb +0 -51
  39. data/vendor/psych/lib/psych/visitors/json_tree.rb +0 -24
  40. data/vendor/psych/lib/psych/visitors/to_ruby.rb +0 -372
  41. data/vendor/psych/lib/psych/visitors/visitor.rb +0 -19
  42. data/vendor/psych/lib/psych/visitors/yaml_tree.rb +0 -496
  43. data/vendor/psych/lib/psych/visitors.rb +0 -6
  44. data/vendor/psych/lib/psych/y.rb +0 -9
  45. data/vendor/psych/lib/psych.bundle +0 -0
  46. data/vendor/psych/lib/psych.rb +0 -497
  47. data/vendor/psych/tmp/x86_64-darwin12.3.0/psych/1.9.3/Makefile +0 -221
  48. data/vendor/psych/tmp/x86_64-darwin12.3.0/psych/1.9.3/mkmf.log +0 -50
  49. data/vendor/psych/tmp/x86_64-darwin12.3.0/psych/1.9.3/psych.bundle +0 -0
  50. data/vendor/psych/tmp/x86_64-darwin12.3.0/psych/1.9.3/psych.o +0 -0
  51. data/vendor/psych/tmp/x86_64-darwin12.3.0/psych/1.9.3/psych_emitter.o +0 -0
  52. data/vendor/psych/tmp/x86_64-darwin12.3.0/psych/1.9.3/psych_parser.o +0 -0
  53. data/vendor/psych/tmp/x86_64-darwin12.3.0/psych/1.9.3/psych_to_ruby.o +0 -0
  54. data/vendor/psych/tmp/x86_64-darwin12.3.0/psych/1.9.3/psych_yaml_tree.o +0 -0
@@ -1,249 +0,0 @@
1
- module Psych
2
- ###
3
- # Psych::Handler is an abstract base class that defines the events used
4
- # when dealing with Psych::Parser. Clients who want to use Psych::Parser
5
- # should implement a class that inherits from Psych::Handler and define
6
- # events that they can handle.
7
- #
8
- # Psych::Handler defines all events that Psych::Parser can possibly send to
9
- # event handlers.
10
- #
11
- # See Psych::Parser for more details
12
- class Handler
13
- ###
14
- # Configuration options for dumping YAML.
15
- class DumperOptions
16
- attr_accessor :line_width, :indentation, :canonical
17
-
18
- def initialize
19
- @line_width = 0
20
- @indentation = 2
21
- @canonical = false
22
- end
23
- end
24
-
25
- # Default dumping options
26
- OPTIONS = DumperOptions.new
27
-
28
- # Events that a Handler should respond to.
29
- EVENTS = [ :alias,
30
- :empty,
31
- :end_document,
32
- :end_mapping,
33
- :end_sequence,
34
- :end_stream,
35
- :scalar,
36
- :start_document,
37
- :start_mapping,
38
- :start_sequence,
39
- :start_stream ]
40
-
41
- ###
42
- # Called with +encoding+ when the YAML stream starts. This method is
43
- # called once per stream. A stream may contain multiple documents.
44
- #
45
- # See the constants in Psych::Parser for the possible values of +encoding+.
46
- def start_stream encoding
47
- end
48
-
49
- ###
50
- # Called when the document starts with the declared +version+,
51
- # +tag_directives+, if the document is +implicit+.
52
- #
53
- # +version+ will be an array of integers indicating the YAML version being
54
- # dealt with, +tag_directives+ is a list of tuples indicating the prefix
55
- # and suffix of each tag, and +implicit+ is a boolean indicating whether
56
- # the document is started implicitly.
57
- #
58
- # === Example
59
- #
60
- # Given the following YAML:
61
- #
62
- # %YAML 1.1
63
- # %TAG ! tag:tenderlovemaking.com,2009:
64
- # --- !squee
65
- #
66
- # The parameters for start_document must be this:
67
- #
68
- # version # => [1, 1]
69
- # tag_directives # => [["!", "tag:tenderlovemaking.com,2009:"]]
70
- # implicit # => false
71
- def start_document version, tag_directives, implicit
72
- end
73
-
74
- ###
75
- # Called with the document ends. +implicit+ is a boolean value indicating
76
- # whether or not the document has an implicit ending.
77
- #
78
- # === Example
79
- #
80
- # Given the following YAML:
81
- #
82
- # ---
83
- # hello world
84
- #
85
- # +implicit+ will be true. Given this YAML:
86
- #
87
- # ---
88
- # hello world
89
- # ...
90
- #
91
- # +implicit+ will be false.
92
- def end_document implicit
93
- end
94
-
95
- ###
96
- # Called when an alias is found to +anchor+. +anchor+ will be the name
97
- # of the anchor found.
98
- #
99
- # === Example
100
- #
101
- # Here we have an example of an array that references itself in YAML:
102
- #
103
- # --- &ponies
104
- # - first element
105
- # - *ponies
106
- #
107
- # &ponies is the achor, *ponies is the alias. In this case, alias is
108
- # called with "ponies".
109
- def alias anchor
110
- end
111
-
112
- ###
113
- # Called when a scalar +value+ is found. The scalar may have an
114
- # +anchor+, a +tag+, be implicitly +plain+ or implicitly +quoted+
115
- #
116
- # +value+ is the string value of the scalar
117
- # +anchor+ is an associated anchor or nil
118
- # +tag+ is an associated tag or nil
119
- # +plain+ is a boolean value
120
- # +quoted+ is a boolean value
121
- # +style+ is an integer idicating the string style
122
- #
123
- # See the constants in Psych::Nodes::Scalar for the possible values of
124
- # +style+
125
- #
126
- # === Example
127
- #
128
- # Here is a YAML document that exercises most of the possible ways this
129
- # method can be called:
130
- #
131
- # ---
132
- # - !str "foo"
133
- # - &anchor fun
134
- # - many
135
- # lines
136
- # - |
137
- # many
138
- # newlines
139
- #
140
- # The above YAML document contains a list with four strings. Here are
141
- # the parameters sent to this method in the same order:
142
- #
143
- # # value anchor tag plain quoted style
144
- # ["foo", nil, "!str", false, false, 3 ]
145
- # ["fun", "anchor", nil, true, false, 1 ]
146
- # ["many lines", nil, nil, true, false, 1 ]
147
- # ["many\nnewlines\n", nil, nil, false, true, 4 ]
148
- #
149
- def scalar value, anchor, tag, plain, quoted, style
150
- end
151
-
152
- ###
153
- # Called when a sequence is started.
154
- #
155
- # +anchor+ is the anchor associated with the sequence or nil.
156
- # +tag+ is the tag associated with the sequence or nil.
157
- # +implicit+ a boolean indicating whether or not the sequence was implicitly
158
- # started.
159
- # +style+ is an integer indicating the list style.
160
- #
161
- # See the constants in Psych::Nodes::Sequence for the possible values of
162
- # +style+.
163
- #
164
- # === Example
165
- #
166
- # Here is a YAML document that exercises most of the possible ways this
167
- # method can be called:
168
- #
169
- # ---
170
- # - !!seq [
171
- # a
172
- # ]
173
- # - &pewpew
174
- # - b
175
- #
176
- # The above YAML document consists of three lists, an outer list that
177
- # contains two inner lists. Here is a matrix of the parameters sent
178
- # to represent these lists:
179
- #
180
- # # anchor tag implicit style
181
- # [nil, nil, true, 1 ]
182
- # [nil, "tag:yaml.org,2002:seq", false, 2 ]
183
- # ["pewpew", nil, true, 1 ]
184
-
185
- def start_sequence anchor, tag, implicit, style
186
- end
187
-
188
- ###
189
- # Called when a sequence ends.
190
- def end_sequence
191
- end
192
-
193
- ###
194
- # Called when a map starts.
195
- #
196
- # +anchor+ is the anchor associated with the map or +nil+.
197
- # +tag+ is the tag associated with the map or +nil+.
198
- # +implicit+ is a boolean indicating whether or not the map was implicitly
199
- # started.
200
- # +style+ is an integer indicating the mapping style.
201
- #
202
- # See the constants in Psych::Nodes::Mapping for the possible values of
203
- # +style+.
204
- #
205
- # === Example
206
- #
207
- # Here is a YAML document that exercises most of the possible ways this
208
- # method can be called:
209
- #
210
- # ---
211
- # k: !!map { hello: world }
212
- # v: &pewpew
213
- # hello: world
214
- #
215
- # The above YAML document consists of three maps, an outer map that contains
216
- # two inner maps. Below is a matrix of the parameters sent in order to
217
- # represent these three maps:
218
- #
219
- # # anchor tag implicit style
220
- # [nil, nil, true, 1 ]
221
- # [nil, "tag:yaml.org,2002:map", false, 2 ]
222
- # ["pewpew", nil, true, 1 ]
223
-
224
- def start_mapping anchor, tag, implicit, style
225
- end
226
-
227
- ###
228
- # Called when a map ends
229
- def end_mapping
230
- end
231
-
232
- ###
233
- # Called when an empty event happens. (Which, as far as I can tell, is
234
- # never).
235
- def empty
236
- end
237
-
238
- ###
239
- # Called when the YAML stream ends
240
- def end_stream
241
- end
242
-
243
- ###
244
- # Is this handler a streaming handler?
245
- def streaming?
246
- false
247
- end
248
- end
249
- end
@@ -1,22 +0,0 @@
1
- require 'psych/tree_builder'
2
-
3
- module Psych
4
- module Handlers
5
- class DocumentStream < Psych::TreeBuilder # :nodoc:
6
- def initialize &block
7
- super
8
- @block = block
9
- end
10
-
11
- def start_document version, tag_directives, implicit
12
- n = Nodes::Document.new version, tag_directives, implicit
13
- push n
14
- end
15
-
16
- def end_document implicit_end = !streaming?
17
- @last.implicit_end = implicit_end
18
- @block.call pop
19
- end
20
- end
21
- end
22
- end
@@ -1,39 +0,0 @@
1
- require 'psych/handler'
2
-
3
- module Psych
4
- module Handlers
5
- ###
6
- # This handler will capture an event and record the event. Recorder events
7
- # are available vial Psych::Handlers::Recorder#events.
8
- #
9
- # For example:
10
- #
11
- # recorder = Psych::Handlers::Recorder.new
12
- # parser = Psych::Parser.new recorder
13
- # parser.parse '--- foo'
14
- #
15
- # recorder.events # => [list of events]
16
- #
17
- # # Replay the events
18
- #
19
- # emitter = Psych::Emitter.new $stdout
20
- # recorder.events.each do |m, args|
21
- # emitter.send m, *args
22
- # end
23
-
24
- class Recorder < Psych::Handler
25
- attr_reader :events
26
-
27
- def initialize
28
- @events = []
29
- super
30
- end
31
-
32
- EVENTS.each do |event|
33
- define_method event do |*args|
34
- @events << [event, args]
35
- end
36
- end
37
- end
38
- end
39
- end
@@ -1,19 +0,0 @@
1
- module Psych
2
- module JSON
3
- module RubyEvents # :nodoc:
4
- def visit_Time o
5
- formatted = format_time o
6
- @emitter.scalar formatted, nil, nil, false, true, Nodes::Scalar::DOUBLE_QUOTED
7
- end
8
-
9
- def visit_DateTime o
10
- visit_Time o.to_time
11
- end
12
-
13
- def visit_String o
14
- @emitter.scalar o.to_s, nil, nil, false, true, Nodes::Scalar::DOUBLE_QUOTED
15
- end
16
- alias :visit_Symbol :visit_String
17
- end
18
- end
19
- end
@@ -1,16 +0,0 @@
1
- require 'psych/json/ruby_events'
2
- require 'psych/json/yaml_events'
3
-
4
- module Psych
5
- module JSON
6
- class Stream < Psych::Visitors::JSONTree
7
- include Psych::JSON::RubyEvents
8
- include Psych::Streaming
9
- extend Psych::Streaming::ClassMethods
10
-
11
- class Emitter < Psych::Stream::Emitter # :nodoc:
12
- include Psych::JSON::YAMLEvents
13
- end
14
- end
15
- end
16
- end
@@ -1,12 +0,0 @@
1
- require 'psych/json/yaml_events'
2
-
3
- module Psych
4
- module JSON
5
- ###
6
- # Psych::JSON::TreeBuilder is an event based AST builder. Events are sent
7
- # to an instance of Psych::JSON::TreeBuilder and a JSON AST is constructed.
8
- class TreeBuilder < Psych::TreeBuilder
9
- include Psych::JSON::YAMLEvents
10
- end
11
- end
12
- end
@@ -1,29 +0,0 @@
1
- module Psych
2
- module JSON
3
- module YAMLEvents # :nodoc:
4
- def start_document version, tag_directives, implicit
5
- super(version, tag_directives, !streaming?)
6
- end
7
-
8
- def end_document implicit_end = !streaming?
9
- super(implicit_end)
10
- end
11
-
12
- def start_mapping anchor, tag, implicit, style
13
- super(anchor, nil, true, Nodes::Mapping::FLOW)
14
- end
15
-
16
- def start_sequence anchor, tag, implicit, style
17
- super(anchor, nil, true, Nodes::Sequence::FLOW)
18
- end
19
-
20
- def scalar value, anchor, tag, plain, quoted, style
21
- if "tag:yaml.org,2002:null" == tag
22
- super('null', nil, nil, true, false, Nodes::Scalar::PLAIN)
23
- else
24
- super
25
- end
26
- end
27
- end
28
- end
29
- end
@@ -1,18 +0,0 @@
1
- module Psych
2
- module Nodes
3
- ###
4
- # This class represents a {YAML Alias}[http://yaml.org/spec/1.1/#alias].
5
- # It points to an +anchor+.
6
- #
7
- # A Psych::Nodes::Alias is a terminal node and may have no children.
8
- class Alias < Psych::Nodes::Node
9
- # The anchor this alias links to
10
- attr_accessor :anchor
11
-
12
- # Create a new Alias that points to an +anchor+
13
- def initialize anchor
14
- @anchor = anchor
15
- end
16
- end
17
- end
18
- end
@@ -1,60 +0,0 @@
1
- module Psych
2
- module Nodes
3
- ###
4
- # This represents a YAML Document. This node must be a child of
5
- # Psych::Nodes::Stream. A Psych::Nodes::Document must have one child,
6
- # and that child may be one of the following:
7
- #
8
- # * Psych::Nodes::Sequence
9
- # * Psych::Nodes::Mapping
10
- # * Psych::Nodes::Scalar
11
- class Document < Psych::Nodes::Node
12
- # The version of the YAML document
13
- attr_accessor :version
14
-
15
- # A list of tag directives for this document
16
- attr_accessor :tag_directives
17
-
18
- # Was this document implicitly created?
19
- attr_accessor :implicit
20
-
21
- # Is the end of the document implicit?
22
- attr_accessor :implicit_end
23
-
24
- ###
25
- # Create a new Psych::Nodes::Document object.
26
- #
27
- # +version+ is a list indicating the YAML version.
28
- # +tags_directives+ is a list of tag directive declarations
29
- # +implicit+ is a flag indicating whether the document will be implicitly
30
- # started.
31
- #
32
- # == Example:
33
- # This creates a YAML document object that represents a YAML 1.1 document
34
- # with one tag directive, and has an implicit start:
35
- #
36
- # Psych::Nodes::Document.new(
37
- # [1,1],
38
- # [["!", "tag:tenderlovemaking.com,2009:"]],
39
- # true
40
- # )
41
- #
42
- # == See Also
43
- # See also Psych::Handler#start_document
44
- def initialize version = [], tag_directives = [], implicit = false
45
- super()
46
- @version = version
47
- @tag_directives = tag_directives
48
- @implicit = implicit
49
- @implicit_end = true
50
- end
51
-
52
- ###
53
- # Returns the root node. A Document may only have one root node:
54
- # http://yaml.org/spec/1.1/#id898031
55
- def root
56
- children.first
57
- end
58
- end
59
- end
60
- end
@@ -1,56 +0,0 @@
1
- module Psych
2
- module Nodes
3
- ###
4
- # This class represents a {YAML Mapping}[http://yaml.org/spec/1.1/#mapping].
5
- #
6
- # A Psych::Nodes::Mapping node may have 0 or more children, but must have
7
- # an even number of children. Here are the valid children a
8
- # Psych::Nodes::Mapping node may have:
9
- #
10
- # * Psych::Nodes::Sequence
11
- # * Psych::Nodes::Mapping
12
- # * Psych::Nodes::Scalar
13
- # * Psych::Nodes::Alias
14
- class Mapping < Psych::Nodes::Node
15
- # Any Map Style
16
- ANY = 0
17
-
18
- # Block Map Style
19
- BLOCK = 1
20
-
21
- # Flow Map Style
22
- FLOW = 2
23
-
24
- # The optional anchor for this mapping
25
- attr_accessor :anchor
26
-
27
- # The optional tag for this mapping
28
- attr_accessor :tag
29
-
30
- # Is this an implicit mapping?
31
- attr_accessor :implicit
32
-
33
- # The style of this mapping
34
- attr_accessor :style
35
-
36
- ###
37
- # Create a new Psych::Nodes::Mapping object.
38
- #
39
- # +anchor+ is the anchor associated with the map or +nil+.
40
- # +tag+ is the tag associated with the map or +nil+.
41
- # +implicit+ is a boolean indicating whether or not the map was implicitly
42
- # started.
43
- # +style+ is an integer indicating the mapping style.
44
- #
45
- # == See Also
46
- # See also Psych::Handler#start_mapping
47
- def initialize anchor = nil, tag = nil, implicit = true, style = BLOCK
48
- super()
49
- @anchor = anchor
50
- @tag = tag
51
- @implicit = implicit
52
- @style = style
53
- end
54
- end
55
- end
56
- end
@@ -1,55 +0,0 @@
1
- require 'stringio'
2
- require 'psych/class_loader'
3
- require 'psych/scalar_scanner'
4
-
5
- module Psych
6
- module Nodes
7
- ###
8
- # The base class for any Node in a YAML parse tree. This class should
9
- # never be instantiated.
10
- class Node
11
- include Enumerable
12
-
13
- # The children of this node
14
- attr_reader :children
15
-
16
- # An associated tag
17
- attr_reader :tag
18
-
19
- # Create a new Psych::Nodes::Node
20
- def initialize
21
- @children = []
22
- end
23
-
24
- ###
25
- # Iterate over each node in the tree. Yields each node to +block+ depth
26
- # first.
27
- def each &block
28
- return enum_for :each unless block_given?
29
- Visitors::DepthFirst.new(block).accept self
30
- end
31
-
32
- ###
33
- # Convert this node to Ruby.
34
- #
35
- # See also Psych::Visitors::ToRuby
36
- def to_ruby
37
- Visitors::ToRuby.create.accept(self)
38
- end
39
- alias :transform :to_ruby
40
-
41
- ###
42
- # Convert this node to YAML.
43
- #
44
- # See also Psych::Visitors::Emitter
45
- def yaml io = nil, options = {}
46
- real_io = io || StringIO.new(''.encode('utf-8'))
47
-
48
- Visitors::Emitter.new(real_io, options).accept self
49
- return real_io.string unless io
50
- io
51
- end
52
- alias :to_yaml :yaml
53
- end
54
- end
55
- end
@@ -1,67 +0,0 @@
1
- module Psych
2
- module Nodes
3
- ###
4
- # This class represents a {YAML Scalar}[http://yaml.org/spec/1.1/#id858081].
5
- #
6
- # This node type is a terminal node and should not have any children.
7
- class Scalar < Psych::Nodes::Node
8
- # Any style scalar, the emitter chooses
9
- ANY = 0
10
-
11
- # Plain scalar style
12
- PLAIN = 1
13
-
14
- # Single quoted style
15
- SINGLE_QUOTED = 2
16
-
17
- # Double quoted style
18
- DOUBLE_QUOTED = 3
19
-
20
- # Literal style
21
- LITERAL = 4
22
-
23
- # Folded style
24
- FOLDED = 5
25
-
26
- # The scalar value
27
- attr_accessor :value
28
-
29
- # The anchor value (if there is one)
30
- attr_accessor :anchor
31
-
32
- # The tag value (if there is one)
33
- attr_accessor :tag
34
-
35
- # Is this a plain scalar?
36
- attr_accessor :plain
37
-
38
- # Is this scalar quoted?
39
- attr_accessor :quoted
40
-
41
- # The style of this scalar
42
- attr_accessor :style
43
-
44
- ###
45
- # Create a new Psych::Nodes::Scalar object.
46
- #
47
- # +value+ is the string value of the scalar
48
- # +anchor+ is an associated anchor or nil
49
- # +tag+ is an associated tag or nil
50
- # +plain+ is a boolean value
51
- # +quoted+ is a boolean value
52
- # +style+ is an integer idicating the string style
53
- #
54
- # == See Also
55
- #
56
- # See also Psych::Handler#scalar
57
- def initialize value, anchor = nil, tag = nil, plain = true, quoted = false, style = ANY
58
- @value = value
59
- @anchor = anchor
60
- @tag = tag
61
- @plain = plain
62
- @quoted = quoted
63
- @style = style
64
- end
65
- end
66
- end
67
- end