iron_oxide 0.0.1 → 0.0.3

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: 689ead17e28d9c0bf0b7b70d8f607ad8cfb838937159568b13b8acc0c832de5b
4
- data.tar.gz: 243c1f6494cf34f30a251792501f3cddb89512a290ca1a4a9db1d8cd096446cc
3
+ metadata.gz: c8cc37a56001f57c84184d8fc493ef41297560a71d3e6721b1df9fccca6e4390
4
+ data.tar.gz: 359d8b8fe95b6647460b4fded5bf27ed4a63d85f229affb5b225fa9cef312fe7
5
5
  SHA512:
6
- metadata.gz: 5f931fa4c52470ac1b74d473337940e5a19c13fe496f061d62bb54fa26949a6dc36b25577c1ce6e497cba4b84355f89be2351e50ebf2e3ac675035e7a8e51065
7
- data.tar.gz: 21a8a63cc77150ad9b812a2add7e81ff4aad80c069951bc8c326bea3c28565fe761cec3c035a8f98089194dd0f1051524ba96e5e9deacf3c55fd6d0c9162035a
6
+ metadata.gz: 55304e8bf2b492a6e0acaa59fc64efdafd967aa29068dccc04709bed9bca4c3d4058969c17d872b7041c6cca9e8e65e517389734d260ff8048d53b83e0ec7cd3
7
+ data.tar.gz: 6e430deaf2d6ebb0e2e6a107ea5fe0221e16425cfd8ec692bbf8a74a29819dcab49e2a12e526829bbd94d34fa21695fb81b3c3b650e38b79e624ffc498c9db41
data/.github/FUNDING.yml CHANGED
@@ -1,4 +1,4 @@
1
1
  # These are supported funding model platforms
2
2
  ---
3
3
  github: [fnando]
4
- custom: ["https://paypal.me/[USER]/🍕"]
4
+ custom: ["https://paypal.me/nandovieira/🍕"]
@@ -24,9 +24,9 @@ jobs:
24
24
  - Gemfile
25
25
 
26
26
  steps:
27
- - uses: actions/checkout@v1
27
+ - uses: actions/checkout@v4
28
28
 
29
- - uses: actions/cache@v2
29
+ - uses: actions/cache@v4
30
30
  with:
31
31
  path: vendor/bundle
32
32
  key: >
data/CHANGELOG.md CHANGED
@@ -11,6 +11,14 @@ Prefix your message with one of the following:
11
11
  - [Security] in case of vulnerabilities.
12
12
  -->
13
13
 
14
+ ## 0.0.3
15
+
16
+ [Fixed] Constant override warning.
17
+
18
+ ## 0.0.2
19
+
20
+ - [Added] Pattern matching support.
21
+
14
22
  ## 0.0.1
15
23
 
16
24
  - Initial release.
@@ -2,12 +2,15 @@
2
2
 
3
3
  module IronOxide
4
4
  module Aliases
5
+ Some = Option::SomeClass
6
+ Ok = Result::OkClass
7
+ Err = Result::ErrClass
8
+ None = Option::None
9
+
5
10
  def Some(value) # rubocop:disable Naming/MethodName
6
11
  Option::Some(value)
7
12
  end
8
13
 
9
- None = Option::None
10
-
11
14
  def Ok(value) # rubocop:disable Naming/MethodName
12
15
  Result::Ok(value)
13
16
  end
@@ -5,6 +5,15 @@ module IronOxide
5
5
  class Base
6
6
  attr_reader :value
7
7
 
8
+ # Deconstructs the instance into an array.
9
+ def deconstruct
10
+ [value]
11
+ end
12
+
13
+ def deconstruct_keys(*)
14
+ {value:}
15
+ end
16
+
8
17
  # Checks if the instance represents a `Some` value.
9
18
  def some?
10
19
  instance_of?(SomeClass)
@@ -9,6 +9,18 @@ module IronOxide
9
9
  @value = value
10
10
  end
11
11
 
12
+ # Deconstructs the instance into an array, so it can be using on
13
+ # pattern matching.
14
+ def deconstruct
15
+ [value]
16
+ end
17
+
18
+ # Deconstructs the instance into a hash, so it can be using on
19
+ # pattern matching.
20
+ def deconstruct_keys(*)
21
+ {value:}
22
+ end
23
+
12
24
  # Compares the current result with another result.
13
25
  def ==(other)
14
26
  Result.result?(other) &&
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module IronOxide
4
- VERSION = "0.0.1"
4
+ VERSION = "0.0.3"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: iron_oxide
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nando Vieira
@@ -147,10 +147,10 @@ metadata:
147
147
  rubygems_mfa_required: 'true'
148
148
  homepage_uri: https://github.com/fnando/iron_oxide
149
149
  bug_tracker_uri: https://github.com/fnando/iron_oxide/issues
150
- source_code_uri: https://github.com/fnando/iron_oxide/tree/v0.0.1
151
- changelog_uri: https://github.com/fnando/iron_oxide/tree/v0.0.1/CHANGELOG.md
152
- documentation_uri: https://github.com/fnando/iron_oxide/tree/v0.0.1/README.md
153
- license_uri: https://github.com/fnando/iron_oxide/tree/v0.0.1/LICENSE.md
150
+ source_code_uri: https://github.com/fnando/iron_oxide/tree/v0.0.3
151
+ changelog_uri: https://github.com/fnando/iron_oxide/tree/v0.0.3/CHANGELOG.md
152
+ documentation_uri: https://github.com/fnando/iron_oxide/tree/v0.0.3/README.md
153
+ license_uri: https://github.com/fnando/iron_oxide/tree/v0.0.3/LICENSE.md
154
154
  post_install_message:
155
155
  rdoc_options: []
156
156
  require_paths: