console-adapter-rails 0.5.1 → 0.6.0
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.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +3 -1
- data/lib/console/adapter/rails/logger.rb +20 -1
- data/lib/console/adapter/rails/railtie.rb +1 -1
- data/lib/console/adapter/rails/version.rb +1 -1
- data/lib/console/adapter/rails.rb +1 -1
- data/license.md +2 -1
- data/readme.md +20 -0
- data/releases.md +4 -0
- data.tar.gz.sig +0 -0
- metadata +6 -5
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: e3bfffd2e5daf13e1ee20290908faef062f5960d88021554cb06eb09f8b33561
|
|
4
|
+
data.tar.gz: b306352bde59591f90ecc8842ed3a369f53e54b6101f9513d672e33188969bd9
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 9963a3eb7663df27e551e90bbdb5869f1a3175845aca759b94576363487adceac22d1ca1ba3423a7e3bc5b11d9125f72e99aea6ea0bebc3f8e33fc0c7268f42d
|
|
7
|
+
data.tar.gz: 67f48ccc6da55ffa1a729a5f841c159de0e4f5ef21f56f87d2622457e33c6a908f757c57fbcd53b79ed2292874f815060149b57faa99abc5ab05eb623ec45467
|
checksums.yaml.gz.sig
CHANGED
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
# Released under the MIT License.
|
|
4
4
|
# Copyright, 2023-2025, by Samuel Williams.
|
|
5
5
|
# Copyright, 2024, by Michael Adams.
|
|
6
|
+
# Copyright, 2026, by Yasha Krasnou.
|
|
6
7
|
|
|
7
8
|
require "console/compatible/logger"
|
|
8
9
|
|
|
@@ -83,7 +84,25 @@ module Console
|
|
|
83
84
|
def add(severity, message = nil, progname = nil, &block)
|
|
84
85
|
return if silenced?(severity)
|
|
85
86
|
|
|
86
|
-
|
|
87
|
+
if formatter.respond_to?(:tag_stack)
|
|
88
|
+
tags = formatter.tag_stack.tags
|
|
89
|
+
|
|
90
|
+
options = tags.each_with_object({}) do |tag, memo|
|
|
91
|
+
next unless tag.respond_to?(:to_hash)
|
|
92
|
+
|
|
93
|
+
tag.to_hash.each do |key, value|
|
|
94
|
+
case key
|
|
95
|
+
when Symbol
|
|
96
|
+
memo[key] = value
|
|
97
|
+
else
|
|
98
|
+
next unless key.respond_to?(:to_sym)
|
|
99
|
+
memo[key.to_sym] = value
|
|
100
|
+
end
|
|
101
|
+
end
|
|
102
|
+
end
|
|
103
|
+
end
|
|
104
|
+
|
|
105
|
+
super(severity, message, progname, **options, &block)
|
|
87
106
|
end
|
|
88
107
|
|
|
89
108
|
# Configure Rails to use the Console logger.
|
data/license.md
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
# MIT License
|
|
2
2
|
|
|
3
|
-
Copyright, 2023-
|
|
3
|
+
Copyright, 2023-2026, by Samuel Williams.
|
|
4
4
|
Copyright, 2023, by Joshua Young.
|
|
5
5
|
Copyright, 2024, by Michael Adams.
|
|
6
6
|
Copyright, 2025, by Jun Jiang.
|
|
7
|
+
Copyright, 2026, by Yasha Krasnou.
|
|
7
8
|
|
|
8
9
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
9
10
|
of this software and associated documentation files (the "Software"), to deal
|
data/readme.md
CHANGED
|
@@ -14,6 +14,10 @@ Please see the [project documentation](https://socketry.github.io/console-adapte
|
|
|
14
14
|
|
|
15
15
|
Please see the [project releases](https://socketry.github.io/console-adapter-rails/releases/index) for all releases.
|
|
16
16
|
|
|
17
|
+
### v0.6.0
|
|
18
|
+
|
|
19
|
+
- Add support for Rails tagged logging in the Rails logger adapter. This allows log messages with tags to be properly formatted and displayed.
|
|
20
|
+
|
|
17
21
|
### v0.5.0
|
|
18
22
|
|
|
19
23
|
- Improved compatibilty with Rails 8+.
|
|
@@ -28,6 +32,22 @@ We welcome contributions to this project.
|
|
|
28
32
|
4. Push to the branch (`git push origin my-new-feature`).
|
|
29
33
|
5. Create new Pull Request.
|
|
30
34
|
|
|
35
|
+
### Running Tests
|
|
36
|
+
|
|
37
|
+
To run the test suite:
|
|
38
|
+
|
|
39
|
+
``` shell
|
|
40
|
+
bundle exec sus
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
### Making Releases
|
|
44
|
+
|
|
45
|
+
To make a new release:
|
|
46
|
+
|
|
47
|
+
``` shell
|
|
48
|
+
bundle exec bake gem:release:patch # or minor or major
|
|
49
|
+
```
|
|
50
|
+
|
|
31
51
|
### Developer Certificate of Origin
|
|
32
52
|
|
|
33
53
|
In order to protect users of this project, we require all contributors to comply with the [Developer Certificate of Origin](https://developercertificate.org/). This ensures that all contributions are properly licensed and attributed.
|
data/releases.md
CHANGED
data.tar.gz.sig
CHANGED
|
Binary file
|
metadata
CHANGED
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: console-adapter-rails
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.6.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Samuel Williams
|
|
8
8
|
- Joshua Young
|
|
9
9
|
- Jun Jiang
|
|
10
10
|
- Michael Adams
|
|
11
|
+
- Yasha Krasnou
|
|
11
12
|
bindir: bin
|
|
12
13
|
cert_chain:
|
|
13
14
|
- |
|
|
@@ -47,14 +48,14 @@ dependencies:
|
|
|
47
48
|
requirements:
|
|
48
49
|
- - "~>"
|
|
49
50
|
- !ruby/object:Gem::Version
|
|
50
|
-
version: '1.
|
|
51
|
+
version: '1.34'
|
|
51
52
|
type: :runtime
|
|
52
53
|
prerelease: false
|
|
53
54
|
version_requirements: !ruby/object:Gem::Requirement
|
|
54
55
|
requirements:
|
|
55
56
|
- - "~>"
|
|
56
57
|
- !ruby/object:Gem::Version
|
|
57
|
-
version: '1.
|
|
58
|
+
version: '1.34'
|
|
58
59
|
- !ruby/object:Gem::Dependency
|
|
59
60
|
name: fiber-storage
|
|
60
61
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -111,14 +112,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
111
112
|
requirements:
|
|
112
113
|
- - ">="
|
|
113
114
|
- !ruby/object:Gem::Version
|
|
114
|
-
version: '3.
|
|
115
|
+
version: '3.3'
|
|
115
116
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
116
117
|
requirements:
|
|
117
118
|
- - ">="
|
|
118
119
|
- !ruby/object:Gem::Version
|
|
119
120
|
version: '0'
|
|
120
121
|
requirements: []
|
|
121
|
-
rubygems_version:
|
|
122
|
+
rubygems_version: 4.0.6
|
|
122
123
|
specification_version: 4
|
|
123
124
|
summary: Adapt Rails logs and events to the console gem.
|
|
124
125
|
test_files: []
|
metadata.gz.sig
CHANGED
|
Binary file
|