berkeley_library-logging 0.2.6.2 → 0.3.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 48c51023acdd7645c3bb8b848866530073434912b93498b4b12a739dd117da52
4
- data.tar.gz: 40fc965452fba9f55877ef598eb594e510a67d1e8f77add187efe1b34f4395b5
3
+ metadata.gz: 3cac01e3581716921d2c705c2db91d3a670e33f6e3d1f4f056d7e926ddd9336e
4
+ data.tar.gz: cd4eb6ea51c7ff3312e49415ff16250206fe7a41d56bc00d65bacec12680303e
5
5
  SHA512:
6
- metadata.gz: f9ecb21c588ccc52ee496c6fd4eb1e9bd47a771147da4707814931b48e58b0a50b4f5d5ce9d7f5974bdaa4fc1ee82ad456e5ac42f4d73931a69cde6652e3a2da
7
- data.tar.gz: b4ffb91ebc7c1d4c98ca314f587ad66dfe92755556d345dd8b459412cf9ff657ed8f70e2c6ccd6060aed44167cc135911f90aeb9ab56e580c3388a6eba361928
6
+ metadata.gz: b4e5ebcf1db7e39917c3010f8c1a185d922c321c9d78de8c2679e19a6c64af4cd80be7ab9d3eef4c5125b62e7c3f150dc1d9c6ab27ced8786a00f59b3c28772b
7
+ data.tar.gz: 64d96ce9fa07080aa043db721e847931e5988af6e4d7d80dce4ab2206660aa2daaece8b46ed4e8d876f23c746f39f5b2456c9c6e9825a767208ff7e07b2d3e5f
@@ -1,18 +1,30 @@
1
1
  name: Build
2
- on: [ push, pull_request ]
2
+ on: [ push, pull_request, workflow_dispatch ]
3
3
  jobs:
4
4
  test:
5
5
  strategy:
6
6
  fail-fast: false
7
7
  matrix:
8
8
  os: [ ubuntu-latest, macos-latest ]
9
- ruby: [ '2.7', '3.0' ]
9
+ ruby: [ '3.3', '3.4' ]
10
10
  runs-on: ${{ matrix.os }}
11
11
 
12
12
  steps:
13
- - uses: actions/checkout@v2
14
- - uses: ruby/setup-ruby@v1
13
+ - name: Check out repository
14
+ uses: actions/checkout@v3
15
+
16
+ - name: Set up Ruby
17
+ uses: ruby/setup-ruby@v1
15
18
  with:
16
19
  ruby-version: ${{ matrix.ruby }}
17
20
  bundler-cache: true # runs 'bundle install' and caches installed gems automatically
