gem-silencer 0.1.0 → 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: e026caf0bbb80c47e003dce6cbb3673111b1dbe34758b04b132df77215984bf9
4
- data.tar.gz: b5c0af92a6ca5aa0526781d374507cfa4cb5c33b146eb13f540a4d2f405ad270
3
+ metadata.gz: 4d8c09a51385e0138e7662069c4d4a6ddbc8c8af0a188f59291880eb674617ac
4
+ data.tar.gz: d835cbce63e2d20e181af67f627a46246f43919a3389d121ade8189bce0883f7
5
5
  SHA512:
6
- metadata.gz: 6765316f1827df072bdd83bff491adbf8265ee52af61461adfa497497138517aac0ddfc45d258d1eb17066992344796e4ca7c7ba6ab01074edb9330c44698331
7
- data.tar.gz: ee2ed37a1525c6ba412670c4ff786368d260ccde4b53e8445678dbe9fd54a502a2e064341aca60ae77e6134070c0a253c13d3401e7999c118799af438657b87f
6
+ metadata.gz: 1393457bbfc8eff9005dfba23637f999b22583da53714f3f2ca00888a64c3402b693344537d16b09015c586267b4aa0869f5136efdae2cad53e3ba942f1f5890
7
+ data.tar.gz: b3ef5bede8895caf60d95a8f05c0b094ca80df850c3556a3b8b586aa0eaabac5b3b2d0d594118d22b8fd051d836feb09552f86c5f5b6447ed219046c1dc42eaa
data/.idea/silencer.iml CHANGED
@@ -26,21 +26,21 @@
26
26
  <option name="myRootTask">
27
27
  <RakeTaskImpl id="rake">
28
28
  <subtasks>
29
- <RakeTaskImpl description="Build silencer-0.1.0.gem into the pkg directory" fullCommand="build" id="build" />
29
+ <RakeTaskImpl description="Build gem-silencer-0.1.0.gem into the pkg directory" fullCommand="build" id="build" />
30
30
  <RakeTaskImpl id="build">
31
31
  <subtasks>
32
- <RakeTaskImpl description="Generate SHA512 checksum of silencer-0.1.0.gem into the checksums directory" fullCommand="build:checksum" id="checksum" />
32
+ <RakeTaskImpl description="Generate SHA512 checksum of gem-silencer-0.1.0.gem into the checksums directory" fullCommand="build:checksum" id="checksum" />
33
33
  </subtasks>
34
34
  </RakeTaskImpl>
35
35
  <RakeTaskImpl description="Remove any temporary products" fullCommand="clean" id="clean" />
36
36
  <RakeTaskImpl description="Remove any generated files" fullCommand="clobber" id="clobber" />
37
- <RakeTaskImpl description="Build and install silencer-0.1.0.gem into system gems" fullCommand="install" id="install" />
37
+ <RakeTaskImpl description="Build and install gem-silencer-0.1.0.gem into system gems" fullCommand="install" id="install" />
38
38
  <RakeTaskImpl id="install">
39
39
  <subtasks>
40
- <RakeTaskImpl description="Build and install silencer-0.1.0.gem into system gems without network access" fullCommand="install:local" id="local" />
40
+ <RakeTaskImpl description="Build and install gem-silencer-0.1.0.gem into system gems without network access" fullCommand="install:local" id="local" />
41
41
  </subtasks>
42
42
  </RakeTaskImpl>
43
- <RakeTaskImpl description="Create tag v0.1.0 and build and push silencer-0.1.0.gem to TODO: Set to your gem server 'https://example.com'" fullCommand="release[remote]" id="release[remote]" />
43
+ <RakeTaskImpl description="Create tag v0.1.0 and build and push gem-silencer-0.1.0.gem to rubygems.org" fullCommand="release[remote]" id="release[remote]" />
44
44
  <RakeTaskImpl description="Run RSpec code examples" fullCommand="spec" id="spec" />
45
45
  <RakeTaskImpl description="" fullCommand="default" id="default" />
46
46
  <RakeTaskImpl description="" fullCommand="release" id="release" />
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Silencer
4
- VERSION = '0.1.0'
4
+ VERSION = '0.3.0'
5
5
  end
data/lib/silencer.rb CHANGED
@@ -12,7 +12,7 @@ module Silencer
12
12
  end
13
13
 
14
14
  def self.ignore_warnings(file = '.silencer.yml')
15
- YAML.load_file(file).each do |name, attrs|
15
+ YAML.load_file(config_file_path(file)).each do |name, attrs|
16
16
  version = attrs['version']
17
17
  spec = Gem::Specification.find_by_name(name)
18
18
  raise Error.new(name, version, spec.version.to_s) unless version == spec.version.to_s
@@ -21,4 +21,12 @@ module Silencer
21
21
  end
22
22
  end
23
23
  end
24
+
25
+ def self.config_file_path(file)
26
+ if defined? ::Bundler
27
+ ::Bundler.root.join(file).to_s
28
+ else
29
+ file
30
+ end
31
+ end
24
32
  end
data/sig/silencer.rbs CHANGED
@@ -1,5 +1,6 @@
1
1
  module Silencer
2
2
  VERSION: String
3
3
  # See the writing guide of rbs: https://github.com/ruby/rbs#guides
4
+ def self.config_file_path: -> String
4
5
  def self.ignore_warnings: -> untyped
5
6
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gem-silencer
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Hamed Asghari
8
8
  bindir: exe
9
9
  cert_chain: []
10
- date: 2025-02-06 00:00:00.000000000 Z
10
+ date: 2025-02-09 00:00:00.000000000 Z
11
11
  dependencies:
12
12
  - !ruby/object:Gem::Dependency
13
13
  name: warning