dbg-rb 0.2.4 → 0.2.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +7 -1
- data/lib/dbg-rb.rb +3 -0
- data/lib/dbg_rb/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b59e26796df37f516bbf9e49abf36ef3e6381251efb147a8cfebc2dc3b25e859
|
4
|
+
data.tar.gz: fb966c5473b1a5799fbb7c6d74823aa62821e054f8af7dfa4f6e05f39efe30fa
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d282afefaa8acb843fea7bd553ba3d31e323f58693ea14c96e8f14cc3c5fbf190f520d30b19521ac28636c8f02387f24dd8e15850c996a3d5a4dd7ba5ce69592
|
7
|
+
data.tar.gz: 815a02500042f53cb9d8e170efd5efef323d68a994258c7b3df59de62c371958b48019ba2a83c6a73b491a8b22b1669cf70058228fdc63ac382934bc41704349
|
data/README.md
CHANGED
@@ -65,7 +65,7 @@ You can color the output:
|
|
65
65
|
```ruby
|
66
66
|
require "dbg-rb"
|
67
67
|
|
68
|
-
DbgRb.color_code =
|
68
|
+
DbgRb.color_code = 33
|
69
69
|
# 31 red
|
70
70
|
# 32 green
|
71
71
|
# 33 yellow
|
@@ -74,6 +74,12 @@ DbgRb.color_code = 35
|
|
74
74
|
# 36 light blue
|
75
75
|
```
|
76
76
|
|
77
|
+
It's yellow by default. You can disable colors by running:
|
78
|
+
|
79
|
+
```ruby
|
80
|
+
DbgRb.color_code= nil
|
81
|
+
```
|
82
|
+
|
77
83
|
```ruby
|
78
84
|
user = User.last.as_json.slice("id", "slack_id")
|
79
85
|
dbg("User last", :user)
|
data/lib/dbg-rb.rb
CHANGED
@@ -1,6 +1,7 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
3
|
require "binding_of_caller"
|
4
|
+
require "json"
|
4
5
|
|
5
6
|
module DbgRb
|
6
7
|
def self.color_code=(val)
|
@@ -100,4 +101,6 @@ def dbg!(*msgs)
|
|
100
101
|
DbgRb.dbg!(*msgs)
|
101
102
|
end
|
102
103
|
|
104
|
+
DbgRb.color_code = 33 # yellow
|
105
|
+
|
103
106
|
alias dbg dbg!
|
data/lib/dbg_rb/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: dbg-rb
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- pawurb
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-12-
|
11
|
+
date: 2024-12-19 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: binding_of_caller
|