18
- - run: bundle exec rake
21
+
22
+ - name: Run checks
23
+ run: bundle exec rake
24
+
25
+ - name: Upload artifacts
26
+ if: ${{ always() }}
27
+ uses: actions/upload-artifact@v4
28
+ with:
29
+ name: artifacts-${{ matrix.ruby }}-${{ matrix.os }}
30
+ path: artifacts/**
@@ -0,0 +1,33 @@
1
+ name: Ruby Gem
2
+
3
+ on:
4
+ release:
5
+ types: [published]
6
+
7
+ jobs:
8
+ build:
9
+ name: Build + Publish
10
+ runs-on: ubuntu-latest
11
+ permissions:
12
+ contents: read
13
+ packages: write
14
+
15
+ steps:
16
+ - uses: actions/checkout@v3
17
+
18
+ - name: Set up Ruby
19
+ uses: ruby/setup-ruby@v1
20
+ with:
21
+ ruby-version: '3.3'
22
+ bundler-cache: true
23
+
24
+ - name: Publish to RubyGems
25
+ run: |
26
+ mkdir -p $HOME/.gem
27
+ touch $HOME/.gem/credentials
28
+ chmod 0600 $HOME/.gem/credentials
29
+ printf -- "---\n:rubygems_api_key: ${GEM_HOST_API_KEY}\n" > $HOME/.gem/credentials
30
+ gem build *.gemspec
31
+ gem push *.gem
32
+ env:
33
+ GEM_HOST_API_KEY: "${{secrets.RUBYGEMS_AUTH_TOKEN}}"
data/.idea/logging.iml CHANGED
@@ -5,99 +5,99 @@
5
5
  </component>
6
6
  <component name="NewModuleRootManager">
7
7
  <content url="file://$MODULE_DIR$" />
8
- <orderEntry type="jdk" jdkName="RVM: ruby-2.7.5" jdkType="RUBY_SDK" />
8
+ <orderEntry type="jdk" jdkName="RVM: ruby-2.7.6" jdkType="RUBY_SDK" />
9
9
  <orderEntry type="sourceFolder" forTests="false" />
10
- <orderEntry type="library" scope="PROVIDED" name="actioncable (v7.0.3, RVM: ruby-2.7.5) [gem]" level="application" />
11
- <orderEntry type="library" scope="PROVIDED" name="actionmailbox (v7.0.3, RVM: ruby-2.7.5) [gem]" level="application" />
12
- <orderEntry type="library" scope="PROVIDED" name="actionmailer (v7.0.3, RVM: ruby-2.7.5) [gem]" level="application" />
13
- <orderEntry type="library" scope="PROVIDED" name="actionpack (v7.0.3, RVM: ruby-2.7.5) [gem]" level="application" />
14
- <orderEntry type="library" scope="PROVIDED" name="actiontext (v7.0.3, RVM: ruby-2.7.5) [gem]" level="application" />
15
- <orderEntry type="library" scope="PROVIDED" name="actionview (v7.0.3, RVM: ruby-2.7.5) [gem]" level="application" />
16
- <orderEntry type="library" scope="PROVIDED" name="activejob (v7.0.3, RVM: ruby-2.7.5) [gem]" level="application" />
17
- <orderEntry type="library" scope="PROVIDED" name="activemodel (v7.0.3, RVM: ruby-2.7.5) [gem]" level="application" />
18
- <orderEntry type="library" scope="PROVIDED" name="activerecord (v7.0.3, RVM: ruby-2.7.5) [gem]" level="application" />
19
- <orderEntry type="library" scope="PROVIDED" name="activestorage (v7.0.3, RVM: ruby-2.7.5) [gem]" level="application" />
20
- <orderEntry type="library" scope="PROVIDED" name="activesupport (v7.0.3, RVM: ruby-2.7.5) [gem]" level="application" />
21
- <orderEntry type="library" scope="PROVIDED" name="amazing_print (v1.4.0, RVM: ruby-2.7.5) [gem]" level="application" />
22
- <orderEntry type="library" scope="PROVIDED" name="ansi (v1.5.0, RVM: ruby-2.7.5) [gem]" level="application" />
23
- <orderEntry type="library" scope="PROVIDED" name="ast (v2.4.2, RVM: ruby-2.7.5) [gem]" level="application" />
24
- <orderEntry type="library" scope="PROVIDED" name="brakeman (v4.10.1, RVM: ruby-2.7.5) [gem]" level="application" />
25
- <orderEntry type="library" scope="PROVIDED" name="builder (v3.2.4, RVM: ruby-2.7.5) [gem]" level="application" />
26
- <orderEntry type="library" scope="PROVIDED" name="bundle-audit (v0.1.0, RVM: ruby-2.7.5) [gem]" level="application" />
27
- <orderEntry type="library" scope="PROVIDED" name="bundler (v2.2.31, RVM: ruby-2.7.5) [gem]" level="application" />
28
- <orderEntry type="library" scope="PROVIDED" name="bundler-audit (v0.9.0.1, RVM: ruby-2.7.5) [gem]" level="application" />
29
- <orderEntry type="library" scope="PROVIDED" name="ci_reporter (v2.0.0, RVM: ruby-2.7.5) [gem]" level="application" />
30
- <orderEntry type="library" scope="PROVIDED" name="ci_reporter_rspec (v1.0.0, RVM: ruby-2.7.5) [gem]" level="application" />
31
- <orderEntry type="library" scope="PROVIDED" name="colorize (v0.8.1, RVM: ruby-2.7.5) [gem]" level="application" />
32
- <orderEntry type="library" scope="PROVIDED" name="concurrent-ruby (v1.1.10, RVM: ruby-2.7.5) [gem]" level="application" />
33
- <orderEntry type="library" scope="PROVIDED" name="crass (v1.0.6, RVM: ruby-2.7.5) [gem]" level="application" />
34
- <orderEntry type="library" scope="PROVIDED" name="diff-lcs (v1.5.0, RVM: ruby-2.7.5) [gem]" level="application" />
35
- <orderEntry type="library" scope="PROVIDED" name="digest (v3.1.0, RVM: ruby-2.7.5) [gem]" level="application" />
36
- <orderEntry type="library" scope="PROVIDED" name="docile (v1.4.0, RVM: ruby-2.7.5) [gem]" level="application" />
37
- <orderEntry type="library" scope="PROVIDED" name="dotenv (v2.7.6, RVM: ruby-2.7.5) [gem]" level="application" />
38
- <orderEntry type="library" scope="PROVIDED" name="erubi (v1.10.0, RVM: ruby-2.7.5) [gem]" level="application" />
39
- <orderEntry type="library" scope="PROVIDED" name="ffi (v1.15.5, RVM: ruby-2.7.5) [gem]" level="application" />
40
- <orderEntry type="library" scope="PROVIDED" name="globalid (v1.0.0, RVM: ruby-2.7.5) [gem]" level="application" />
41
- <orderEntry type="library" scope="PROVIDED" name="i18n (v1.10.0, RVM: ruby-2.7.5) [gem]" level="application" />
42
- <orderEntry type="library" scope="PROVIDED" name="io-console (v0.5.11, RVM: ruby-2.7.5) [gem]" level="application" />
43
- <orderEntry type="library" scope="PROVIDED" name="irb (v1.4.1, RVM: ruby-2.7.5) [gem]" level="application" />
44
- <orderEntry type="library" scope="PROVIDED" name="listen (v3.1.5, RVM: ruby-2.7.5) [gem]" level="application" />
45
- <orderEntry type="library" scope="PROVIDED" name="lograge (v0.12.0, RVM: ruby-2.7.5) [gem]" level="application" />
46
- <orderEntry type="library" scope="PROVIDED" name="loofah (v2.18.0, RVM: ruby-2.7.5) [gem]" level="application" />
47
- <orderEntry type="library" scope="PROVIDED" name="mail (v2.7.1, RVM: ruby-2.7.5) [gem]" level="application" />
48
- <orderEntry type="library" scope="PROVIDED" name="marcel (v1.0.2, RVM: ruby-2.7.5) [gem]" level="application" />
49
- <orderEntry type="library" scope="PROVIDED" name="method_source (v1.0.0, RVM: ruby-2.7.5) [gem]" level="application" />
50
- <orderEntry type="library" scope="PROVIDED" name="mini_mime (v1.1.2, RVM: ruby-2.7.5) [gem]" level="application" />
51
- <orderEntry type="library" scope="PROVIDED" name="minitest (v5.15.0, RVM: ruby-2.7.5) [gem]" level="application" />
52
- <orderEntry type="library" scope="PROVIDED" name="net-imap (v0.2.3, RVM: ruby-2.7.5) [gem]" level="application" />
53
- <orderEntry type="library" scope="PROVIDED" name="net-pop (v0.1.1, RVM: ruby-2.7.5) [gem]" level="application" />
54
- <orderEntry type="library" scope="PROVIDED" name="net-protocol (v0.1.3, RVM: ruby-2.7.5) [gem]" level="application" />
55
- <orderEntry type="library" scope="PROVIDED" name="net-smtp (v0.3.1, RVM: ruby-2.7.5) [gem]" level="application" />
56
- <orderEntry type="library" scope="PROVIDED" name="nio4r (v2.5.8, RVM: ruby-2.7.5) [gem]" level="application" />
57
- <orderEntry type="library" scope="PROVIDED" name="nokogiri (v1.13.6, RVM: ruby-2.7.5) [gem]" level="application" />
58
- <orderEntry type="library" scope="PROVIDED" name="oj (v3.13.11, RVM: ruby-2.7.5) [gem]" level="application" />
59
- <orderEntry type="library" scope="PROVIDED" name="ougai (v1.9.1, RVM: ruby-2.7.5) [gem]" level="application" />
60
- <orderEntry type="library" scope="PROVIDED" name="parallel (v1.22.1, RVM: ruby-2.7.5) [gem]" level="application" />
61
- <orderEntry type="library" scope="PROVIDED" name="parser (v3.1.2.0, RVM: ruby-2.7.5) [gem]" level="application" />
62
- <orderEntry type="library" scope="PROVIDED" name="racc (v1.6.0, RVM: ruby-2.7.5) [gem]" level="application" />
63
- <orderEntry type="library" scope="PROVIDED" name="rack (v2.2.3, RVM: ruby-2.7.5) [gem]" level="application" />
64
- <orderEntry type="library" scope="PROVIDED" name="rack-test (v1.1.0, RVM: ruby-2.7.5) [gem]" level="application" />
65
- <orderEntry type="library" scope="PROVIDED" name="rails (v7.0.3, RVM: ruby-2.7.5) [gem]" level="application" />
66
- <orderEntry type="library" scope="PROVIDED" name="rails-dom-testing (v2.0.3, RVM: ruby-2.7.5) [gem]" level="application" />
67
- <orderEntry type="library" scope="PROVIDED" name="rails-html-sanitizer (v1.4.2, RVM: ruby-2.7.5) [gem]" level="application" />
68
- <orderEntry type="library" scope="PROVIDED" name="railties (v7.0.3, RVM: ruby-2.7.5) [gem]" level="application" />
69
- <orderEntry type="library" scope="PROVIDED" name="rainbow (v3.1.1, RVM: ruby-2.7.5) [gem]" level="application" />
70
- <orderEntry type="library" scope="PROVIDED" name="rake (v13.0.6, RVM: ruby-2.7.5) [gem]" level="application" />
71
- <orderEntry type="library" scope="PROVIDED" name="rb-fsevent (v0.11.1, RVM: ruby-2.7.5) [gem]" level="application" />
72
- <orderEntry type="library" scope="PROVIDED" name="rb-inotify (v0.10.1, RVM: ruby-2.7.5) [gem]" level="application" />
73
- <orderEntry type="library" scope="PROVIDED" name="regexp_parser (v2.4.0, RVM: ruby-2.7.5) [gem]" level="application" />
74
- <orderEntry type="library" scope="PROVIDED" name="reline (v0.3.1, RVM: ruby-2.7.5) [gem]" level="application" />
75
- <orderEntry type="library" scope="PROVIDED" name="request_store (v1.5.1, RVM: ruby-2.7.5) [gem]" level="application" />
76
- <orderEntry type="library" scope="PROVIDED" name="rexml (v3.2.5, RVM: ruby-2.7.5) [gem]" level="application" />
77
- <orderEntry type="library" scope="PROVIDED" name="rspec (v3.11.0, RVM: ruby-2.7.5) [gem]" level="application" />
78
- <orderEntry type="library" scope="PROVIDED" name="rspec-core (v3.11.0, RVM: ruby-2.7.5) [gem]" level="application" />
79
- <orderEntry type="library" scope="PROVIDED" name="rspec-expectations (v3.11.0, RVM: ruby-2.7.5) [gem]" level="application" />
80
- <orderEntry type="library" scope="PROVIDED" name="rspec-mocks (v3.11.1, RVM: ruby-2.7.5) [gem]" level="application" />
81
- <orderEntry type="library" scope="PROVIDED" name="rspec-support (v3.11.0, RVM: ruby-2.7.5) [gem]" level="application" />
82
- <orderEntry type="library" scope="PROVIDED" name="rubocop (v1.26.1, RVM: ruby-2.7.5) [gem]" level="application" />
83
- <orderEntry type="library" scope="PROVIDED" name="rubocop-ast (v1.17.0, RVM: ruby-2.7.5) [gem]" level="application" />
84
- <orderEntry type="library" scope="PROVIDED" name="rubocop-rspec (v2.4.0, RVM: ruby-2.7.5) [gem]" level="application" />
85
- <orderEntry type="library" scope="PROVIDED" name="ruby-progressbar (v1.11.0, RVM: ruby-2.7.5) [gem]" level="application" />
86
- <orderEntry type="library" scope="PROVIDED" name="ruby_dep (v1.5.0, RVM: ruby-2.7.5) [gem]" level="application" />
87
- <orderEntry type="library" scope="PROVIDED" name="simplecov (v0.21.2, RVM: ruby-2.7.5) [gem]" level="application" />
88
- <orderEntry type="library" scope="PROVIDED" name="simplecov-console (v0.9.1, RVM: ruby-2.7.5) [gem]" level="application" />
89
- <orderEntry type="library" scope="PROVIDED" name="simplecov-html (v0.12.3, RVM: ruby-2.7.5) [gem]" level="application" />
90
- <orderEntry type="library" scope="PROVIDED" name="simplecov-rcov (v0.3.1, RVM: ruby-2.7.5) [gem]" level="application" />
91
- <orderEntry type="library" scope="PROVIDED" name="simplecov_json_formatter (v0.1.4, RVM: ruby-2.7.5) [gem]" level="application" />
92
- <orderEntry type="library" scope="PROVIDED" name="strscan (v3.0.3, RVM: ruby-2.7.5) [gem]" level="application" />
93
- <orderEntry type="library" scope="PROVIDED" name="terminal-table (v3.0.2, RVM: ruby-2.7.5) [gem]" level="application" />
94
- <orderEntry type="library" scope="PROVIDED" name="thor (v1.2.1, RVM: ruby-2.7.5) [gem]" level="application" />
95
- <orderEntry type="library" scope="PROVIDED" name="timeout (v0.2.0, RVM: ruby-2.7.5) [gem]" level="application" />
96
- <orderEntry type="library" scope="PROVIDED" name="tzinfo (v2.0.4, RVM: ruby-2.7.5) [gem]" level="application" />
97
- <orderEntry type="library" scope="PROVIDED" name="unicode-display_width (v2.1.0, RVM: ruby-2.7.5) [gem]" level="application" />
98
- <orderEntry type="library" scope="PROVIDED" name="websocket-driver (v0.7.5, RVM: ruby-2.7.5) [gem]" level="application" />
99
- <orderEntry type="library" scope="PROVIDED" name="websocket-extensions (v0.1.5, RVM: ruby-2.7.5) [gem]" level="application" />
100
- <orderEntry type="library" scope="PROVIDED" name="zeitwerk (v2.5.4, RVM: ruby-2.7.5) [gem]" level="application" />
10
+ <orderEntry type="library" scope="PROVIDED" name="actioncable (v7.0.3, RVM: ruby-2.7.6) [gem]" level="application" />
11
+ <orderEntry type="library" scope="PROVIDED" name="actionmailbox (v7.0.3, RVM: ruby-2.7.6) [gem]" level="application" />
12
+ <orderEntry type="library" scope="PROVIDED" name="actionmailer (v7.0.3, RVM: ruby-2.7.6) [gem]" level="application" />
13
+ <orderEntry type="library" scope="PROVIDED" name="actionpack (v7.0.3, RVM: ruby-2.7.6) [gem]" level="application" />
14
+ <orderEntry type="library" scope="PROVIDED" name="actiontext (v7.0.3, RVM: ruby-2.7.6) [gem]" level="application" />
15
+ <orderEntry type="library" scope="PROVIDED" name="actionview (v7.0.3, RVM: ruby-2.7.6) [gem]" level="application" />
16
+ <orderEntry type="library" scope="PROVIDED" name="activejob (v7.0.3, RVM: ruby-2.7.6) [gem]" level="application" />
17
+ <orderEntry type="library" scope="PROVIDED" name="activemodel (v7.0.3, RVM: ruby-2.7.6) [gem]" level="application" />
18
+ <orderEntry type="library" scope="PROVIDED" name="activerecord (v7.0.3, RVM: ruby-2.7.6) [gem]" level="application" />
19
+ <orderEntry type="library" scope="PROVIDED" name="activestorage (v7.0.3, RVM: ruby-2.7.6) [gem]" level="application" />
20
+ <orderEntry type="library" scope="PROVIDED" name="activesupport (v7.0.3, RVM: ruby-2.7.6) [gem]" level="application" />
21
+ <orderEntry type="library" scope="PROVIDED" name="amazing_print (v1.4.0, RVM: ruby-2.7.6) [gem]" level="application" />
22
+ <orderEntry type="library" scope="PROVIDED" name="ansi (v1.5.0, RVM: ruby-2.7.6) [gem]" level="application" />
23
+ <orderEntry type="library" scope="PROVIDED" name="ast (v2.4.2, RVM: ruby-2.7.6) [gem]" level="application" />
24
+ <orderEntry type="library" scope="PROVIDED" name="brakeman (v4.10.1, RVM: ruby-2.7.6) [gem]" level="application" />
25
+ <orderEntry type="library" scope="PROVIDED" name="builder (v3.2.4, RVM: ruby-2.7.6) [gem]" level="application" />
26
+ <orderEntry type="library" scope="PROVIDED" name="bundle-audit (v0.1.0, RVM: ruby-2.7.6) [gem]" level="application" />
27
+ <orderEntry type="library" scope="PROVIDED" name="bundler (v2.2.31, RVM: ruby-2.7.6) [gem]" level="application" />
28
+ <orderEntry type="library" scope="PROVIDED" name="bundler-audit (v0.9.0.1, RVM: ruby-2.7.6) [gem]" level="application" />
29
+ <orderEntry type="library" scope="PROVIDED" name="ci_reporter (v2.0.0, RVM: ruby-2.7.6) [gem]" level="application" />
30
+ <orderEntry type="library" scope="PROVIDED" name="ci_reporter_rspec (v1.0.0, RVM: ruby-2.7.6) [gem]" level="application" />
31
+ <orderEntry type="library" scope="PROVIDED" name="colorize (v0.8.1, RVM: ruby-2.7.6) [gem]" level="application" />
32
+ <orderEntry type="library" scope="PROVIDED" name="concurrent-ruby (v1.1.10, RVM: ruby-2.7.6) [gem]" level="application" />
33
+ <orderEntry type="library" scope="PROVIDED" name="crass (v1.0.6, RVM: ruby-2.7.6) [gem]" level="application" />
34
+ <orderEntry type="library" scope="PROVIDED" name="diff-lcs (v1.5.0, RVM: ruby-2.7.6) [gem]" level="application" />
35
+ <orderEntry type="library" scope="PROVIDED" name="digest (v3.1.0, RVM: ruby-2.7.6) [gem]" level="application" />
36
+ <orderEntry type="library" scope="PROVIDED" name="docile (v1.4.0, RVM: ruby-2.7.6) [gem]" level="application" />
37
+ <orderEntry type="library" scope="PROVIDED" name="dotenv (v2.7.6, RVM: ruby-2.7.6) [gem]" level="application" />
38
+ <orderEntry type="library" scope="PROVIDED" name="erubi (v1.10.0, RVM: ruby-2.7.6) [gem]" level="application" />
39
+ <orderEntry type="library" scope="PROVIDED" name="ffi (v1.15.5, RVM: ruby-2.7.6) [gem]" level="application" />
40
+ <orderEntry type="library" scope="PROVIDED" name="globalid (v1.0.0, RVM: ruby-2.7.6) [gem]" level="application" />
41
+ <orderEntry type="library" scope="PROVIDED" name="i18n (v1.10.0, RVM: ruby-2.7.6) [gem]" level="application" />
42
+ <orderEntry type="library" scope="PROVIDED" name="io-console (v0.5.11, RVM: ruby-2.7.6) [gem]" level="application" />
43
+ <orderEntry type="library" scope="PROVIDED" name="irb (v1.4.1, RVM: ruby-2.7.6) [gem]" level="application" />
44
+ <orderEntry type="library" scope="PROVIDED" name="listen (v3.1.5, RVM: ruby-2.7.6) [gem]" level="application" />
45
+ <orderEntry type="library" scope="PROVIDED" name="lograge (v0.12.0, RVM: ruby-2.7.6) [gem]" level="application" />
46
+ <orderEntry type="library" scope="PROVIDED" name="loofah (v2.18.0, RVM: ruby-2.7.6) [gem]" level="application" />
47
+ <orderEntry type="library" scope="PROVIDED" name="mail (v2.7.1, RVM: ruby-2.7.6) [gem]" level="application" />
48
+ <orderEntry type="library" scope="PROVIDED" name="marcel (v1.0.2, RVM: ruby-2.7.6) [gem]" level="application" />
49
+ <orderEntry type="library" scope="PROVIDED" name="method_source (v1.0.0, RVM: ruby-2.7.6) [gem]" level="application" />
50
+ <orderEntry type="library" scope="PROVIDED" name="mini_mime (v1.1.2, RVM: ruby-2.7.6) [gem]" level="application" />
51
+ <orderEntry type="library" scope="PROVIDED" name="minitest (v5.15.0, RVM: ruby-2.7.6) [gem]" level="application" />
52
+ <orderEntry type="library" scope="PROVIDED" name="net-imap (v0.2.3, RVM: ruby-2.7.6) [gem]" level="application" />
53
+ <orderEntry type="library" scope="PROVIDED" name="net-pop (v0.1.1, RVM: ruby-2.7.6) [gem]" level="application" />
54
+ <orderEntry type="library" scope="PROVIDED" name="net-protocol (v0.1.3, RVM: ruby-2.7.6) [gem]" level="application" />
55
+ <orderEntry type="library" scope="PROVIDED" name="net-smtp (v0.3.1, RVM: ruby-2.7.6) [gem]" level="application" />
56
+ <orderEntry type="library" scope="PROVIDED" name="nio4r (v2.5.8, RVM: ruby-2.7.6) [gem]" level="application" />
57
+ <orderEntry type="library" scope="PROVIDED" name="nokogiri (v1.13.6, RVM: ruby-2.7.6) [gem]" level="application" />
58
+ <orderEntry type="library" scope="PROVIDED" name="oj (v3.13.11, RVM: ruby-2.7.6) [gem]" level="application" />
59
+ <orderEntry type="library" scope="PROVIDED" name="ougai (v1.9.1, RVM: ruby-2.7.6) [gem]" level="application" />
60
+ <orderEntry type="library" scope="PROVIDED" name="parallel (v1.22.1, RVM: ruby-2.7.6) [gem]" level="application" />
61
+ <orderEntry type="library" scope="PROVIDED" name="parser (v3.1.2.0, RVM: ruby-2.7.6) [gem]" level="application" />
62
+ <orderEntry type="library" scope="PROVIDED" name="racc (v1.6.0, RVM: ruby-2.7.6) [gem]" level="application" />
63
+ <orderEntry type="library" scope="PROVIDED" name="rack (v2.2.3, RVM: ruby-2.7.6) [gem]" level="application" />
64
+ <orderEntry type="library" scope="PROVIDED" name="rack-test (v1.1.0, RVM: ruby-2.7.6) [gem]" level="application" />
65
+ <orderEntry type="library" scope="PROVIDED" name="rails (v7.0.3, RVM: ruby-2.7.6) [gem]" level="application" />
66
+ <orderEntry type="library" scope="PROVIDED" name="rails-dom-testing (v2.0.3, RVM: ruby-2.7.6) [gem]" level="application" />
67
+ <orderEntry type="library" scope="PROVIDED" name="rails-html-sanitizer (v1.4.2, RVM: ruby-2.7.6) [gem]" level="application" />
68
+ <orderEntry type="library" scope="PROVIDED" name="railties (v7.0.3, RVM: ruby-2.7.6) [gem]" level="application" />
69
+ <orderEntry type="library" scope="PROVIDED" name="rainbow (v3.1.1, RVM: ruby-2.7.6) [gem]" level="application" />
70
+ <orderEntry type="library" scope="PROVIDED" name="rake (v13.0.6, RVM: ruby-2.7.6) [gem]" level="application" />
71
+ <orderEntry type="library" scope="PROVIDED" name="rb-fsevent (v0.11.1, RVM: ruby-2.7.6) [gem]" level="application" />
72
+ <orderEntry type="library" scope="PROVIDED" name="rb-inotify (v0.10.1, RVM: ruby-2.7.6) [gem]" level="application" />
73
+ <orderEntry type="library" scope="PROVIDED" name="regexp_parser (v2.4.0, RVM: ruby-2.7.6) [gem]" level="application" />
74
+ <orderEntry type="library" scope="PROVIDED" name="reline (v0.3.1, RVM: ruby-2.7.6) [gem]" level="application" />
75
+ <orderEntry type="library" scope="PROVIDED" name="request_store (v1.5.1, RVM: ruby-2.7.6) [gem]" level="application" />
76
+ <orderEntry type="library" scope="PROVIDED" name="rexml (v3.2.5, RVM: ruby-2.7.6) [gem]" level="application" />
77
+ <orderEntry type="library" scope="PROVIDED" name="rspec (v3.11.0, RVM: ruby-2.7.6) [gem]" level="application" />
78
+ <orderEntry type="library" scope="PROVIDED" name="rspec-core (v3.11.0, RVM: ruby-2.7.6) [gem]" level="application" />
79
+ <orderEntry type="library" scope="PROVIDED" name="rspec-expectations (v3.11.0, RVM: ruby-2.7.6) [gem]" level="application" />
80
+ <orderEntry type="library" scope="PROVIDED" name="rspec-mocks (v3.11.1, RVM: ruby-2.7.6) [gem]" level="application" />
81
+ <orderEntry type="library" scope="PROVIDED" name="rspec-support (v3.11.0, RVM: ruby-2.7.6) [gem]" level="application" />
82
+ <orderEntry type="library" scope="PROVIDED" name="rubocop (v1.26.1, RVM: ruby-2.7.6) [gem]" level="application" />
83
+ <orderEntry type="library" scope="PROVIDED" name="rubocop-ast (v1.17.0, RVM: ruby-2.7.6) [gem]" level="application" />
84
+ <orderEntry type="library" scope="PROVIDED" name="rubocop-rspec (v2.4.0, RVM: ruby-2.7.6) [gem]" level="application" />
85
+ <orderEntry type="library" scope="PROVIDED" name="ruby-progressbar (v1.11.0, RVM: ruby-2.7.6) [gem]" level="application" />
86
+ <orderEntry type="library" scope="PROVIDED" name="ruby_dep (v1.5.0, RVM: ruby-2.7.6) [gem]" level="application" />
87
+ <orderEntry type="library" scope="PROVIDED" name="simplecov (v0.21.2, RVM: ruby-2.7.6) [gem]" level="application" />
88
+ <orderEntry type="library" scope="PROVIDED" name="simplecov-console (v0.9.1, RVM: ruby-2.7.6) [gem]" level="application" />
89
+ <orderEntry type="library" scope="PROVIDED" name="simplecov-html (v0.12.3, RVM: ruby-2.7.6) [gem]" level="application" />
90
+ <orderEntry type="library" scope="PROVIDED" name="simplecov-rcov (v0.3.1, RVM: ruby-2.7.6) [gem]" level="application" />
91
+ <orderEntry type="library" scope="PROVIDED" name="simplecov_json_formatter (v0.1.4, RVM: ruby-2.7.6) [gem]" level="application" />
92
+ <orderEntry type="library" scope="PROVIDED" name="strscan (v3.0.3, RVM: ruby-2.7.6) [gem]" level="application" />
93
+ <orderEntry type="library" scope="PROVIDED" name="terminal-table (v3.0.2, RVM: ruby-2.7.6) [gem]" level="application" />
94
+ <orderEntry type="library" scope="PROVIDED" name="thor (v1.2.1, RVM: ruby-2.7.6) [gem]" level="application" />
95
+ <orderEntry type="library" scope="PROVIDED" name="timeout (v0.2.0, RVM: ruby-2.7.6) [gem]" level="application" />
96
+ <orderEntry type="library" scope="PROVIDED" name="tzinfo (v2.0.4, RVM: ruby-2.7.6) [gem]" level="application" />
97
+ <orderEntry type="library" scope="PROVIDED" name="unicode-display_width (v2.1.0, RVM: ruby-2.7.6) [gem]" level="application" />
98
+ <orderEntry type="library" scope="PROVIDED" name="websocket-driver (v0.7.5, RVM: ruby-2.7.6) [gem]" level="application" />
99
+ <orderEntry type="library" scope="PROVIDED" name="websocket-extensions (v0.1.5, RVM: ruby-2.7.6) [gem]" level="application" />
100
+ <orderEntry type="library" scope="PROVIDED" name="zeitwerk (v2.5.4, RVM: ruby-2.7.6) [gem]" level="application" />
101
101
  </component>
102
102
  <component name="RModuleSettingsStorage">
103
103
  <LOAD_PATH number="2" string0="$MODULE_DIR$/lib" string1="$MODULE_DIR$/spec" />
@@ -116,7 +116,7 @@
116
116
  <RakeTaskImpl description="Remove artifacts directory, except for .keep file" fullCommand="clean" id="clean" />
117
117
  <RakeTaskImpl description="Run all specs in spec directory, with coverage" fullCommand="coverage" id="coverage" />
118
118
  <RakeTaskImpl description="Clean, check, build gem" fullCommand="default" id="default" />
119
- <RakeTaskImpl description="Build berkeley_library-logging.gemspec as berkeley_library-logging-0.2.6.1.gem" fullCommand="gem" id="gem" />
119
+ <RakeTaskImpl description="Build berkeley_library-logging.gemspec as berkeley_library-logging-0.2.7.gem" fullCommand="gem" id="gem" />
120
120
  <RakeTaskImpl description="Run RuboCop" fullCommand="rubocop" id="rubocop" />
121
121
  <RakeTaskImpl id="rubocop">
122
122
  <subtasks>
data/.rubocop.yml CHANGED
@@ -6,6 +6,8 @@ AllCops:
6
6
  - 'out/**/*'
