pry 0.10.0.pre2 → 0.10.0.pre3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/pry/code.rb +2 -7
- data/lib/pry/commands/cat/exception_formatter.rb +1 -1
- data/lib/pry/commands/cat/input_expression_formatter.rb +1 -1
- data/lib/pry/commands/show_source.rb +1 -1
- data/lib/pry/commands/watch_expression.rb +1 -1
- data/lib/pry/commands/watch_expression/expression.rb +2 -2
- data/lib/pry/commands/whereami.rb +1 -1
- data/lib/pry/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4664289a3e2cd574bbac76c77f855ad21e7ba7a0
|
4
|
+
data.tar.gz: 52406d51797888fd40ad5d0f26c155d99a6337d8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4166f9d2710da02d57da497660ae79e0d6c58274a926d79798808bf34577cbd5daef54cc618330674df5aa36dfa50a9570410c814928d88cd7cc67af93736700
|
7
|
+
data.tar.gz: fd7151a78d78d731cf8cdd2e57d12240911de630da071079cdf66ff5ee067bcf67c59823b4accaf660854514696655d805cb139b2280fb13970a980bb32b89b8
|
data/lib/pry/code.rb
CHANGED
@@ -253,12 +253,7 @@ class Pry
|
|
253
253
|
# @return [String] a formatted representation (based on the configuration of
|
254
254
|
# the object).
|
255
255
|
def to_s
|
256
|
-
print_to_output(""
|
257
|
-
end
|
258
|
-
|
259
|
-
# @return [String] a (possibly highlighted) copy of the source code.
|
260
|
-
def highlighted
|
261
|
-
print_to_output("", true)
|
256
|
+
print_to_output("")
|
262
257
|
end
|
263
258
|
|
264
259
|
# Writes a formatted representation (based on the configuration of the
|
@@ -266,7 +261,7 @@ class Pry
|
|
266
261
|
def print_to_output(output, color=false)
|
267
262
|
@lines.each do |loc|
|
268
263
|
loc = loc.dup
|
269
|
-
loc.colorize(@code_type)
|
264
|
+
loc.colorize(@code_type)
|
270
265
|
loc.add_line_number(max_lineno_width, color) if @with_line_numbers
|
271
266
|
loc.add_marker(@marker_lineno) if @with_marker
|
272
267
|
loc.indent(@indentation_num) if @with_indentation
|
@@ -16,7 +16,7 @@ class Pry
|
|
16
16
|
set_file_and_dir_locals(backtrace_file, _pry_, _pry_.current_context)
|
17
17
|
code = decorate(Pry::Code.from_file(backtrace_file).
|
18
18
|
between(*start_and_end_line_for_code_window).
|
19
|
-
with_marker(backtrace_line))
|
19
|
+
with_marker(backtrace_line))
|
20
20
|
"#{header}#{code}"
|
21
21
|
end
|
22
22
|
|
@@ -40,7 +40,7 @@ class Pry
|
|
40
40
|
# The source for code_object prepared for display.
|
41
41
|
def content_for(code_object)
|
42
42
|
Code.new(code_object.source, start_line_for(code_object)).
|
43
|
-
with_line_numbers(use_line_numbers?)
|
43
|
+
with_line_numbers(use_line_numbers?)
|
44
44
|
end
|
45
45
|
end
|
46
46
|
|
@@ -6,7 +6,7 @@ class Pry
|
|
6
6
|
def initialize(_pry_, target, source)
|
7
7
|
@_pry_ = _pry_
|
8
8
|
@target = target
|
9
|
-
@source =
|
9
|
+
@source = source.strip
|
10
10
|
end
|
11
11
|
|
12
12
|
def eval!
|
@@ -15,7 +15,7 @@ class Pry
|
|
15
15
|
end
|
16
16
|
|
17
17
|
def to_s
|
18
|
-
"#{Code.new(source).
|
18
|
+
"#{Code.new(source).strip} => #{value}"
|
19
19
|
end
|
20
20
|
|
21
21
|
# Has the value of the expression changed?
|
@@ -89,7 +89,7 @@ class Pry
|
|
89
89
|
set_file_and_dir_locals(@file)
|
90
90
|
|
91
91
|
out = "\n#{text.bold('From:')} #{location}:\n\n" <<
|
92
|
-
code.with_line_numbers(use_line_numbers?).with_marker(marker)
|
92
|
+
code.with_line_numbers(use_line_numbers?).with_marker(marker) << "\n"
|
93
93
|
|
94
94
|
_pry_.pager.page out
|
95
95
|
end
|
data/lib/pry/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: pry
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.10.0.
|
4
|
+
version: 0.10.0.pre3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- John Mair (banisterfiend)
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2014-05-
|
13
|
+
date: 2014-05-15 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: coderay
|