mongoid-cached-json 1.7.0 → 1.7.1
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
- data/.github/workflows/danger-comment.yml +10 -2
- data/.github/workflows/danger.yml +9 -2
- data/.github/workflows/lint.yml +29 -0
- data/.github/workflows/release.yml +31 -0
- data/.github/workflows/test.yml +22 -16
- data/.gitignore +1 -0
- data/.rubocop.yml +142 -3
- data/.rubocop_todo.yml +97 -75
- data/.spellcheck.txt +84 -0
- data/CHANGELOG.md +6 -2
- data/CONTRIBUTING.md +18 -19
- data/Gemfile +13 -1
- data/README.md +60 -76
- data/RELEASING.md +35 -0
- data/Rakefile +22 -3
- data/UPGRADING.md +3 -3
- data/lib/mongoid-cached-json/cached_json.rb +1 -1
- data/lib/mongoid-cached-json/version.rb +1 -1
- data/mongoid-cached-json.gemspec +1 -2
- data/script/release.rb +16 -0
- data/spec/coverage_spec.rb +44 -0
- data/spec/release/release_spec.rb +77 -0
- metadata +10 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: '0419b583880c1f8874e9ca75fd1cd452153d7c91a33c5aa02d8abf4bc3ca2aa4'
|
|
4
|
+
data.tar.gz: b31e7f206c5df249b0b9e4b52db2e11021604e7ba572f8aa586601a49ec0075d
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: f19bf4bd4ff34a0218e47ef9a11345486c5963df41e284e3f035fb72688db042aef1563a0303e38c24baa810c79c5ea936a5c439c9e91a13b4133583e7d28d5e
|
|
7
|
+
data.tar.gz: 80236d90267a43ee6a50c340ef85fbd6309f64e245eaf0a034c68eee2c876bb8fc27a64edd3fafbce253c002180da9ff03b18051e2a68ddb2129b2e2c0aec57c
|
|
@@ -5,7 +5,15 @@ on:
|
|
|
5
5
|
workflows: [Danger]
|
|
6
6
|
types: [completed]
|
|
7
7
|
|
|
8
|
+
permissions:
|
|
9
|
+
actions: read
|
|
10
|
+
issues: write
|
|
11
|
+
pull-requests: write
|
|
12
|
+
|
|
8
13
|
jobs:
|
|
9
14
|
comment:
|
|
10
|
-
|
|
11
|
-
|
|
15
|
+
name: Post Review Comment
|
|
16
|
+
uses: danger/danger-pr-comment/.github/workflows/danger-comment.yml@645e89bcc7be89ee7e8362166110b05cbced8e59 # v0.3.0
|
|
17
|
+
with:
|
|
18
|
+
base-branch: '*'
|
|
19
|
+
comment-empty: false
|
|
@@ -4,10 +4,17 @@ on:
|
|
|
4
4
|
pull_request:
|
|
5
5
|
types: [opened, reopened, edited, synchronize]
|
|
6
6
|
|
|
7
|
+
permissions:
|
|
8
|
+
contents: read
|
|
9
|
+
|
|
10
|
+
concurrency:
|
|
11
|
+
group: ${{ github.workflow }}-${{ github.ref }}
|
|
12
|
+
cancel-in-progress: true
|
|
13
|
+
|
|
7
14
|
jobs:
|
|
8
15
|
danger:
|
|
9
|
-
|
|
10
|
-
|
|
16
|
+
name: Review Pull Request
|
|
17
|
+
uses: danger/danger-pr-comment/.github/workflows/danger-run.yml@645e89bcc7be89ee7e8362166110b05cbced8e59 # v0.3.0
|
|
11
18
|
with:
|
|
12
19
|
ruby-version: '3.3'
|
|
13
20
|
bundler-cache: true
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
name: Lint
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [master]
|
|
6
|
+
pull_request:
|
|
7
|
+
|
|
8
|
+
concurrency:
|
|
9
|
+
group: ${{ github.workflow }}-${{ github.ref }}
|
|
10
|
+
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
|
|
11
|
+
|
|
12
|
+
permissions:
|
|
13
|
+
contents: read
|
|
14
|
+
|
|
15
|
+
jobs:
|
|
16
|
+
lint:
|
|
17
|
+
name: Lint Code and Documentation
|
|
18
|
+
runs-on: ubuntu-latest
|
|
19
|
+
timeout-minutes: 10
|
|
20
|
+
steps:
|
|
21
|
+
- name: Check Out Code
|
|
22
|
+
uses: actions/checkout@v7
|
|
23
|
+
- name: Set Up Ruby
|
|
24
|
+
uses: ruby/setup-ruby@v1
|
|
25
|
+
with:
|
|
26
|
+
ruby-version: '4.0'
|
|
27
|
+
bundler-cache: true
|
|
28
|
+
- name: Run Lint
|
|
29
|
+
run: bundle exec rake lint
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
name: Release
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
workflow_dispatch:
|
|
5
|
+
inputs:
|
|
6
|
+
version:
|
|
7
|
+
description: Optional release version overriding the checked-in version.
|
|
8
|
+
type: string
|
|
9
|
+
required: false
|
|
10
|
+
dry-run:
|
|
11
|
+
description: Check release prerequisites, such as RubyGems Trusted Publishing, without releasing.
|
|
12
|
+
type: boolean
|
|
13
|
+
default: false
|
|
14
|
+
|
|
15
|
+
permissions:
|
|
16
|
+
contents: write
|
|
17
|
+
id-token: write
|
|
18
|
+
|
|
19
|
+
jobs:
|
|
20
|
+
release:
|
|
21
|
+
if: github.repository == 'mongoid/mongoid-cached-json' && github.ref == 'refs/heads/master'
|
|
22
|
+
uses: dblock/ruby-gem-release/.github/workflows/release.yml@v0.9.0
|
|
23
|
+
with:
|
|
24
|
+
ruby-version: '3.3'
|
|
25
|
+
version: ${{ inputs.version }}
|
|
26
|
+
dry-run: ${{ inputs.dry-run }}
|
|
27
|
+
test: |
|
|
28
|
+
docker run --detach --name mongodb --publish 27017:27017 mongo:8.0
|
|
29
|
+
until docker exec mongodb mongosh --quiet --eval 'db.adminCommand({ping: 1})'; do sleep 1; done
|
|
30
|
+
docker run --detach --name memcached --publish 11211:11211 memcached:1.6
|
|
31
|
+
bundle exec rake
|
data/.github/workflows/test.yml
CHANGED
|
@@ -1,6 +1,12 @@
|
|
|
1
1
|
name: Test
|
|
2
2
|
|
|
3
|
-
on:
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [master]
|
|
6
|
+
pull_request:
|
|
7
|
+
concurrency:
|
|
8
|
+
group: ${{ github.workflow }}-${{ github.ref }}
|
|
9
|
+
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
|
|
4
10
|
|
|
5
11
|
permissions:
|
|
6
12
|
contents: read
|
|
@@ -17,15 +23,16 @@ jobs:
|
|
|
17
23
|
- { ruby: '2.1.9', mongoid: '3', mongodb: '3.6', bundler: '1.17.3' }
|
|
18
24
|
- { ruby: '2.3.8', mongoid: '4', mongodb: '3.6', bundler: '2.3.26' }
|
|
19
25
|
- { ruby: '2.3.8', mongoid: '5', mongodb: '4.0', bundler: '2.3.26' }
|
|
20
|
-
- { ruby: '2.5.9', mongoid: '6', mongodb: '4.0', bundler: '2.3.26' }
|
|
26
|
+
- { ruby: '2.5.9', mongoid: '6', mongodb: '4.0', bundler: '2.3.26', coverage: true }
|
|
21
27
|
- { ruby: '2.7.8', mongoid: '7', mongodb: '4.4', bundler: '2.4.22' }
|
|
22
28
|
- { ruby: '3.2', mongoid: '8', mongodb: '6.0', bundler: default }
|
|
23
29
|
- { ruby: '3.3', mongoid: '9', mongodb: '7.0', bundler: default }
|
|
24
30
|
- { ruby: '3.4', mongoid: '9', mongodb: '8.0', bundler: default }
|
|
25
|
-
- { ruby: '4.0', mongoid: '9', mongodb: '8.0', bundler: default }
|
|
31
|
+
- { ruby: '4.0', mongoid: '9', mongodb: '8.0', bundler: default, coverage: true }
|
|
26
32
|
env:
|
|
33
|
+
BUNDLE_BUILD__BSON: --with-cflags=-Wno-error=implicit-function-declaration
|
|
27
34
|
MONGOID_VERSION: ${{ matrix.mongoid }}
|
|
28
|
-
COVERAGE: ${{ matrix.
|
|
35
|
+
COVERAGE: ${{ matrix.coverage }}
|
|
29
36
|
services:
|
|
30
37
|
mongodb:
|
|
31
38
|
image: mongo:${{ matrix.mongodb }}
|
|
@@ -45,23 +52,22 @@ jobs:
|
|
|
45
52
|
bundler-cache: true
|
|
46
53
|
- run: bundle exec rake spec
|
|
47
54
|
- name: Report coverage to Coveralls
|
|
48
|
-
if: matrix.
|
|
55
|
+
if: matrix.coverage
|
|
49
56
|
uses: coverallsapp/github-action@v2
|
|
50
57
|
with:
|
|
51
58
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
52
59
|
file: coverage/.resultset.json
|
|
53
60
|
format: simplecov
|
|
61
|
+
parallel: true
|
|
62
|
+
flag-name: mongoid-${{ matrix.mongoid }}
|
|
54
63
|
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
64
|
+
coverage:
|
|
65
|
+
needs: test
|
|
66
|
+
if: ${{ always() && needs.test.result == 'success' }}
|
|
67
|
+
runs-on: ubuntu-latest
|
|
68
|
+
timeout-minutes: 20
|
|
60
69
|
steps:
|
|
61
|
-
- uses:
|
|
62
|
-
- uses: ruby/setup-ruby@v1
|
|
70
|
+
- uses: coverallsapp/github-action@v2
|
|
63
71
|
with:
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
bundler-cache: true
|
|
67
|
-
- run: bundle exec rake rubocop
|
|
72
|
+
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
73
|
+
parallel-finished: true
|
data/.gitignore
CHANGED
data/.rubocop.yml
CHANGED
|
@@ -1,7 +1,146 @@
|
|
|
1
|
+
plugins:
|
|
2
|
+
- rubocop-md
|
|
3
|
+
- rubocop-prose
|
|
4
|
+
- rubocop-rake
|
|
5
|
+
- rubocop-spellcheck
|
|
6
|
+
- rubocop-yaml
|
|
7
|
+
|
|
8
|
+
inherit_from: ".rubocop_todo.yml"
|
|
9
|
+
|
|
1
10
|
AllCops:
|
|
2
11
|
Exclude:
|
|
3
|
-
|
|
4
|
-
|
|
12
|
+
- vendor/**/*
|
|
13
|
+
- bin/**/*
|
|
14
|
+
- coverage/**/*
|
|
15
|
+
- pkg/**/*
|
|
5
16
|
NewCops: disable
|
|
17
|
+
SuggestExtensions: false
|
|
18
|
+
inherit_mode:
|
|
19
|
+
merge:
|
|
20
|
+
- Include
|
|
21
|
+
Include:
|
|
22
|
+
- ".github/**/*.yml"
|
|
23
|
+
- ".rubocop.yml"
|
|
24
|
+
|
|
25
|
+
YAML/Lint/InvalidSyntax:
|
|
26
|
+
Include:
|
|
27
|
+
- "**/*.yml"
|
|
28
|
+
- "**/*.yaml"
|
|
29
|
+
|
|
30
|
+
YAML/Lint/DuplicateKey:
|
|
31
|
+
Include:
|
|
32
|
+
- "**/*.yml"
|
|
33
|
+
- "**/*.yaml"
|
|
34
|
+
|
|
35
|
+
Naming/FileName:
|
|
36
|
+
inherit_mode:
|
|
37
|
+
merge:
|
|
38
|
+
- Exclude
|
|
39
|
+
Exclude:
|
|
40
|
+
- "**/*.md"
|
|
41
|
+
- ".github/workflows/*.yml"
|
|
42
|
+
- lib/mongoid-cached-json.rb
|
|
43
|
+
|
|
44
|
+
Metrics/MethodLength:
|
|
45
|
+
inherit_mode:
|
|
46
|
+
merge:
|
|
47
|
+
- Exclude
|
|
48
|
+
Exclude:
|
|
49
|
+
- "**/*.md"
|
|
50
|
+
|
|
51
|
+
Metrics/AbcSize:
|
|
52
|
+
inherit_mode:
|
|
53
|
+
merge:
|
|
54
|
+
- Exclude
|
|
55
|
+
Exclude:
|
|
56
|
+
- "**/*.md"
|
|
57
|
+
|
|
58
|
+
Naming/HeredocDelimiterNaming:
|
|
59
|
+
inherit_mode:
|
|
60
|
+
merge:
|
|
61
|
+
- Exclude
|
|
62
|
+
Exclude:
|
|
63
|
+
- "**/*.md"
|
|
64
|
+
|
|
65
|
+
Style/SafeNavigation:
|
|
66
|
+
inherit_mode:
|
|
67
|
+
merge:
|
|
68
|
+
- Exclude
|
|
69
|
+
Exclude:
|
|
70
|
+
- "**/*.md"
|
|
71
|
+
|
|
72
|
+
Style/OneClassPerFile:
|
|
73
|
+
inherit_mode:
|
|
74
|
+
merge:
|
|
75
|
+
- Exclude
|
|
76
|
+
Exclude:
|
|
77
|
+
- "**/*.md"
|
|
78
|
+
|
|
79
|
+
Style/Documentation:
|
|
80
|
+
inherit_mode:
|
|
81
|
+
merge:
|
|
82
|
+
- Exclude
|
|
83
|
+
Exclude:
|
|
84
|
+
- "**/*.md"
|
|
6
85
|
|
|
7
|
-
|
|
86
|
+
Lint/UselessAssignment:
|
|
87
|
+
inherit_mode:
|
|
88
|
+
merge:
|
|
89
|
+
- Exclude
|
|
90
|
+
Exclude:
|
|
91
|
+
- "**/*.md"
|
|
92
|
+
|
|
93
|
+
Style/MultilineBlockChain:
|
|
94
|
+
inherit_mode:
|
|
95
|
+
merge:
|
|
96
|
+
- Exclude
|
|
97
|
+
Exclude:
|
|
98
|
+
- "**/*.md"
|
|
99
|
+
|
|
100
|
+
Style/SymbolProc:
|
|
101
|
+
inherit_mode:
|
|
102
|
+
merge:
|
|
103
|
+
- Exclude
|
|
104
|
+
Exclude:
|
|
105
|
+
- "**/*.md"
|
|
106
|
+
|
|
107
|
+
Lint/Void:
|
|
108
|
+
inherit_mode:
|
|
109
|
+
merge:
|
|
110
|
+
- Exclude
|
|
111
|
+
Exclude:
|
|
112
|
+
- "**/*.md"
|
|
113
|
+
|
|
114
|
+
Metrics/BlockLength:
|
|
115
|
+
inherit_mode:
|
|
116
|
+
merge:
|
|
117
|
+
- Exclude
|
|
118
|
+
Exclude:
|
|
119
|
+
- spec/release/release_spec.rb
|
|
120
|
+
- Gemfile
|
|
121
|
+
|
|
122
|
+
Layout/LineLength:
|
|
123
|
+
inherit_mode:
|
|
124
|
+
merge:
|
|
125
|
+
- Exclude
|
|
126
|
+
Exclude:
|
|
127
|
+
- ".github/workflows/*.yml"
|
|
128
|
+
|
|
129
|
+
Markdown/HeadingCapitalization:
|
|
130
|
+
Enabled: true
|
|
131
|
+
Style: title_case
|
|
132
|
+
|
|
133
|
+
Prose/MaxLength:
|
|
134
|
+
Max: false
|
|
135
|
+
Exclude:
|
|
136
|
+
- LICENSE.md
|
|
137
|
+
|
|
138
|
+
Spellcheck:
|
|
139
|
+
DictionaryFiles:
|
|
140
|
+
en:
|
|
141
|
+
- gem:rubocop-spellcheck/data/en/en.dic
|
|
142
|
+
- ".spellcheck.txt"
|
|
143
|
+
|
|
144
|
+
Spellcheck/Spelling:
|
|
145
|
+
Exclude:
|
|
146
|
+
- LICENSE.md
|