7
7
  # Exclude vendor files in GitHub build
8
8
  - 'vendor/**/*'
9
+ SuggestExtensions:
10
+ rubocop-rails: false
9
11
 
10
12
  # Allow one line around block body (Layout/EmptyLines will still disallow two or more)
11
13
  Layout/EmptyLinesAroundBlockBody:
@@ -181,7 +183,7 @@ Lint/TripleQuotes: # (new in 1.9)
181
183
  Enabled: true
182
184
  Style/IfWithBooleanLiteralBranches: # (new in 1.9)
183
185
  Enabled: true
184
- Gemspec/DateAssignment: # (new in 1.10)
186
+ Gemspec/DeprecatedAttributeAssignment: # (new in 1.10)
185
187
  Enabled: true
186
188
  Style/HashConversion: # (new in 1.10)
187
189
  Enabled: true
@@ -234,3 +236,177 @@ Style/MapToHash: # new in 1.24
234
236
  Style/NestedFileDirname: # new in 1.26
235
237
  Enabled: true
236
238
 
239
+ Gemspec/AddRuntimeDependency: # new in 1.65
240
+ Enabled: true
241
+ Gemspec/AttributeAssignment: # new in 1.77
242
+ Enabled: true
243
+ Gemspec/DevelopmentDependencies: # new in 1.44
244
+ Enabled: false
245
+ Layout/LineContinuationLeadingSpace: # new in 1.31
246
+ Enabled: true
247
+ Layout/LineContinuationSpacing: # new in 1.31
248
+ Enabled: true
249
+ Lint/ArrayLiteralInRegexp: # new in 1.71
250
+ Enabled: true
251
+ Lint/ConstantOverwrittenInRescue: # new in 1.31
252
+ Enabled: true
253
+ Lint/ConstantReassignment: # new in 1.70
254
+ Enabled: true
255
+ Lint/CopDirectiveSyntax: # new in 1.72
256
+ Enabled: true
257
+ Lint/DuplicateMagicComment: # new in 1.37
258
+ Enabled: true
259
+ Lint/DuplicateMatchPattern: # new in 1.50
260
+ Enabled: true
261
+ Lint/DuplicateSetElement: # new in 1.67
262
+ Enabled: true
263
+ Lint/HashNewWithKeywordArgumentsAsDefault: # new in 1.69
264
+ Enabled: true
265
+ Lint/ItWithoutArgumentsInBlock: # new in 1.59
266
+ Enabled: true
267
+ Lint/LiteralAssignmentInCondition: # new in 1.58
268
+ Enabled: true
269
+ Lint/MixedCaseRange: # new in 1.53
270
+ Enabled: true
271
+ Lint/NonAtomicFileOperation: # new in 1.31
272
+ Enabled: true
273
+ Lint/NumericOperationWithConstantResult: # new in 1.69
274
+ Enabled: true
275
+ Lint/RedundantRegexpQuantifiers: # new in 1.53
276
+ Enabled: true
277
+ Lint/RedundantTypeConversion: # new in 1.72
278
+ Enabled: true
279
+ Lint/RefinementImportMethods: # new in 1.27
280
+ Enabled: true
281
+ Lint/RequireRangeParentheses: # new in 1.32
282
+ Enabled: true
283
+ Lint/SharedMutableDefault: # new in 1.70
284
+ Enabled: true
285
+ Lint/SuppressedExceptionInNumberConversion: # new in 1.72
286
+ Enabled: true
287
+ Lint/UnescapedBracketInRegexp: # new in 1.68
288
+ Enabled: true
289
+ Lint/UselessConstantScoping: # new in 1.72
290
+ Enabled: true
291
+ Lint/UselessDefaultValueArgument: # new in 1.76
292
+ Enabled: true
293
+ Lint/UselessDefined: # new in 1.69
294
+ Enabled: true
295
+ Lint/UselessNumericOperation: # new in 1.66
296
+ Enabled: true
297
+ Lint/UselessOr: # new in 1.76
298
+ Enabled: true
299
+ Lint/UselessRescue: # new in 1.43
300
+ Enabled: true
301
+ Metrics/CollectionLiteralLength: # new in 1.47
302
+ Enabled: true
303
+ Naming/PredicateMethod: # new in 1.76
304
+ Enabled: true
305
+ Security/CompoundHash: # new in 1.28
306
+ Enabled: true
307
+ Style/AmbiguousEndlessMethodDefinition: # new in 1.68
308
+ Enabled: true
309
+ Style/ArrayIntersect: # new in 1.40
310
+ Enabled: true
311
+ Style/BitwisePredicate: # new in 1.68
312
+ Enabled: true
313
+ Style/CollectionQuerying: # new in 1.77
314
+ Enabled: true
315
+ Style/CombinableDefined: # new in 1.68
316
+ Enabled: true
317
+ Style/ComparableBetween: # new in 1.74
318
+ Enabled: true
319
+ Style/ComparableClamp: # new in 1.44
320
+ Enabled: true
321
+ Style/ConcatArrayLiterals: # new in 1.41
322
+ Enabled: true
323
+ Style/DataInheritance: # new in 1.49
324
+ Enabled: true
325
+ Style/DigChain: # new in 1.69
326
+ Enabled: true
327
+ Style/DirEmpty: # new in 1.48
328
+ Enabled: true
329
+ Style/EmptyHeredoc: # new in 1.32
330
+ Enabled: true
331
+ Style/EmptyStringInsideInterpolation: # new in 1.76
332
+ Enabled: true
333
+ Style/EnvHome: # new in 1.29
334
+ Enabled: true
335
+ Style/ExactRegexpMatch: # new in 1.51
336
+ Enabled: true
337
+ Style/FetchEnvVar: # new in 1.28
338
+ Enabled: true
339
+ Style/FileEmpty: # new in 1.48
340
+ Enabled: true
341
+ Style/FileNull: # new in 1.69
342
+ Enabled: true
343
+ Style/FileTouch: # new in 1.69
344
+ Enabled: true
345
+ Style/HashFetchChain: # new in 1.75
346
+ Enabled: true
347
+ Style/HashSlice: # new in 1.71
348
+ Enabled: true
349
+ Style/ItAssignment: # new in 1.70
350
+ Enabled: true
351
+ Style/ItBlockParameter: # new in 1.75
352
+ Enabled: true
353
+ Style/KeywordArgumentsMerging: # new in 1.68
354
+ Enabled: true
355
+ Style/MagicCommentFormat: # new in 1.35
356
+ Enabled: true
357
+ Style/MapCompactWithConditionalBlock: # new in 1.30
358
+ Enabled: true
359
+ Style/MapIntoArray: # new in 1.63
360
+ Enabled: true
361
+ Style/MapToSet: # new in 1.42
362
+ Enabled: true
363
+ Style/MinMaxComparison: # new in 1.42
364
+ Enabled: true
365
+ Style/ObjectThen: # new in 1.28
366
+ Enabled: true
367
+ Style/OperatorMethodCall: # new in 1.37
368
+ Enabled: true
369
+ Style/RedundantArrayConstructor: # new in 1.52
370
+ Enabled: true
371
+ Style/RedundantArrayFlatten: # new in 1.76
372
+ Enabled: true
373
+ Style/RedundantConstantBase: # new in 1.40
374
+ Enabled: true
375
+ Style/RedundantCurrentDirectoryInPath: # new in 1.53
376
+ Enabled: true
377
+ Style/RedundantDoubleSplatHashBraces: # new in 1.41
378
+ Enabled: true
379
+ Style/RedundantEach: # new in 1.38
380
+ Enabled: true
381
+ Style/RedundantFilterChain: # new in 1.52
382
+ Enabled: true
383
+ Style/RedundantFormat: # new in 1.72
384
+ Enabled: true
385
+ Style/RedundantHeredocDelimiterQuotes: # new in 1.45
386
+ Enabled: true
387
+ Style/RedundantInitialize: # new in 1.27
388
+ Enabled: true
389
+ Style/RedundantInterpolationUnfreeze: # new in 1.66
390
+ Enabled: true
391
+ Style/RedundantLineContinuation: # new in 1.49
392
+ Enabled: true
393
+ Style/RedundantRegexpArgument: # new in 1.53
394
+ Enabled: true
395
+ Style/RedundantRegexpConstructor: # new in 1.52
396
+ Enabled: true
397
+ Style/RedundantStringEscape: # new in 1.37
398
+ Enabled: true
399
+ Style/ReturnNilInPredicateMethodDefinition: # new in 1.53
400
+ Enabled: true
401
+ Style/SafeNavigationChainLength: # new in 1.68
402
+ Enabled: true
403
+ Style/SendWithLiteralMethodName: # new in 1.64
404
+ Enabled: true
405
+ Style/SingleLineDoEndBlock: # new in 1.57
406
+ Enabled: true
407
+ Style/SuperArguments: # new in 1.64
408
+ Enabled: true
409
+ Style/SuperWithArgsParentheses: # new in 1.58
410
+ Enabled: true
411
+ Style/YAMLFileRead: # new in 1.53
412
+ Enabled: true
data/.ruby-version CHANGED
@@ -1 +1 @@
1
- 2.7
1
+ ~> 3.3
data/CHANGES.md CHANGED
@@ -1,3 +1,13 @@
1
+ # 0.3.0 (2025-07-23)
2
+
3
+ - Update to support Ruby 3.3+ and Rails 7+ exclusively.
4
+ - Update Rubocop & Style changes.
5
+ - Log `HTTP_USER_AGENT`.
6
+
7
+ # 0.2.7 (2022-05-25)
8
+
9
+ - Set `BerkeleyLibrary::Logging.logger` on Railtie initialization
10
+
1
11
  # 0.2.6.2 (2022-05-25)
