invar 0.9.1 → 0.9.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 2346259fc26689ffca5386f39e982de60dc9f2d9c03399f85023e05a47802f7a
4
- data.tar.gz: b6e2cea0c52fd0b52eb833036844c03d3a714d83e0572dc5dcbb4ae083c61cf7
3
+ metadata.gz: de219e48de87431ca272889fc21eed52ad9bc91a9034bb08f284881f5f3eddf9
4
+ data.tar.gz: c7a291babaf371130c98fd0cb77e11ab4468903cffef66727d1043eb7eef7f78
5
5
  SHA512:
6
- metadata.gz: 1a9556b30d2c17fda9373551ecf6fffeaacabd35aa0e40bb883c78e8bd94642bf4bebbeea054b5f9a9681b0bb23b6ee8c30860afb732f94b9d7887e62e0c0c47
7
- data.tar.gz: a80954a8dbfc4c42d3f57b94cb2830a8e598eda85cd95f37ff431a1ab2b253fa64d4c65f9aacba8cfa718f5b5f1082b05f78c0d1f97d2ae7bc58b4392c4e19f0
6
+ metadata.gz: f273a02beda6a3485092f4ec8495834fa166788502f7a73cf4f1c95bf7c281c51c7db18fd2b2eeb447de34664e36dd876a2b96ca2c04c0ccbd98f36eebe0ff12
7
+ data.tar.gz: 6acfd6d89b8ff8fdf7f94f5b1ca4995774d0fddbac7a6e6bd46752d4b84861da6096d91110d58d6315423a37d180b3c7d5e284d93dd3a3892eb81d8c3524a68e
data/.rubocop.yml CHANGED
@@ -1,5 +1,10 @@
1
1
  inherit_from: ~/.config/rubocop/config.yml
2
2
 
3
+ require:
4
+ - rubocop-performance
5
+ - rubocop-rspec
6
+ - rubocop-rake
7
+
3
8
  AllCops:
4
9
  Exclude:
5
10
  - 'bin/*'
@@ -12,3 +17,20 @@ Metrics/BlockLength:
12
17
  Metrics/ModuleLength:
13
18
  Exclude:
14
19
  - 'spec/**/*.rb'
20
+
21
+ RSpec/ExampleWording:
22
+ Enabled: false
23
+
24
+ RSpec/ExampleLength:
25
+ CountAsOne:
26
+ - array
27
+ - hash
28
+ - heredoc
29
+ - method_call
30
+
31
+ RSpec/NotToNot:
32
+ Enabled: false
33
+
34
+ # TODO: remove this restriction
35
+ RSpec/MultipleMemoizedHelpers:
36
+ Enabled: false
data/.ruby-version CHANGED
@@ -1 +1 @@
1
- ruby-3.1.4
1
+ ruby-3.3.0
data/Gemfile CHANGED
@@ -7,14 +7,16 @@ gemspec
7
7
 
8
8
  group :development do
9
9
  gem 'bundler', '~> 2.3'
10
- gem 'rake', '~> 13.0'
11
- gem 'rubocop', '~> 1.56'
12
- gem 'rubocop-performance', '~> 1.19'
10
+ gem 'rake', '~> 13.1'
11
+ gem 'rubocop', '~> 1.61'
12
+ gem 'rubocop-performance', '~> 1.20'
13
+ gem 'rubocop-rake', '~> 0.6'
14
+ gem 'rubocop-rspec', '~> 2.27'
13
15
  gem 'yard', '~> 0.9'
14
16
  end
15
17
 
16
18
  group :test do
17
- gem 'fakefs', '~> 2.5'
18
- gem 'rspec', '~> 3.12'
19
+ gem 'climate_control', '~> 1.2'
20
+ gem 'rspec', '~> 3.13'
19
21
  gem 'simplecov', '~> 0.22'
20
22
  end
data/RELEASE_NOTES.md CHANGED
@@ -19,6 +19,20 @@ to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
19
19
 
20
20
  * none
21
21
 
22
+ ## [0.9.2] - 2024-03-03
23
+
24
+ ### Major Changes
25
+
26
+ * none
27
+
28
+ ### Minor Changes
29
+
30
+ * none
31
+
32
+ ### Bugfixes
33
+
34
+ * Fixed load error in ruby 3.3 of not properly requiring Forwardable
35
+
22
36
  ## [0.9.1] - 2023-09-30
23
37
 
24
38
  ### Major Changes
@@ -3,13 +3,14 @@
3
3
  require 'invar/version'
4
4
  require 'invar/scope'
5
5
 
6
- require 'delegate'
6
+ require 'forwardable'
7
7
 
8
8
  module Invar
9
9
  # Verifies a file is secure
10
10
  class PrivateFile
11
11
  extend Forwardable
12
- def_delegators :@delegate_sd_obj, :stat, :to_s, :basename, :dirname, :extname, :==, :chmod, :rename, :write
12
+ def_delegators :@delegate_sd_obj,
13
+ :stat, :to_s, :basename, :dirname, :extname, :==, :chmod, :rename, :write, :binwrite
13
14
 
14
15
  # Mask for limiting to the lowest three octal digits (which store permissions)
15
16
  PERMISSIONS_MASK = 0o777
@@ -82,8 +82,7 @@ module Invar
82
82
  encrypted_data = lockbox.encrypt(content)
83
83
 
84
84
  config_dir.mkpath
85
- # TODO: replace File.opens with photo_path.binwrite(uri.data) once FakeFS can handle it
86
- File.open(file_path.to_s, 'wb') { |f| f.write encrypted_data }
85
+ file_path.binwrite encrypted_data
87
86
  file_path.chmod permissions if permissions
88
87
 
89
88
  warn "Saved file: #{ file_path }"
data/lib/invar/scope.rb CHANGED
@@ -4,7 +4,7 @@ module Invar
4
4
  # A set of configurations
5
5
  class Scope
6
6
  def initialize(data = nil)
7
- @data = convert(data)
7
+ @data = convert data
8
8
 
9
9
  @data.freeze
10
10
  freeze
@@ -34,7 +34,7 @@ module Invar
34
34
  def respond_to_missing?(method_name, include_all)
35
35
  guard_test_methods method_name
36
36
 
37
- super method_name, include_all
37
+ super(method_name, include_all)
38
38
  end
39
39
 
40
40
  # Returns a hash representation of this scope and subscopes.
data/lib/invar/version.rb CHANGED
@@ -2,5 +2,5 @@
2
2
 
3
3
  module Invar
4
4
  # Current version of the gem
5
- VERSION = '0.9.1'
5
+ VERSION = '0.9.2'
6
6
  end
data/lib/invar.rb CHANGED
@@ -28,7 +28,7 @@ module Invar
28
28
  def respond_to_missing?(method_name, include_all)
29
29
  guard_test_hooks method_name
30
30
 
31
- super method_name, include_all
31
+ super(method_name, include_all)
32
32
  end
33
33
 
34
34
  private
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: invar
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.9.1
4
+ version: 0.9.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Robin Miller
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2023-09-30 00:00:00.000000000 Z
11
+ date: 2024-03-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: dry-schema
@@ -92,7 +92,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
92
92
  - !ruby/object:Gem::Version
93
93
  version: '0'
94
94
  requirements: []
95
- rubygems_version: 3.4.18
95
+ rubygems_version: 3.5.3
96
96
  signing_key:
97
97
  specification_version: 4
98
98
  summary: Single source of truth for environmental configuration.