pry-bloodline 0.0.1 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 8b63c16b4138e7384bd64c9fac2bf62fd3f72131
4
- data.tar.gz: 1b73d4e016f2a2b588d5f37f84193680deea3394
3
+ metadata.gz: a66716907d849602ae09cad671fc5a77a5e05e69
4
+ data.tar.gz: b8cec5e68022ef53cbf98ff43354005bc52a22c8
5
5
  SHA512:
6
- metadata.gz: 1120823c840f790ad64a0d6248b38e574b177dc4eb899dd01f3a20f4747cc1d89cdea01aa9079e5ed91bcc9df671e38f75305166fdcd7a1b0a65741360b0adc1
7
- data.tar.gz: 6957354c67e03ffcf51dbd6c0e98bca61265c49cc260ac37276f35306173a6424b6687b09d5cd25ee63353da109be3564b7d71a3f2678fecfebf568d6bb9e1ed
6
+ metadata.gz: 78e89a29eaca3156f7bf545c8ae6a03e8eb69797b530a9ab4290906a9d0fd0648a587f8344b3cfcfe12c52d64ceb85f88df8cb5aa15db73979615613df56c801
7
+ data.tar.gz: a4dcf3cd2dcc9abae8dfcc760f0b8693c00bd856a8783a5f5d3a94a7b987cb8fb0925ab6c0e65e46a443e2466207bd739d94bb0ad877b5093ced9426630eadc8
data/README.md CHANGED
@@ -2,6 +2,58 @@
2
2
 
3
3
  A glorious descendant of a noble lineage of status lines, to be used with Pry.
4
4
 
5
+ It turns this:
6
+
7
+ ![Before](images/before.png)
8
+
9
+ Into this:
10
+
11
+ ![After](images/after.png)
12
+
13
+ ## Themes
14
+
15
+ It's really easy to build your own theme!
16
+
17
+ #### Freedom
18
+
19
+ ```ruby
20
+ PryBloodline.configure do |c|
21
+ c.line_color = :white
22
+ c.name_color = :blue
23
+ c.path_color = :red
24
+ c.separator = "★"
25
+ c.separator_color = :white
26
+ end
27
+ ```
28
+
29
+ ![Freedom](images/freedom.png)
30
+
31
+ #### Blood
32
+
33
+ ```ruby
34
+ PryBloodline.configure do |c|
35
+ c.line_color = :light_white
36
+ c.name_color = :light_red
37
+ c.path_color = :red
38
+ c.separator_color = :light_black
39
+ end
40
+ ```
41
+
42
+ ![Blood](images/blood.png)
43
+
44
+ ### Thor
45
+
46
+ ```ruby
47
+ PryBloodline.configure do |c|
48
+ c.line_color = :red
49
+ c.name_color = :white
50
+ c.path_color = :blue
51
+ c.separator = "⚡"
52
+ end
53
+ ```
54
+
55
+ ![Thor](images/thor.png)
56
+
5
57
  ## Installation
6
58
 
7
59
  Add this line to your application's Gemfile:
@@ -38,6 +90,31 @@ Then:
38
90
 
39
91
  $ pry
40
92
 
93
+ ## Configuration
94
+
95
+ Here are all the fields you can configure:
96
+
97
+ ```ruby
98
+ PryBloodline.configure do |c|
99
+ c.name = "pry"
100
+ c.line_color = :light_black
101
+ c.name_color = :green
102
+ c.path_color = :light_blue
103
+ c.separator = "\u00BB"
104
+ c.separator_color = :light_green
105
+ c.name_proc = proc { c.name.colorize(c.name_color) }
106
+ c.line_proc = proc { |obj, level, pry| "[#{pry.input_array.size}]".colorize(c.line_color) }
107
+ c.path_proc = proc { |obj, level, pry| "(#{Pry.view_clip(obj)})".colorize(c.path_color) }
108
+ c.separator_proc = proc { c.separator.colorize(c.separator_color }
109
+ end
110
+ ```
111
+
112
+ This configuration yields this theme:
113
+
114
+ ![Custom](images/custom.png)
115
+
116
+ Check the source code for more details on this ;)
117
+
41
118
  ## Contributing
42
119
 
43
120
  1. Fork it ( https://github.com/Arkham/pry-bloodline/fork )
@@ -33,11 +33,11 @@ module PryBloodline
33
33
 
34
34
  DEFAULTS = {
35
35
  name: "pry",
36
- line_color: :white,
37
- name_color: :blue,
38
- path_color: :white,
36
+ line_color: :light_black,
37
+ name_color: :green,
38
+ path_color: :light_blue,
39
39
  separator: "\u00BB",
40
- separator_color: :red,
40
+ separator_color: :light_green,
41
41
  name_proc: DEFAULT_NAME_PROC,
42
42
  line_proc: DEFAULT_LINE_PROC,
43
43
  path_proc: DEFAULT_PATH_PROC,
@@ -1,3 +1,3 @@
1
1
  module PryBloodline
2
- VERSION = "0.0.1"
2
+ VERSION = "0.0.2"
3
3
  end
@@ -13,7 +13,7 @@ Gem::Specification.new do |spec|
13
13
  spec.homepage = "https://github.com/Arkham/pry-bloodline"
14
14
  spec.license = "MIT"
15
15
 
16
- spec.files = `git ls-files -z`.split("\x0")
16
+ spec.files = `git ls-files -z`.split("\x0").reject { |f| f.start_with? "images" }
17
17
  spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
18
18
  spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
19
19
  spec.require_paths = ["lib"]
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pry-bloodline
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ju Liu
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-10-21 00:00:00.000000000 Z
11
+ date: 2014-10-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: pry