2
12
 
3
13
  - Fix `NoMethodError` when calling `BerkeleyLibrary::Logging::Loggers.default_logger` before
data/Dockerfile CHANGED
@@ -1,7 +1,7 @@
1
1
  # =============================================================================
2
2
  # Target: base
3
3
 
4
- FROM ruby:2.7-alpine AS base
4
+ FROM ruby:3.3-alpine AS base
5
5
 
6
6
  RUN apk --no-cache --update upgrade && \
7
7
  apk --no-cache add \
@@ -12,6 +12,7 @@ RUN apk --no-cache --update upgrade && \
12
12
  openssl \
13
13
  tzdata \
14
14
  xz-libs \
15
+ yaml-dev \
15
16
  && rm -rf /var/cache/apk/*
16
17
 
17
18
  WORKDIR /opt/app
@@ -29,8 +30,8 @@ RUN apk --update --no-cache add \
29
30
  git \
30
31
  && rm -rf /var/cache/apk/*
31
32
 
32
- # The base image ships bundler 1.17.2, but we want something more recent
33
- RUN gem install bundler -v 2.1.4
33
+ # The base image ships an older bundler, but we want something more recent
34
+ RUN gem install bundler -v 2.5.22
34
35
 
35
36
  # Copy codebase to WORKDIR. Unlike application projects, for a gem project
36
37
  # we need to do this before running `bundle install`, in order for the gem
@@ -11,8 +11,8 @@ require 'berkeley_library/logging/module_info'
11
11
 
12
12
  Gem::Specification.new do |spec|
13
13
  spec.name = BerkeleyLibrary::Logging::ModuleInfo::NAME
14
- spec.author = BerkeleyLibrary::Logging::ModuleInfo::AUTHOR
15
- spec.email = BerkeleyLibrary::Logging::ModuleInfo::AUTHOR_EMAIL
14
+ spec.author = BerkeleyLibrary::Logging::ModuleInfo::AUTHORS
15
+ spec.email = BerkeleyLibrary::Logging::ModuleInfo::AUTHOR_EMAILS
16
16
  spec.summary = BerkeleyLibrary::Logging::ModuleInfo::SUMMARY
17
17
  spec.description = BerkeleyLibrary::Logging::ModuleInfo::DESCRIPTION
18
18
  spec.license = BerkeleyLibrary::Logging::ModuleInfo::LICENSE
@@ -20,32 +20,31 @@ Gem::Specification.new do |spec|
20
20
  spec.homepage = BerkeleyLibrary::Logging::ModuleInfo::HOMEPAGE
21
21
 
22
22
  spec.files = `git ls-files -z`.split("\x0")
23
- spec.test_files = spec.files.grep(%r{^(test|spec|features|artifacts)/})
24
23
  spec.require_paths = ['lib']
25
24
 
26
- spec.required_ruby_version = ">= #{ruby_version}"
25
+ spec.required_ruby_version = ruby_version
27
26
 
28
- rails_version = '>= 6'
27
+ rails_version = '>= 7'
29
28
 
30
29
  spec.add_dependency 'activesupport', rails_version
31
30
  spec.add_dependency 'amazing_print', '~> 1.1'
32
- spec.add_dependency 'colorize', '~> 0.8.1'
31
+ spec.add_dependency 'colorize', '~> 1.0'
33
32
  spec.add_dependency 'lograge', '~> 0.11'
34
- spec.add_dependency 'ougai', '~> 1.8'
33
+ spec.add_dependency 'ougai', '~> 2.0'
35
34
 
36
35
  spec.add_development_dependency 'brakeman', '~> 4.9'
37
36
  spec.add_development_dependency 'bundle-audit', '~> 0.1'
38
37
  spec.add_development_dependency 'ci_reporter_rspec', '~> 1.0'
39
38
  spec.add_development_dependency 'dotenv', '~> 2.7'
40
- spec.add_development_dependency 'irb', '~> 1.2' # workaroundfor https://github.com/bundler/bundler/issues/6929
41
- spec.add_development_dependency 'listen', '>= 3.0.5', '< 3.2'
39
+ spec.add_development_dependency 'listen', '~> 3.2'
42
40
  spec.add_development_dependency 'rails', rails_version
43
41
  spec.add_development_dependency 'rake', '~> 13.0'
44
- spec.add_development_dependency 'rspec-support', '~> 3.9'
45
- spec.add_development_dependency 'rubocop', '~> 1.26.0'
46
- spec.add_development_dependency 'rubocop-rspec', '~> 2.4.0'
47
- spec.add_development_dependency 'simplecov', '~> 0.21.1'
48
- spec.add_development_dependency 'simplecov-console', '~> 0.9.1'
42
+ spec.add_development_dependency 'rspec', '~> 3.9'
43
+ spec.add_development_dependency 'rubocop', '~> 1.78.0'
44
+ spec.add_development_dependency 'rubocop-rake', '~> 0.7.1'
45
+ spec.add_development_dependency 'rubocop-rspec', '~> 3.6.0'
46
+ spec.add_development_dependency 'simplecov', '~> 0.21'
47
+ spec.add_development_dependency 'simplecov-console', '~> 0.9'
49
48
  spec.add_development_dependency 'simplecov-rcov', '~> 0.2'
50
49
 
51
50
  spec.metadata['rubygems_mfa_required'] = 'true'
@@ -8,13 +8,17 @@ module BerkeleyLibrary
8
8
  class Configurator
9
9
  class << self
10
10
 
11
+ # Applies the log configuration to the specified Rails config.
12
+ #
13
+ # @return [BerkeleyLibrary::Logging::Logger] the configured logger
11
14
  def configure(config)
12
15
  configure_lograge(config)
13
16
 
14
- logger = Loggers.new_default_logger(config)
15
- logger.info("Custom logger initialized for environment #{Logging.env.inspect}")
16
- configure_webpacker(logger)
17
- config.logger = logger
17
+ Loggers.new_default_logger(config).tap do |logger|
18
+ logger.info("Custom logger initialized for environment #{Logging.env.inspect}")
19
+ configure_webpacker(logger)
20
+ config.logger = logger
21
+ end
18
22
  end
19
23
 
20
24
  private
@@ -13,7 +13,7 @@ module BerkeleyLibrary
13
13
  @env ||= begin
14
14
  # NOTE: can't just self.env= b/c it returns the wrong value -- see
15
15
  # https://stackoverflow.com/q/65226532/27358
16
- env = (ENV['RAILS_ENV'] || ENV['RACK_ENV'] || FALLBACK_ENV)
16
+ env = ENV['RAILS_ENV'] || ENV['RACK_ENV'] || FALLBACK_ENV
17
17
  ensure_rails_env_like(env)
18
18
  end
19
19
  end
@@ -14,7 +14,8 @@ module BerkeleyLibrary
14
14
  remote_ip: 'action_dispatch.remote_ip',
15
15
  remote_addr: 'REMOTE_ADDR',
16
16
  x_forwarded_for: 'HTTP_X_FORWARDED_FOR',
17
- forwarded: 'HTTP_FORWARDED' # RFC 7239
17
+ forwarded: 'HTTP_FORWARDED', # RFC 7239
18
+ user_agent: 'HTTP_USER_AGENT'
18
19
  }.freeze
19
20
 
20
21
  class << self
@@ -63,7 +63,7 @@ module BerkeleyLibrary
63
63
 
64
64
  def ensure_log_directory
65
65
  File.join(workdir, FALLBACK_LOG_DIR).tap do |log_dir|
66
- FileUtils.mkdir(log_dir) unless File.exist?(log_dir)
66
+ FileUtils.mkdir_p(log_dir)
67
67
  raise ArgumentError, "Not a directory: #{log_dir}" unless File.directory?(log_dir)
68
68
  end
69
69
  end
@@ -2,12 +2,12 @@ module BerkeleyLibrary
2
2
  module Logging
3
3
  class ModuleInfo
4
4
  NAME = 'berkeley_library-logging'.freeze
5
- AUTHOR = 'David Moles'.freeze
6
- AUTHOR_EMAIL = 'dmoles@berkeley.edu'.freeze
5
+ AUTHORS = ['David Moles', 'maría a. matienzo'].freeze
6
+ AUTHOR_EMAILS = ['dmoles@berkeley.edu', 'matienzo@berkeley.edu'].freeze
7
7
  SUMMARY = 'Opinionated Ruby/Rails logging for UC Berkeley Library'.freeze
8
8
  DESCRIPTION = 'A gem providing shared logging code for UC Berkeley Library gems and Rails applications'.freeze
9
9
  LICENSE = 'MIT'.freeze
10
- VERSION = '0.2.6.2'.freeze
10
+ VERSION = '0.3.0'.freeze
11
11
  HOMEPAGE = 'https://github.com/BerkeleyLibrary/logging'.freeze
12
12
 
13
13
  private_class_method :new
@@ -8,7 +8,8 @@ module BerkeleyLibrary
8
8
  # Don't use the Railtie's own `config` because configure() needs
9
9
  # Rails::Application::Configuration#default_log_file
10
10
  initializer('logging.configure_berkeley_library_logging', before: :initialize_logger) do |app|
11
- Configurator.configure(app.config)
11
+ logger = Configurator.configure(app.config)
12
+ BerkeleyLibrary::Logging.logger = logger
12
13
  end
13
14
  end
14
15
  end
@@ -24,10 +24,10 @@ module BerkeleyLibrary
24
24
  @logger = (ensure_logger(v) unless v.nil?)
25
25
  end
26
26
 
27
- private
28
-
29
27
  LOG_METHODS = %i[debug info warn error].freeze
30
28
 
29
+ private
30
+
31
31
  def ensure_logger(v)
32
32
  return v if (missing = LOG_METHODS.reject { |m| v.respond_to?(m) }).empty?
33
33
 
data/rakelib/.rubocop.yml CHANGED
@@ -1,4 +1,7 @@
1
1
  inherit_from: ../.rubocop.yml
2
2
 
3
+ plugins:
4
+ - rubocop-rake
5
+
3
6
  Metrics/BlockLength:
4
7
  Enabled: false
@@ -1,6 +1,7 @@
1
1
  require 'colorize'
2
2
 
3
3
  namespace :simplecov do
4
+ desc 'Run coverage analysis'
4
5
  task :check_coverage do
5
6
  ENV['COVERAGE'] ||= 'true'
6
7
  Rake::Task['spec'].invoke
@@ -9,6 +10,7 @@ namespace :simplecov do
9
10
  raise
10
11
  end
11
12
 
13
+ desc 'Create the structured coverage report'
12
14
  task :report do
13
15
  require 'simplecov'
14
16
  require 'simplecov-rcov'
data/rakelib/spec.rake CHANGED
@@ -1,6 +1,7 @@
1
1
  require 'rspec/core/rake_task'
2
2
 
3
3
  namespace :spec do
4
+ desc 'Prepare the specs for execution'
4
5
  task :prepare do
5
6
  if ENV['GENERATE_REPORTS']
6
7
  ENV['CI_REPORTS'] = 'artifacts/rspec'
@@ -14,7 +15,7 @@ namespace :spec do
14
15
  groups.each do |group|
15
16
  desc "Run specs in spec/#{group} directory"
16
17
  RSpec::Core::RakeTask.new(group) do |task|
17
- task.rspec_opts = %w[--color --format documentation --order default]
18
+ task.rspec_opts = %w[--color --format documentation]
18
19
  task.pattern = "spec/#{group}/**/*_spec.rb"
19
20
  end
20
21
  end
@@ -26,6 +27,6 @@ desc 'Run all specs in spec directory'
26
27
  task spec: ['spec:prepare'] do
27
28
  Rake::Task['spec:all'].invoke
28
29
  ensure
29
- reports_dir = ENV['CI_REPORTS']
30
+ reports_dir = ENV.fetch('CI_REPORTS', nil)
30
31
  puts "JUnit-format XML test report written to #{reports_dir}" if reports_dir
31
32
  end
data/spec/.rubocop.yml CHANGED
@@ -1,6 +1,6 @@
1
1
  inherit_from: ../.rubocop.yml
2
2
 
3
- require:
3
+ plugins:
4
4
  - rubocop-rspec
5
5
 
6
6
  Style/ClassAndModuleChildren:
@@ -57,9 +57,12 @@ RSpec/ExpectOutput:
57
57
  Enabled: false
58
58
 
59
59
  # your naming scheme is not in possession of all the facts
60
- RSpec/FilePath:
60
+ RSpec/SpecFilePathFormat:
61
61
  Enabled: false
62
62
 
63
+ RSpec/SpecFilePathSuffix:
64
+ Enabled: true
65
+
63
66
  # explicit >>> implicit
64
67
  RSpec/InstanceVariable:
65
68
  Enabled: false
@@ -96,6 +99,9 @@ RSpec/StubbedMock:
96
99
  RSpec/VerifiedDoubles:
97
100
  Enabled: false
98
101
 
102
+ RSpec/RemoveConst:
103
+ Enabled: false
104
+
99
105
  ############################################################
100
106
  # rubocop-rspec
101
107
 
@@ -103,6 +109,3 @@ RSpec/VerifiedDoubles:
103
109
 
104
110
  RSpec/IdenticalEqualityAssertion: # new in 2.4
105
111
  Enabled: true
106
-
107
- RSpec/Rails/AvoidSetupHook: # new in 2.4
108
- Enabled: true
@@ -23,11 +23,16 @@ module BerkeleyLibrary
23
23
  expect(config.logger).to be_a(Logging::Logger)
24
24
  end
25
25
 
26
+ it 'returns the logger' do
27
+ logger = Configurator.configure(config)
28
+ expect(logger).to be(config.logger)
29
+ end
30
+
26
31
  describe :configure_lograge! do
27
32
  it 'enables Lograge' do
28
33
  Configurator.configure(config)
29
34
  lograge = config.lograge
30
- expect(lograge.enabled).to eq(true)
35
+ expect(lograge.enabled).to be(true)
31
36
  end
32
37
 
33
38
  context 'events' do
