lll 1.12.0 → 1.12.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/Rakefile +0 -1
- data/VERSION +1 -1
- data/lll.gemspec +1 -56
- metadata +7 -26
data/Rakefile
CHANGED
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
1.12.
|
1
|
+
1.12.1
|
data/lll.gemspec
CHANGED
@@ -5,66 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{lll}
|
8
|
-
s.version = "1.12.
|
8
|
+
s.version = "1.12.1"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = [%q{Mark Wilden}]
|
12
12
|
s.date = %q{2011-09-10}
|
13
|
-
s.description = %q{## lll ##
|
14
|
-
|
15
|
-
lll() is used in debugging to display an expression and its value.
|
16
|
-
|
17
|
-
### Motivation ###
|
18
|
-
|
19
|
-
One of the most basic tools in debugging is printing out the values of
|
20
|
-
variables (or other expressions) during program execution:
|
21
|
-
|
22
|
-
puts user_name
|
23
|
-
|
24
|
-
Sometimes you need to label these values so you know what they're
|
25
|
-
referring to, especially if you're outputting a lot of them:
|
26
|
-
|
27
|
-
puts "user_name = #{message}"
|
28
|
-
|
29
|
-
lll() does the labelling automatically:
|
30
|
-
|
31
|
-
lll{'user_name'}
|
32
|
-
|
33
|
-
The expression is passed as a string inside a block. It's useful to
|
34
|
-
create a text editor macro that outputs <tt>lll{''}</tt> and leaves the
|
35
|
-
cursor inside the apostrophes.
|
36
|
-
|
37
|
-
### Other benefits ###
|
38
|
-
|
39
|
-
Output goes to standard output and the Rails log (if available).
|
40
|
-
|
41
|
-
Output is displayed in reverse video, so it's easy to pick out from the
|
42
|
-
log or console.
|
43
|
-
|
44
|
-
lll() uses #inspect to output the expression. It outputs Enumerable
|
45
|
-
members (except strings) on separate lines.
|
46
|
-
|
47
|
-
Output is tagged with the file and line number where it appears, so
|
48
|
-
you can easily find lll's that you forgot to take out. The time of
|
49
|
-
day (but not the date) is also printed, so you don't waste time
|
50
|
-
looking at old output.
|
51
|
-
|
52
|
-
### Outputting additional text ###
|
53
|
-
|
54
|
-
Sometimes you want to include some other string, along with the label
|
55
|
-
and value like this:
|
56
|
-
|
57
|
-
puts "After polling the queue, user_name = #{user_name}"
|
58
|
-
|
59
|
-
You can pass a string to lll() to print a string:
|
60
|
-
|
61
|
-
lll("After polling the queue"){'user_name'}
|
62
|
-
|
63
|
-
And because lll() outputs in reverse video, and to the Rails log, it can
|
64
|
-
be useful to simply print a string without an expression:
|
65
|
-
|
66
|
-
lll "After read_user"
|
67
|
-
}
|
68
13
|
s.email = %q{mark@mwilden.com}
|
69
14
|
s.extra_rdoc_files = [
|
70
15
|
"README.md"
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: lll
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.12.
|
4
|
+
version: 1.12.1
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -13,7 +13,7 @@ date: 2011-09-10 00:00:00.000000000Z
|
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rake
|
16
|
-
requirement: &
|
16
|
+
requirement: &2158011740 !ruby/object:Gem::Requirement
|
17
17
|
none: false
|
18
18
|
requirements:
|
19
19
|
- - ! '>='
|
@@ -21,10 +21,10 @@ dependencies:
|
|
21
21
|
version: '0'
|
22
22
|
type: :development
|
23
23
|
prerelease: false
|
24
|
-
version_requirements: *
|
24
|
+
version_requirements: *2158011740
|
25
25
|
- !ruby/object:Gem::Dependency
|
26
26
|
name: jeweler
|
27
|
-
requirement: &
|
27
|
+
requirement: &2158011260 !ruby/object:Gem::Requirement
|
28
28
|
none: false
|
29
29
|
requirements:
|
30
30
|
- - ! '>='
|
@@ -32,27 +32,8 @@ dependencies:
|
|
32
32
|
version: '0'
|
33
33
|
type: :development
|
34
34
|
prerelease: false
|
35
|
-
version_requirements: *
|
36
|
-
description:
|
37
|
-
its value.\n\n### Motivation ###\n\nOne of the most basic tools in debugging is
|
38
|
-
printing out the values of\nvariables (or other expressions) during program execution:\n\n
|
39
|
-
\ puts user_name\n\nSometimes you need to label these values so you know what
|
40
|
-
they're\nreferring to, especially if you're outputting a lot of them:\n\n puts
|
41
|
-
\"user_name = #{message}\"\n\nlll() does the labelling automatically: \n\n lll{'user_name'}\n\nThe
|
42
|
-
expression is passed as a string inside a block. It's useful to\ncreate a text editor
|
43
|
-
macro that outputs <tt>lll{''}</tt> and leaves the\ncursor inside the apostrophes.\n\n###
|
44
|
-
Other benefits ###\n\nOutput goes to standard output and the Rails log (if available).\n\nOutput
|
45
|
-
is displayed in reverse video, so it's easy to pick out from the\nlog or console.\n\nlll()
|
46
|
-
uses #inspect to output the expression. It outputs Enumerable\nmembers (except strings)
|
47
|
-
on separate lines.\n\nOutput is tagged with the file and line number where it appears,
|
48
|
-
so\nyou can easily find lll's that you forgot to take out. The time of\nday (but
|
49
|
-
not the date) is also printed, so you don't waste time\nlooking at old output.\n\n###
|
50
|
-
Outputting additional text ###\n\nSometimes you want to include some other string,
|
51
|
-
along with the label\nand value like this:\n\n puts \"After polling the queue,
|
52
|
-
user_name = #{user_name}\"\n\nYou can pass a string to lll() to print a string:\n\n
|
53
|
-
\ lll(\"After polling the queue\"){'user_name'}\n\nAnd because lll() outputs in
|
54
|
-
reverse video, and to the Rails log, it can\nbe useful to simply print a string
|
55
|
-
without an expression:\n\n lll \"After read_user\"\n"
|
35
|
+
version_requirements: *2158011260
|
36
|
+
description:
|
56
37
|
email: mark@mwilden.com
|
57
38
|
executables: []
|
58
39
|
extensions: []
|
@@ -82,7 +63,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
82
63
|
version: '0'
|
83
64
|
segments:
|
84
65
|
- 0
|
85
|
-
hash:
|
66
|
+
hash: 1242927181139307324
|
86
67
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
87
68
|
none: false
|
88
69
|
requirements:
|