wirb 0.4.0 → 0.4.1
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGELOG.rdoc +4 -0
- data/README.rdoc +11 -1
- data/data/wirb/classic_paint.yml +3 -4
- data/data/wirb/colorless.yml +79 -0
- data/lib/wirb.rb +2 -2
- data/lib/wirb/version.rb +1 -1
- metadata +93 -93
data/CHANGELOG.rdoc
CHANGED
data/README.rdoc
CHANGED
@@ -46,11 +46,21 @@ Color schemas wanted! You've got a good looking alternative color schema? Please
|
|
46
46
|
|
47
47
|
Colorizers wanted! Your favorite terminal colors gem is not supported yet? Please fork and add it to <tt>lib/wirb/colorizer/*</tt> :D
|
48
48
|
|
49
|
+
=== Bundled schemas
|
50
|
+
|
51
|
+
The following schemas are bundled (load with <tt>Wirb.load_schema :name</tt> and make sure the used colorizer is available).
|
52
|
+
|
53
|
+
==== Wirb0
|
54
|
+
* <tt>:classic_wirb0</tt> (current default)
|
55
|
+
|
56
|
+
==== Paint
|
57
|
+
* <tt>:classic_paint</tt> (paint implementation of default)
|
58
|
+
* <tt>:colorless</tt> (only uses :bright, :underline and :inverse effect)
|
59
|
+
|
49
60
|
== wp
|
50
61
|
You can colorize any object with <tt>wp</tt> (wavy_print):
|
51
62
|
require 'wirb/wp'
|
52
63
|
wp some_object
|
53
|
-
wp some_object, :light_red
|
54
64
|
|
55
65
|
== Also see
|
56
66
|
* Configure views for specific objects: hirb[https://github.com/cldwalker/hirb]
|
data/data/wirb/classic_paint.yml
CHANGED
@@ -13,7 +13,6 @@ open_array:
|
|
13
13
|
- :green
|
14
14
|
- :bright
|
15
15
|
close_array:
|
16
|
-
- nil
|
17
16
|
- :green
|
18
17
|
- :bright
|
19
18
|
open_set:
|
@@ -58,10 +57,10 @@ object_line_number:
|
|
58
57
|
- :brown
|
59
58
|
- :underline
|
60
59
|
object_variable_prefix:
|
61
|
-
- :
|
60
|
+
- :magenta
|
62
61
|
- :bright
|
63
62
|
object_variable:
|
64
|
-
- :
|
63
|
+
- :magenta
|
65
64
|
- :bright
|
66
65
|
close_object:
|
67
66
|
- :green
|
@@ -122,7 +121,7 @@ close_rational:
|
|
122
121
|
#default:
|
123
122
|
#keyword:
|
124
123
|
time:
|
125
|
-
- :
|
124
|
+
- :magenta
|
126
125
|
nil:
|
127
126
|
- :red
|
128
127
|
- :bright
|
@@ -0,0 +1,79 @@
|
|
1
|
+
colorizer:
|
2
|
+
- Paint
|
3
|
+
- Wirb0_Paint
|
4
|
+
|
5
|
+
# container
|
6
|
+
open_hash:
|
7
|
+
close_hash:
|
8
|
+
open_array:
|
9
|
+
close_array:
|
10
|
+
open_set:
|
11
|
+
close_set:
|
12
|
+
|
13
|
+
# delimiter
|
14
|
+
comma:
|
15
|
+
refers:
|
16
|
+
|
17
|
+
# class
|
18
|
+
class:
|
19
|
+
- :bright
|
20
|
+
class_separator:
|
21
|
+
object_class:
|
22
|
+
- :bright
|
23
|
+
|
24
|
+
# object
|
25
|
+
open_object:
|
26
|
+
object_description_prefix:
|
27
|
+
object_description:
|
28
|
+
object_address_prefix:
|
29
|
+
object_address:
|
30
|
+
object_line_prefix:
|
31
|
+
object_line:
|
32
|
+
object_line_number:
|
33
|
+
object_variable_prefix:
|
34
|
+
object_variable:
|
35
|
+
close_object:
|
36
|
+
|
37
|
+
# symbol
|
38
|
+
symbol_prefix:
|
39
|
+
symbol:
|
40
|
+
- :bright
|
41
|
+
open_symbol_string:
|
42
|
+
symbol_string:
|
43
|
+
- :bright
|
44
|
+
close_symbol_string:
|
45
|
+
|
46
|
+
# string
|
47
|
+
open_string:
|
48
|
+
string:
|
49
|
+
- :underline
|
50
|
+
close_string:
|
51
|
+
|
52
|
+
# regexp
|
53
|
+
open_regexp:
|
54
|
+
regexp:
|
55
|
+
- :underline
|
56
|
+
close_regexp:
|
57
|
+
regexp_flags:
|
58
|
+
|
59
|
+
# number
|
60
|
+
number:
|
61
|
+
- :bright
|
62
|
+
range:
|
63
|
+
open_rational:
|
64
|
+
rational_separator:
|
65
|
+
close_rational:
|
66
|
+
|
67
|
+
# misc
|
68
|
+
default:
|
69
|
+
keyword:
|
70
|
+
time:
|
71
|
+
nil:
|
72
|
+
- :inverse
|
73
|
+
false:
|
74
|
+
- :inverse
|
75
|
+
true:
|
76
|
+
- :inverse
|
77
|
+
gem_requirement_condition:
|
78
|
+
- :bright
|
79
|
+
gem_requirement_version:
|
data/lib/wirb.rb
CHANGED
@@ -39,7 +39,7 @@ class << Wirb
|
|
39
39
|
def load_colorizer(colorizer_name)
|
40
40
|
# @colorizer = Wirb::Colorizer.const_get(colorizer_name, false)
|
41
41
|
@colorizer = eval "Wirb::Colorizer::#{colorizer_name}"
|
42
|
-
|
42
|
+
compatible_colorizer?(@colorizer)
|
43
43
|
@colorizer
|
44
44
|
end
|
45
45
|
|
@@ -114,7 +114,7 @@ class << Wirb
|
|
114
114
|
|
115
115
|
private
|
116
116
|
|
117
|
-
def
|
117
|
+
def compatible_colorizer?(col)
|
118
118
|
short_col = col.to_s.sub(/^.*::(.*?)$/, '\1').to_sym
|
119
119
|
if !col
|
120
120
|
warn "No colorizer selected!"
|
data/lib/wirb/version.rb
CHANGED
metadata
CHANGED
@@ -1,152 +1,152 @@
|
|
1
|
-
--- !ruby/object:Gem::Specification
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
2
|
name: wirb
|
3
|
-
version: !ruby/object:Gem::Version
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.4.1
|
4
5
|
prerelease:
|
5
|
-
version: 0.4.0
|
6
6
|
platform: ruby
|
7
|
-
authors:
|
7
|
+
authors:
|
8
8
|
- Jan Lelis
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
- !ruby/object:Gem::Dependency
|
12
|
+
date: 2011-07-08 00:00:00.000000000Z
|
13
|
+
dependencies:
|
14
|
+
- !ruby/object:Gem::Dependency
|
16
15
|
name: rspec
|
17
|
-
|
18
|
-
requirement: &id001 !ruby/object:Gem::Requirement
|
16
|
+
requirement: &22010080 !ruby/object:Gem::Requirement
|
19
17
|
none: false
|
20
|
-
requirements:
|
21
|
-
- -
|
22
|
-
- !ruby/object:Gem::Version
|
23
|
-
version:
|
18
|
+
requirements:
|
19
|
+
- - ! '>='
|
20
|
+
- !ruby/object:Gem::Version
|
21
|
+
version: '0'
|
24
22
|
type: :development
|
25
|
-
version_requirements: *id001
|
26
|
-
- !ruby/object:Gem::Dependency
|
27
|
-
name: rspec-core
|
28
23
|
prerelease: false
|
29
|
-
|
24
|
+
version_requirements: *22010080
|
25
|
+
- !ruby/object:Gem::Dependency
|
26
|
+
name: rspec-core
|
27
|
+
requirement: &22009620 !ruby/object:Gem::Requirement
|
30
28
|
none: false
|
31
|
-
requirements:
|
32
|
-
- -
|
33
|
-
- !ruby/object:Gem::Version
|
34
|
-
version:
|
29
|
+
requirements:
|
30
|
+
- - ! '>='
|
31
|
+
- !ruby/object:Gem::Version
|
32
|
+
version: '0'
|
35
33
|
type: :development
|
36
|
-
version_requirements: *id002
|
37
|
-
- !ruby/object:Gem::Dependency
|
38
|
-
name: rake
|
39
34
|
prerelease: false
|
40
|
-
|
35
|
+
version_requirements: *22009620
|
36
|
+
- !ruby/object:Gem::Dependency
|
37
|
+
name: rake
|
38
|
+
requirement: &22009200 !ruby/object:Gem::Requirement
|
41
39
|
none: false
|
42
|
-
requirements:
|
43
|
-
- -
|
44
|
-
- !ruby/object:Gem::Version
|
45
|
-
version:
|
40
|
+
requirements:
|
41
|
+
- - ! '>='
|
42
|
+
- !ruby/object:Gem::Version
|
43
|
+
version: '0'
|
46
44
|
type: :development
|
47
|
-
version_requirements: *id003
|
48
|
-
- !ruby/object:Gem::Dependency
|
49
|
-
name: zucker
|
50
45
|
prerelease: false
|
51
|
-
|
46
|
+
version_requirements: *22009200
|
47
|
+
- !ruby/object:Gem::Dependency
|
48
|
+
name: zucker
|
49
|
+
requirement: &22008700 !ruby/object:Gem::Requirement
|
52
50
|
none: false
|
53
|
-
requirements:
|
54
|
-
- -
|
55
|
-
- !ruby/object:Gem::Version
|
56
|
-
version:
|
51
|
+
requirements:
|
52
|
+
- - ! '>='
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '11'
|
57
55
|
type: :development
|
58
|
-
version_requirements: *id004
|
59
|
-
- !ruby/object:Gem::Dependency
|
60
|
-
name: paint
|
61
56
|
prerelease: false
|
62
|
-
|
57
|
+
version_requirements: *22008700
|
58
|
+
- !ruby/object:Gem::Dependency
|
59
|
+
name: paint
|
60
|
+
requirement: &22008280 !ruby/object:Gem::Requirement
|
63
61
|
none: false
|
64
|
-
requirements:
|
65
|
-
- -
|
66
|
-
- !ruby/object:Gem::Version
|
67
|
-
version:
|
62
|
+
requirements:
|
63
|
+
- - ! '>='
|
64
|
+
- !ruby/object:Gem::Version
|
65
|
+
version: '0'
|
68
66
|
type: :development
|
69
|
-
|
70
|
-
|
67
|
+
prerelease: false
|
68
|
+
version_requirements: *22008280
|
69
|
+
description: ! 'Wavy IRB: Colorizes irb results. It originated from Wirble, but only
|
70
|
+
provides result highlighting. Just call Wirb.start and enjoy the colors in your
|
71
|
+
IRB ;). You can use it with your favorite colorizer engine. See README.rdoc for
|
72
|
+
more details.'
|
71
73
|
email: mail@janlelis.de
|
72
74
|
executables: []
|
73
|
-
|
74
75
|
extensions: []
|
75
|
-
|
76
|
-
extra_rdoc_files:
|
76
|
+
extra_rdoc_files:
|
77
77
|
- README.rdoc
|
78
78
|
- COPYING.txt
|
79
|
-
files:
|
79
|
+
files:
|
80
80
|
- lib/wirb.rb
|
81
|
-
- lib/wirb/
|
82
|
-
- lib/wirb/tokenizer.rb
|
83
|
-
- lib/wirb/wp.rb
|
84
|
-
- lib/wirb/colorizer/wirble.rb
|
85
|
-
- lib/wirb/colorizer/paint.rb
|
81
|
+
- lib/wirb/irb.rb
|
86
82
|
- lib/wirb/colorizer/wirb0.rb
|
87
|
-
- lib/wirb/colorizer/wirb0_highline.rb
|
88
83
|
- lib/wirb/colorizer/wirb0_paint.rb
|
84
|
+
- lib/wirb/colorizer/paint.rb
|
89
85
|
- lib/wirb/colorizer/highline.rb
|
86
|
+
- lib/wirb/colorizer/wirble.rb
|
87
|
+
- lib/wirb/colorizer/wirb0_highline.rb
|
88
|
+
- lib/wirb/tokenizer.rb
|
89
|
+
- lib/wirb/wp.rb
|
90
90
|
- lib/wirb/version.rb
|
91
|
-
- lib/wirb/
|
91
|
+
- lib/wirb/colorizer.rb
|
92
|
+
- spec/tokenizer_misc_spec.rb
|
93
|
+
- spec/tokenizer_number_spec.rb
|
94
|
+
- spec/colorizer_wirb0_spec.rb
|
95
|
+
- spec/tokenizer_set_spec.rb
|
96
|
+
- spec/tokenizer_object_spec.rb
|
92
97
|
- spec/tokenizer_rails_spec.rb
|
93
|
-
- spec/
|
94
|
-
- spec/
|
98
|
+
- spec/tokenizer_time_spec.rb
|
99
|
+
- spec/tokenizer_enumerator_spec.rb
|
95
100
|
- spec/colorizer_wirb0_paint_spec.rb
|
96
|
-
- spec/tokenizer_number_spec.rb
|
97
101
|
- spec/tokenizer_regexp_spec.rb
|
98
|
-
- spec/
|
99
|
-
- spec/
|
100
|
-
- spec/
|
102
|
+
- spec/tokenizer_rubygems_spec.rb
|
103
|
+
- spec/tokenizer_string_spec.rb
|
104
|
+
- spec/colorizer_paint_spec.rb
|
105
|
+
- spec/tokenizer_hash_spec.rb
|
101
106
|
- spec/spec_helper.rb
|
102
|
-
- spec/
|
103
|
-
- spec/tokenizer_nil_false_true_spec.rb
|
104
|
-
- spec/colorizer_highline_spec.rb
|
107
|
+
- spec/colorizer_spec.rb
|
105
108
|
- spec/tokenizer_symbol_spec.rb
|
106
|
-
- spec/
|
107
|
-
- spec/tokenizer_object_spec.rb
|
108
|
-
- spec/colorizer_wirb0_spec.rb
|
109
|
+
- spec/tokenizer_nil_false_true_spec.rb
|
109
110
|
- spec/tokenizer_nested_spec.rb
|
110
|
-
- spec/
|
111
|
-
- spec/
|
111
|
+
- spec/colorizer_highline_spec.rb
|
112
|
+
- spec/colorizer_wirble_spec.rb
|
112
113
|
- spec/tokenizer_rubyvm_spec.rb
|
113
|
-
- spec/
|
114
|
-
- spec/
|
115
|
-
- spec/tokenizer_rubygems_spec.rb
|
114
|
+
- spec/tokenizer_array_spec.rb
|
115
|
+
- spec/colorizer_wirb0_highline_spec.rb
|
116
116
|
- COPYING.txt
|
117
117
|
- README.rdoc
|
118
118
|
- CHANGELOG.rdoc
|
119
|
-
- data/wirb/
|
119
|
+
- data/wirb/colorless.yml
|
120
120
|
- data/wirb/classic_paint.yml
|
121
|
+
- data/wirb/classic_wirb0.yml
|
121
122
|
- Rakefile
|
122
123
|
- wirb.gemspec
|
123
124
|
- .gemtest
|
124
125
|
homepage: https://github.com/janlelis/wirb
|
125
|
-
licenses:
|
126
|
+
licenses:
|
126
127
|
- MIT
|
127
|
-
post_install_message: "
|
128
|
+
post_install_message: ! " ┌── info ──────────────────────────┐\n J-_-L │ https://github.com/janlelis/wirb
|
129
|
+
│\n ├── usage ─────────────────────────┤\n │ require 'wirb' │\n
|
130
|
+
\ │ Wirb.start │\n └──────────────────────────────────┘"
|
128
131
|
rdoc_options: []
|
129
|
-
|
130
|
-
require_paths:
|
132
|
+
require_paths:
|
131
133
|
- lib
|
132
|
-
required_ruby_version: !ruby/object:Gem::Requirement
|
134
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
133
135
|
none: false
|
134
|
-
requirements:
|
135
|
-
- -
|
136
|
-
- !ruby/object:Gem::Version
|
136
|
+
requirements:
|
137
|
+
- - ! '>='
|
138
|
+
- !ruby/object:Gem::Version
|
137
139
|
version: 1.8.7
|
138
|
-
required_rubygems_version: !ruby/object:Gem::Requirement
|
140
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
139
141
|
none: false
|
140
|
-
requirements:
|
141
|
-
- -
|
142
|
-
- !ruby/object:Gem::Version
|
142
|
+
requirements:
|
143
|
+
- - ! '>='
|
144
|
+
- !ruby/object:Gem::Version
|
143
145
|
version: 1.3.6
|
144
146
|
requirements: []
|
145
|
-
|
146
147
|
rubyforge_project:
|
147
|
-
rubygems_version: 1.8.
|
148
|
+
rubygems_version: 1.8.5
|
148
149
|
signing_key:
|
149
150
|
specification_version: 3
|
150
|
-
summary:
|
151
|
+
summary: ! 'Wavy IRB: Colorizes irb results.'
|
151
152
|
test_files: []
|
152
|
-
|