@@ -58,7 +63,8 @@ module BerkeleyLibrary
58
63
  'action_dispatch.remote_ip' => 'value from action_dispatch.remote_ip',
59
64
  'REMOTE_ADDR' => 'value from REMOTE_ADDR',
60
65
  'HTTP_X_FORWARDED_FOR' => 'value from HTTP_X_FORWARDED_FOR',
61
- 'HTTP_FORWARDED' => 'value from HTTP_FORWARDED'
66
+ 'HTTP_FORWARDED' => 'value from HTTP_FORWARDED',
67
+ 'HTTP_USER_AGENT' => 'value from HTTP_USER_AGENT'
62
68
  }
63
69
  end
64
70
 
@@ -80,10 +86,8 @@ module BerkeleyLibrary
80
86
  allow(session).to receive(:to_hash).and_return(session_hash)
81
87
 
82
88
  @request = instance_double(ActionDispatch::Request)
83
- allow(request).to receive(:origin).and_return('http://example.org:3000')
84
- allow(request).to receive(:base_url).and_return('https://example.org:3443')
85
- allow(request).to receive(:x_csrf_token).and_return('5551212')
86
- allow(request).to receive(:session).and_return(session)
89
+ allow(request).to receive_messages(origin: 'http://example.org:3000', base_url: 'https://example.org:3443', x_csrf_token: '5551212',
90
+ session: session)
87
91
 
88
92
  @payload = {
89
93
  params: params,
@@ -146,7 +150,7 @@ module BerkeleyLibrary
146
150
 
147
151
  describe 'Webpacker' do
148
152
  it 'works if Webpacker is not present' do
149
- expect(Object.const_defined?(:Webpacker)).to eq(false) # just to be sure
153
+ expect(Object.const_defined?(:Webpacker)).to be(false) # just to be sure
150
154
  expect { Configurator.configure(config) }.not_to raise_error
151
155
  end
152
156
 
@@ -18,7 +18,7 @@ module BerkeleyLibrary
18
18
  expect(defined?(Rails)).to be_truthy # just to be sure
19
19
  Logging.env = 'elvis'
20
20
  expect(Rails.env).to eq('elvis')
21
- expect(Rails.env.elvis?).to eq(true)
21
+ expect(Rails.env.elvis?).to be(true)
22
22
  end
23
23
  end
24
24
  end
@@ -38,7 +38,7 @@ module BerkeleyLibrary
38
38
  logging_initializer.run(app)
39
39
  bootstrap_logger_initializer.run(app)
40
40
 
41
- expect(Rails.logger).to be_a(BerkeleyLibrary::Logging::Logger)
41
+ expect(Rails.logger.broadcasts).to include(a_kind_of(BerkeleyLibrary::Logging::Logger))
42
42
  end
43
43
  end
44
44
  end
@@ -29,7 +29,7 @@ module BerkeleyLibrary
29
29
  it 'enables Lograge' do
30
30
  Configurator.configure(config)
31
31
  lograge = config.lograge
32
- expect(lograge.enabled).to eq(true)
32
+ expect(lograge.enabled).to be(true)
33
33
  end
34
34
 
35
35
  it 'extracts request info from log events' do
@@ -42,7 +42,8 @@ module BerkeleyLibrary
42
42
  'action_dispatch.remote_ip' => 'value from action_dispatch.remote_ip',
43
43
  'REMOTE_ADDR' => 'value from REMOTE_ADDR',
44
44
  'HTTP_X_FORWARDED_FOR' => 'value from HTTP_X_FORWARDED_FOR',
45
- 'HTTP_FORWARDED' => 'value from HTTP_FORWARDED'
45
+ 'HTTP_FORWARDED' => 'value from HTTP_FORWARDED',
46
+ 'HTTP_USER_AGENT' => 'value from HTTP_USER_AGENT'
46
47
  }
47
48
 
48
49
  expected_header_map = {
@@ -78,7 +79,7 @@ module BerkeleyLibrary
78
79
 
79
80
  describe 'Webpacker' do
80
81
  it 'works if Webpacker is not present' do
81
- expect(Object.const_defined?(:Webpacker)).to eq(false) # just to be sure
82
+ expect(Object.const_defined?(:Webpacker)).to be(false) # just to be sure
82
83
  expect { Configurator.configure(config) }.not_to raise_error
83
84
  end
84
85
 
metadata CHANGED
@@ -1,14 +1,15 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: berkeley_library-logging
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.6.2
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - David Moles
8
+ - maría a. matienzo
8
9
  autorequire:
9
10
  bindir: bin
10
11
  cert_chain: []
11
- date: 2022-05-25 00:00:00.000000000 Z
12
+ date: 2025-07-24 00:00:00.000000000 Z
12
13
  dependencies:
13
14
  - !ruby/object:Gem::Dependency
14
15
  name: activesupport
@@ -16,14 +17,14 @@ dependencies:
16
17
  requirements:
17
18
  - - ">="
18
19
  - !ruby/object:Gem::Version
19
- version: '6'
20
+ version: '7'
20
21
  type: :runtime
21
22
  prerelease: false
22
23
  version_requirements: !ruby/object:Gem::Requirement
23
24
  requirements:
24
25
  - - ">="
25
26
  - !ruby/object:Gem::Version
26
- version: '6'
27
+ version: '7'
27
28
  - !ruby/object:Gem::Dependency
28
29
  name: amazing_print
29
30
  requirement: !ruby/object:Gem::Requirement
@@ -44,14 +45,14 @@ dependencies:
44
45
  requirements:
45
46
  - - "~>"
46
47
  - !ruby/object:Gem::Version
47
- version: 0.8.1
48
+ version: '1.0'
48
49
  type: :runtime
49
50
  prerelease: false
50
51
  version_requirements: !ruby/object:Gem::Requirement
51
52
  requirements:
52
53
  - - "~>"
53
54
  - !ruby/object:Gem::Version
54
- version: 0.8.1
55
+ version: '1.0'
55
56
  - !ruby/object:Gem::Dependency
56
57
  name: lograge
57
58
  requirement: !ruby/object:Gem::Requirement
@@ -72,14 +73,14 @@ dependencies:
72
73
  requirements:
73
74
  - - "~>"
74
75
  - !ruby/object:Gem::Version
75
- version: '1.8'
76
+ version: '2.0'
76
77
  type: :runtime
77
78
  prerelease: false
78
79
  version_requirements: !ruby/object:Gem::Requirement
79
80
  requirements:
80
81
  - - "~>"
81
82
  - !ruby/object:Gem::Version
82
- version: '1.8'
83
+ version: '2.0'
83
84
  - !ruby/object:Gem::Dependency
84
85
  name: brakeman
85
86
  requirement: !ruby/object:Gem::Requirement
@@ -137,137 +138,131 @@ dependencies:
137
138
  - !ruby/object:Gem::Version
138
139
  version: '2.7'
139
140
  - !ruby/object:Gem::Dependency
140
- name: irb
141
+ name: listen
141
142
  requirement: !ruby/object:Gem::Requirement
142
143
  requirements:
143
144
  - - "~>"
144
145
  - !ruby/object:Gem::Version
145
- version: '1.2'
146
+ version: '3.2'
146
147
  type: :development
147
148
  prerelease: false
148
149
  version_requirements: !ruby/object:Gem::Requirement
149
150
  requirements:
150
151
  - - "~>"
151
152
  - !ruby/object:Gem::Version
152
- version: '1.2'
153
+ version: '3.2'
153
154
  - !ruby/object:Gem::Dependency
154
- name: listen
155
+ name: rails
155
156
  requirement: !ruby/object:Gem::Requirement
156
157
  requirements:
157
158
  - - ">="
158
159
  - !ruby/object:Gem::Version
159
- version: 3.0.5
160
- - - "<"
161
- - !ruby/object:Gem::Version
162
- version: '3.2'
160
+ version: '7'
163
161
  type: :development
164
162
  prerelease: false
165
163
  version_requirements: !ruby/object:Gem::Requirement
166
164
  requirements:
167
165
  - - ">="
168
166
  - !ruby/object:Gem::Version
169
- version: 3.0.5
170
- - - "<"
171
- - !ruby/object:Gem::Version
172
- version: '3.2'
167
+ version: '7'
173
168
  - !ruby/object:Gem::Dependency
174
- name: rails
169
+ name: rake
175
170
  requirement: !ruby/object:Gem::Requirement
176
171
  requirements:
177
- - - ">="
172
+ - - "~>"
178
173
  - !ruby/object:Gem::Version
179
- version: '6'
174
+ version: '13.0'
180
175
  type: :development
181
176
  prerelease: false
182
177
  version_requirements: !ruby/object:Gem::Requirement
183
178
  requirements:
184
- - - ">="
179
+ - - "~>"
185
180
  - !ruby/object:Gem::Version
186
- version: '6'
181
+ version: '13.0'
187
182
  - !ruby/object:Gem::Dependency
188
- name: rake
183
+ name: rspec
189
184
  requirement: !ruby/object:Gem::Requirement
190
185
  requirements:
191
186
  - - "~>"
192
187
  - !ruby/object:Gem::Version
193
- version: '13.0'
188
+ version: '3.9'
194
189
  type: :development
195
190
  prerelease: false
196
191
  version_requirements: !ruby/object:Gem::Requirement
197
192
  requirements:
198
193
  - - "~>"
199
194
  - !ruby/object:Gem::Version
200
- version: '13.0'
195
+ version: '3.9'
201
196
  - !ruby/object:Gem::Dependency
202
- name: rspec-support
197
+ name: rubocop
203
198
  requirement: !ruby/object:Gem::Requirement
204
199
  requirements:
205
200
  - - "~>"
206
201
  - !ruby/object:Gem::Version
207
- version: '3.9'
202
+ version: 1.78.0
208
203
  type: :development
209
204
  prerelease: false
210
205
  version_requirements: !ruby/object:Gem::Requirement
211
206
  requirements:
212
207
  - - "~>"
213
208
  - !ruby/object:Gem::Version
214
- version: '3.9'
209
+ version: 1.78.0
215
210
  - !ruby/object:Gem::Dependency
216
- name: rubocop
211
+ name: rubocop-rake
217
212
  requirement: !ruby/object:Gem::Requirement
218
213
  requirements:
219
214
  - - "~>"
220
215
  - !ruby/object:Gem::Version
221
- version: 1.26.0
216
+ version: 0.7.1
222
217
  type: :development
223
218
  prerelease: false
224
219
  version_requirements: !ruby/object:Gem::Requirement
225
220
  requirements:
226
221
  - - "~>"
227
222
  - !ruby/object:Gem::Version
228
- version: 1.26.0
223
+ version: 0.7.1
229
224
  - !ruby/object:Gem::Dependency
230
225
  name: rubocop-rspec
231
226
  requirement: !ruby/object:Gem::Requirement
232
227
  requirements:
233
228
  - - "~>"
234
229
  - !ruby/object:Gem::Version
235
- version: 2.4.0
230
+ version: 3.6.0
236
231
  type: :development
237
232
  prerelease: false
238
233
  version_requirements: !ruby/object:Gem::Requirement
239
234
  requirements:
240
235
  - - "~>"
241
236
  - !ruby/object:Gem::Version
242
- version: 2.4.0
237
+ version: 3.6.0
243
238
  - !ruby/object:Gem::Dependency
244
239
  name: simplecov
245
240
  requirement: !ruby/object:Gem::Requirement
246
241
  requirements:
247
242
  - - "~>"
248
243
  - !ruby/object:Gem::Version
249
- version: 0.21.1
244
+ version: '0.21'
250
245
  type: :development
251
246
  prerelease: false
252
247
  version_requirements: !ruby/object:Gem::Requirement
253
248
  requirements:
254
249
  - - "~>"
255
250
  - !ruby/object:Gem::Version
256
- version: 0.21.1
251
+ version: '0.21'
257
252
  - !ruby/object:Gem::Dependency
258
253
  name: simplecov-console
259
254
  requirement: !ruby/object:Gem::Requirement
260
255
  requirements:
261
256
  - - "~>"
262
257
  - !ruby/object:Gem::Version
263
- version: 0.9.1
258
+ version: '0.9'
264
259
  type: :development
265
260
  prerelease: false
266
261
  version_requirements: !ruby/object:Gem::Requirement
267
262
  requirements:
268
263
  - - "~>"
269
264
  - !ruby/object:Gem::Version
270
- version: 0.9.1
265
+ version: '0.9'
271
266
  - !ruby/object:Gem::Dependency
272
267
  name: simplecov-rcov
273
268
  requirement: !ruby/object:Gem::Requirement
@@ -284,12 +279,15 @@ dependencies:
284
279
  version: '0.2'
285
280
  description: A gem providing shared logging code for UC Berkeley Library gems and
286
281
  Rails applications
287
- email: dmoles@berkeley.edu
282
+ email:
283
+ - dmoles@berkeley.edu
284
+ - matienzo@berkeley.edu
288
285
  executables: []
289
286
  extensions: []
290
287
  extra_rdoc_files: []
291
288
  files:
292
289
  - ".github/workflows/build.yml"
290
+ - ".github/workflows/gem-push.yml"
293
291
  - ".gitignore"
294
292
  - ".idea/inspectionProfiles/Project_Default.xml"
295
293
  - ".idea/logging.iml"
@@ -352,34 +350,17 @@ require_paths:
352
350
  - lib
353
351
  required_ruby_version: !ruby/object:Gem::Requirement
354
352
  requirements:
355
- - - ">="
353
+ - - "~>"
356
354
  - !ruby/object:Gem::Version
357
- version: '2.7'
355
+ version: '3.3'
358
356
  required_rubygems_version: !ruby/object:Gem::Requirement
359
357
  requirements:
360
358
  - - ">="
361
359
  - !ruby/object:Gem::Version
362
360
  version: '0'
363
361
  requirements: []
364
- rubygems_version: 3.1.6
362
+ rubygems_version: 3.5.22
365
363
  signing_key:
366
364
  specification_version: 4
367
365
  summary: Opinionated Ruby/Rails logging for UC Berkeley Library
368
- test_files:
369
- - artifacts/.keep
370
- - spec/.rubocop.yml
371
- - spec/rails/ucblit/logging/configurator_spec.rb
372
- - spec/rails/ucblit/logging/env_spec.rb
373
- - spec/rails/ucblit/logging/formatters_spec.rb
374
- - spec/rails/ucblit/logging/loggers_spec.rb
375
- - spec/rails/ucblit/logging/railtie_spec.rb
376
- - spec/rails/ucblit/logging/safe_serializer_spec.rb
377
- - spec/rails/ucblit/logging_spec.rb
378
- - spec/rails_helper.rb
379
- - spec/spec_helper.rb
380
- - spec/standalone/ucblit/logging/configurator_spec.rb
381
- - spec/standalone/ucblit/logging/formatters_spec.rb
382
- - spec/standalone/ucblit/logging/loggers_spec.rb
383
- - spec/standalone/ucblit/logging/safe_serializer_spec.rb
384
- - spec/standalone/ucblit/logging_spec.rb
385
- - spec/standalone_helper.rb
366
+ test_files: []