standard-thread_safety 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: a0a5e853fbd31b7cd119503f211915b7f7c24ae813cc827786146e5ded6d826e
4
+ data.tar.gz: 74807ebe7a0e612728f0de9ca0cd319796a55143066797331d3d3953ed1c57aa
5
+ SHA512:
6
+ metadata.gz: 1a96c517551b14686884602a11c6d32080c660114f961f470b5d92bd0e14b13151ebeab4f0ecfe7c4b0b2fe72eb805f19a3bc52f0251c4ffcb84aca5159bd2c2
7
+ data.tar.gz: fece699bc66611eb53880a7707bfd4399e82c510603dcbe44d58c58a4a709115489c6c1e413b5434b3a83b8f24783700b25c53da5185097276d29311b33218be
data/CHANGELOG.md ADDED
@@ -0,0 +1,5 @@
1
+ ## [Unreleased]
2
+
3
+ ## [1.0.0]
4
+
5
+ - Initial release
data/Gemfile ADDED
@@ -0,0 +1,3 @@
1
+ source "https://rubygems.org"
2
+
3
+ gemspec
data/Gemfile.lock ADDED
@@ -0,0 +1,45 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ standard-thread_safety (1.0.0)
5
+ lint_roller (~> 1.0)
6
+ rubocop-thread_safety
7
+
8
+ GEM
9
+ remote: https://rubygems.org/
10
+ specs:
11
+ ast (2.4.2)
12
+ json (2.6.3)
13
+ lint_roller (1.0.0)
14
+ parallel (1.23.0)
15
+ parser (3.2.2.1)
16
+ ast (~> 2.4.1)
17
+ rainbow (3.1.1)
18
+ regexp_parser (2.8.0)
19
+ rexml (3.2.5)
20
+ rubocop (1.51.0)
21
+ json (~> 2.3)
22
+ parallel (~> 1.10)
23
+ parser (>= 3.2.0.0)
24
+ rainbow (>= 2.2.2, < 4.0)
25
+ regexp_parser (>= 1.8, < 3.0)
26
+ rexml (>= 3.2.5, < 4.0)
27
+ rubocop-ast (>= 1.28.0, < 2.0)
28
+ ruby-progressbar (~> 1.7)
29
+ unicode-display_width (>= 2.4.0, < 3.0)
30
+ rubocop-ast (1.28.1)
31
+ parser (>= 3.2.1.0)
32
+ rubocop-thread_safety (0.5.1)
33
+ rubocop (>= 0.90.0)
34
+ ruby-progressbar (1.13.0)
35
+ unicode-display_width (2.4.2)
36
+
37
+ PLATFORMS
38
+ arm64-darwin-22
39
+ x86_64-linux
40
+
41
+ DEPENDENCIES
42
+ standard-thread_safety!
43
+
44
+ BUNDLED WITH
45
+ 2.4.8
data/MIT-LICENSE ADDED
@@ -0,0 +1,20 @@
1
+ Copyright 2023 Kirill Platonov
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining
4
+ a copy of this software and associated documentation files (the
5
+ "Software"), to deal in the Software without restriction, including
6
+ without limitation the rights to use, copy, modify, merge, publish,
7
+ distribute, sublicense, and/or sell copies of the Software, and to
8
+ permit persons to whom the Software is furnished to do so, subject to
9
+ the following conditions:
10
+
11
+ The above copyright notice and this permission notice shall be
12
+ included in all copies or substantial portions of the Software.
13
+
14
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
15
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
17
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
18
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
19
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,22 @@
1
+ # standard-thread_safety
2
+
3
+ This gem provides a [lint_roller](https://github.com/standardrb/lint_roller)
4
+ plugin configuration for the
5
+ [rubocop-thread_safety](https://github.com/rubocop/rubocop-thread_safety) ruleset, for use
6
+ as an extension to the [Standard Ruby
7
+ gem](https://github.com/standardrb/standard).
8
+
9
+ To install it, you'll want to start by adding it to your Gemfile:
10
+
11
+ ```ruby
12
+ gem "standard-thread_safety"
13
+ ```
14
+
15
+ ## Configuration
16
+
17
+ In your `.standard.yml` file, you can simply list `standard-thread_safety` as a plugin:
18
+
19
+ ```yaml
20
+ plugins:
21
+ - standard-thread_safety
22
+ ```
data/config/base.yml ADDED
@@ -0,0 +1,10 @@
1
+ inherit_mode:
2
+ merge:
3
+ - Exclude
4
+
5
+ require:
6
+ - rubocop-thread_safety
7
+
8
+ ThreadSafety/MutableClassInstanceVariable:
9
+ Exclude:
10
+ - test/**/*.rb
@@ -0,0 +1,28 @@
1
+ module Standard::ThreadSafety
2
+ class Plugin < LintRoller::Plugin
3
+ def initialize(config)
4
+ @config = config
5
+ end
6
+
7
+ def about
8
+ LintRoller::About.new(
9
+ name: "standard-thread_safety",
10
+ version: VERSION,
11
+ homepage: "https://github.com/kirillplatonov/standard-thread_safety",
12
+ description: "Configuration for rubocop-thread_safety rules"
13
+ )
14
+ end
15
+
16
+ def supported?(context)
17
+ true
18
+ end
19
+
20
+ def rules(context)
21
+ LintRoller::Rules.new(
22
+ type: :path,
23
+ config_format: :rubocop,
24
+ value: Pathname.new(__dir__).join("../../../config/base.yml")
25
+ )
26
+ end
27
+ end
28
+ end
@@ -0,0 +1,5 @@
1
+ module Standard
2
+ module ThreadSafety
3
+ VERSION = "1.0.0"
4
+ end
5
+ end
@@ -0,0 +1,9 @@
1
+ require "lint_roller"
2
+
3
+ require_relative "thread_safety/version"
4
+ require_relative "thread_safety/plugin"
5
+
6
+ module Standard
7
+ module ThreadSafety
8
+ end
9
+ end
@@ -0,0 +1 @@
1
+ require_relative "standard/thread_safety"
@@ -0,0 +1,34 @@
1
+ require_relative "lib/standard/thread_safety/version"
2
+
3
+ Gem::Specification.new do |spec|
4
+ spec.name = "standard-thread_safety"
5
+ spec.version = Standard::ThreadSafety::VERSION
6
+ spec.authors = ["Kirill Platonov"]
7
+ spec.email = ["mail@kirillplatonov.com"]
8
+
9
+ spec.summary = "A Standard Ruby plugin that configures rubocop-thread_safety"
10
+ spec.homepage = "https://github.com/kirillplatonov/standard-thread_safety"
11
+ spec.license = "MIT"
12
+ spec.required_ruby_version = ">= 2.7.0"
13
+
14
+ spec.metadata["homepage_uri"] = spec.homepage
15
+ spec.metadata["source_code_uri"] = spec.homepage
16
+ spec.metadata["changelog_uri"] = "#{spec.homepage}/blob/main/CHANGELOG.md"
17
+ spec.metadata["rubygems_mfa_required"] = "true"
18
+
19
+ spec.metadata["default_lint_roller_plugin"] = "Standard::ThreadSafety::Plugin"
20
+
21
+ # Specify which files should be added to the gem when it is released.
22
+ # The `git ls-files -z` loads the files in the RubyGem that have been added into git.
23
+ spec.files = Dir.chdir(__dir__) do
24
+ `git ls-files -z`.split("\x0").reject do |f|
25
+ (File.expand_path(f) == __FILE__) || f.start_with?(*%w[bin/ test/ spec/ features/ .git .circleci appveyor])
26
+ end
27
+ end
28
+ spec.bindir = "exe"
29
+ spec.executables = spec.files.grep(%r{\Aexe/}) { |f| File.basename(f) }
30
+ spec.require_paths = ["lib"]
31
+
32
+ spec.add_dependency "lint_roller", "~> 1.0"
33
+ spec.add_dependency "rubocop-thread_safety"
34
+ end
metadata ADDED
@@ -0,0 +1,87 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: standard-thread_safety
3
+ version: !ruby/object:Gem::Version
4
+ version: 1.0.0
5
+ platform: ruby
6
+ authors:
7
+ - Kirill Platonov
8
+ autorequire:
9
+ bindir: exe
10
+ cert_chain: []
11
+ date: 2023-05-23 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: lint_roller
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '1.0'
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '1.0'
27
+ - !ruby/object:Gem::Dependency
28
+ name: rubocop-thread_safety
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ">="
32
+ - !ruby/object:Gem::Version
33
+ version: '0'
34
+ type: :runtime
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - ">="
39
+ - !ruby/object:Gem::Version
40
+ version: '0'
41
+ description:
42
+ email:
43
+ - mail@kirillplatonov.com
44
+ executables: []
45
+ extensions: []
46
+ extra_rdoc_files: []
47
+ files:
48
+ - CHANGELOG.md
49
+ - Gemfile
50
+ - Gemfile.lock
51
+ - MIT-LICENSE
52
+ - README.md
53
+ - config/base.yml
54
+ - lib/standard-thread_safety.rb
55
+ - lib/standard/thread_safety.rb
56
+ - lib/standard/thread_safety/plugin.rb
57
+ - lib/standard/thread_safety/version.rb
58
+ - standard-thread_safety.gemspec
59
+ homepage: https://github.com/kirillplatonov/standard-thread_safety
60
+ licenses:
61
+ - MIT
62
+ metadata:
63
+ homepage_uri: https://github.com/kirillplatonov/standard-thread_safety
64
+ source_code_uri: https://github.com/kirillplatonov/standard-thread_safety
65
+ changelog_uri: https://github.com/kirillplatonov/standard-thread_safety/blob/main/CHANGELOG.md
66
+ rubygems_mfa_required: 'true'
67
+ default_lint_roller_plugin: Standard::ThreadSafety::Plugin
68
+ post_install_message:
69
+ rdoc_options: []
70
+ require_paths:
71
+ - lib
72
+ required_ruby_version: !ruby/object:Gem::Requirement
73
+ requirements:
74
+ - - ">="
75
+ - !ruby/object:Gem::Version
76
+ version: 2.7.0
77
+ required_rubygems_version: !ruby/object:Gem::Requirement
78
+ requirements:
79
+ - - ">="
80
+ - !ruby/object:Gem::Version
81
+ version: '0'
82
+ requirements: []
83
+ rubygems_version: 3.4.6
84
+ signing_key:
85
+ specification_version: 4
86
+ summary: A Standard Ruby plugin that configures rubocop-thread_safety
87
+ test_files: []