nerd_dice 0.4.1 → 0.5.1

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: 2652443ce77d0c00ceb8ec2cb15151d7b03a15bba2ad592c44bb3f080f2e613c
4
- data.tar.gz: 1c91a3545d42ce5d5627ddb87169a05316cff352e4931e4b6970f92e2c17e98a
3
+ metadata.gz: 6e6e1993a7ddd4782146fdb532f44983eb8d67c71a71740c7b10a2a7d943a8a4
4
+ data.tar.gz: cc708f79a5fcd24024112802beb58cd0701677df7f5fceaf5be24008570d5fbf
5
5
  SHA512:
6
- metadata.gz: 39909d95757e9ebf2fa6848e87350a09aeb3b00ee8791aecc50ae083b5e541b2f6426a7a5e280c530a594f6b39179a6f32e70ba053817115992608ee205f662d
7
- data.tar.gz: b6fd6502fb2a5beb79d6367f71b7039800138edc4d366e8b6e05030acf56875a37f2124ebc18eab08e9575cb232eb07b15f5d6528ad49c55dd7b997525343f36
6
+ metadata.gz: aa4194ee43ce436d055a72cf40c4f88abefb503025e0ea368f2fd9cfaf069373c4ff9abe36d8e0309ab4fdfed942998c72ac5425ac231792fae28cfebc3dab93
7
+ data.tar.gz: a1d4ebea184f994f02206665f7b77223a9a0c2c199cf637147ecb2da71f30b62067328e5c660e5fb9692a75f146546af4d893262c7c234309f91657ed5385cc8
checksums.yaml.gz.sig CHANGED
Binary file
@@ -14,7 +14,7 @@ jobs:
14
14
  runs-on: ubuntu-latest
15
15
  strategy:
16
16
  matrix:
17
- ruby-version: ['3.0', '3.1', '3.2']
17
+ ruby-version: ['3.0', '3.1', '3.2', '3.3']
18
18
 
19
19
  steps:
20
20
  - uses: actions/checkout@v2
data/.rubocop.yml CHANGED
@@ -12,7 +12,7 @@ require:
12
12
  - rubocop-rspec
13
13
 
14
14
  AllCops:
15
- TargetRubyVersion: 2.7
15
+ TargetRubyVersion: 3.0
16
16
  # RuboCop has a bunch of cops enabled by default. This setting tells RuboCop
17
17
  # to ignore them, so only the ones explicitly set in this file are enabled.
18
18
  #DisabledByDefault: true
@@ -166,6 +166,9 @@ Metrics/BlockLength:
166
166
  - 'spec/**/*.rb'
167
167
  - 'nerd_dice.gemspec'
168
168
 
169
+ Gemspec/DevelopmentDependencies:
170
+ EnforcedStyle: gemspec
171
+
169
172
  Lint/ErbNewArguments:
170
173
  Enabled: true
171
174
 
data/CONTRIBUTING.md ADDED
@@ -0,0 +1,108 @@
1
+ # Contributing to the NerdDice Project
2
+
3
+ Thank you for visiting the NerdDice repository and for taking interest in collaborating on the project. The primary goal of this project is educational: we want to teach people how to code with [Ruby](https://www.ruby-lang.org/en/). This is a published gem on [RubyGems](https://rubygems.org/gems/nerd_dice) and can be used in other projects using the instructions outlined in the [README](README.md#installation).
4
+
5
+ <a name="before-you-start"></a>
6
+ ## Before you start...
7
+ Everything in this repository is intended to be made freely available via the [UNLICENSE](UNLICENSE.txt) and the [Creative Commons](https://creativecommons.org) [CC0 Public Domain Dedication](https://creativecommons.org/publicdomain/zero/1.0/). You can obviously submit feature requests and issues and participate in the discussions, but we can\'t accept anything into this repository and project unless you agree to make it available under the terms above. See the [legal](README.md#legal) section in the README for more information.
8
+
9
+ ### Coding Videos
10
+ We make [coding videos](https://youtube.com/playlist?list=PL9kkbu1kLUeOnUtMpAnJOCtHdThx1Efkt) on our [YouTube channel](https://www.youtube.com/statelesscode) for the end-to-end of this project. If you collaborate on this project, you are consenting to potentially have the interaction featured in our videos. There is no guarantee or obligation to include your contribution or interaction in our videos, and we reserve the right to moderate inappropriate content at our own discretion.
11
+
12
+ ## Ways to Contribute
13
+ There are numerous ways to contribute to this project, irrespective of your level of technical expertise. We\'ll flesh out the details and guidelines for each way to contribute below
14
+
15
+ - **[Feature requests](#feature-requests)**
16
+ - **[Bug reports](#bug-reports)**
17
+ - **[Code contributions](#code-contributions)**
18
+ - **[Documentation contributions](#documentation-contributions)**
19
+ - **[Art, design and creative input](#art-design-creative-input)**
20
+
21
+ <a name="feature-requests"></a>
22
+ ### Feature requests
23
+ If you have an idea for a feature you would like to see in the NerdDice gem, feel free to [open an issue](https://github.com/statelesscode/nerd_dice/issues) in this GitHub repository. As an agile project, we strive to provide value. The better you can articulate your idea and the value it would bring to you as a user of the gem or including in your own project, it will help us determine whether or how to prioritize the idea.
24
+
25
+ Once an issue is submitted, we will likely need to discuss and clarify the feature request via comments to refine and clarify the intent, scope, and value of the feature. Precisely articulating your original feature request will help reduce the back-and-forth necessary to evaluate the story for implementation.
26
+
27
+ We can\'t guarantee that your feature request will be implemented or featured in a video, but truly welcome the collaboration and feedback of all who take interest.
28
+
29
+ <a name="bug-reports"></a>
30
+ ### Bug reports
31
+ The distinction between a feature and a bug can sometimes be murky. While a feature generally refers to a request for new functionality, a bug is related to existing functionality that is not working as intended. In order to better evaluate the bug for a fix, it is extremely helpful to follow the following format:
32
+ #### Expected behavior
33
+ How you as a user or a technical evaluator would expect the application to behave. Expectation is obviously subjective, but defining your expectations as a user can help to expose usability problems with the application. If you discover a bug, we warmly welcome you to [open an issue](https://github.com/statelesscode/nerd_dice/issues) in this GitHub repository unless it is a [security bug](#security-bugs) that could be exploited and is not suitable for public collaboration.
34
+
35
+ **Examples:**
36
+ - When I use the `roll_` convenience method with `plus` and `minus` I expect it to error out.
37
+ - When I configure a randomization technique I expect that the configuration will persist until I change it or stop the Ruby interpreter
38
+ - When I roll a 6-sided die, I expect to get a number between 1 and 6, inclusive
39
+
40
+ #### Actual behavior
41
+ The actual behavior is what really happens when you try to use your feature in a way that defies your expectations. Using the same examples listed above, you can see how this might work.
42
+
43
+ **Examples:**
44
+ - The method doesn't error out and uses the plus but not the minus
45
+ - The configuration always reverts the randomization technique to `:secure_random`
46
+ - I sometimes get a 0 and I never get a 6
47
+
48
+ #### Steps to reproduce
49
+ In order to properly fix the bug, it needs to be reproducible. The more detailed and precise your steps to reproduce are, the more likely it will be that we come to the right solution in fixing the bug. Sometimes a bug will only manifest if an exact sequence of events takes place. The more complex an application gets, the harder it becomes to isolate and diagnose the root cause. An example of steps to reproduce the first problem can look something like this.
50
+ - Include the gem in the `Gemfile` and run `bundle install`
51
+ - Open the `Pry` console
52
+ - Execute the following commands
53
+ ```ruby
54
+ o = Object.new
55
+ o.roll_2d8.harvest_totals
56
+ ```
57
+ - A `NoMethodError` is raised
58
+
59
+ In this case the `NoMethodError` is caused by improper usage of the `harvest_totals` method, but providing specifics about what you are trying to do and what you expect to have happen can result in better clarity of documentation or a new feature.
60
+
61
+ <a name="security-bugs"></a>
62
+ #### Security bugs
63
+ If you discover a security vulnerability in the application that can be exploited, please follow our [security reporting process](SECURITY.md) instead of submitting a public issue.
64
+
65
+ <a name="code-contributions"></a>
66
+ ### Code contributions
67
+ At Stateless Code our motto is \"Code Along\" and we mean it. If you have a feature that you want to implement yourself and contribute to the project, or you see an item in the [project backlog](https://github.com/statelesscode/nerd_dice/projects/1) that you want to try and tackle yourself, you are encouraged to do so.
68
+ #### Open an issue, if applicable
69
+ If there's a brand new feature you want to propose, or you want to work on a backlog item that is not yet converted into an issue, you can [open an issue](https://github.com/statelesscode/nerd_dice/issues) in this GitHub repository as you would in the sections above.
70
+ #### Fork the repository
71
+ To work on your changes, you will want to [fork this repository](https://github.com/statelesscode/nerd_dice/fork) into a repo on your own account so you can work and iterate on your feature.
72
+ #### Develop the feature
73
+ After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
74
+
75
+ To install this gem onto your local machine, run `bundle exec rake install`.
76
+
77
+ Once you have forked the repo, you can work to develop the contribution on your account. As you are working on your contribution you can commit as frequently as you'd like. \(We'll likely squash the commit down if and when it becomes time to merge the feature.\) In order to avoid rework, be sure to follow the [coding standards](#coding-standards) below. If the pull request is a candidate for merging, we will review the code and iterate on any feedback as needed.
78
+ <a name="coding-standards"></a>
79
+ #### Coding standards
80
+ Just like [Ruby on Rails](https://rubyonrails.org/) is able to increase programmer happiness by using convention over configuration, it\'s important to follow a consistent set of conventions throughout the code base to make it more consistent and maintainable. Some of these standards are just preferences while others \(like writing good tests\) are indispensable. If you feel strongly that one of these conventions should be modified and have good reasons to back it up, cordial conversation in an [issue](https://github.com/statelesscode/nerd_dice/issues) can be productive. I don\'t have all the answers and am constantly learning and evolving as a programmer myself. Just don\'t be a jerk about it.
81
+ ##### Always cover your code with good tests!
82
+ Whenever it\'s possible and feasible, we recommend using a test-driven development approach \(red, green, refactor\) . We have a video on [Why Test Driven Development](https://youtu.be/AGXfZP-EhKo) on our [YouTube channel](https://www.youtube.com/statelesscode) if you\'d like to learn more.
83
+ - Write your failing test
84
+ - Implement your change in the application code to make the test pass
85
+ - Refactor your code
86
+
87
+ Tests should be meaningful, failing without your code and passing only with your code. And the assertions you make about your code should be meaningful. **Covering code with a test that doesn\'t make meaningful assertions is worse than not covering your code at all.**
88
+
89
+ ##### Make sure the build will pass
90
+ Before your pull request can be merged, we need to make sure the GitHub Actions build will not fail. The following criteria must be met:
91
+ - `rubocop` needs to run without violations. If there is no way around a RuboCop violation, we can add disable-enable magic comments, but this should be seen as a last resort
92
+ - The test suite needs to pass. Running `rspec spec` from the root of the project will run the unit tests
93
+ - The code coverage can\'t decrease. This will cause the Coveralls check on the code to fail.
94
+ ##### Avoid cognitive complexity and giant methods
95
+ One of the common mottoes in the Ruby ecosystem is Don\'t Repeat Yourself \(DRY\). You want to write small, reusable methods for your code instead of giant thousand line monstrosities with if-else ladders and nested loops with more if-else ladders. Breaking your code down into bite sized chunks makes it more maintainable and less bug prone. It also allows you to write smaller, more-targeted unit tests. \"Working, but ugly\" is a common early iteration condition of a feature, but before we merge it to the main branch, we want our end goal to be elegant, expressive, concise code.
96
+ ##### Write a good commit message
97
+ When you\'re incrementally working on a story, it's fine to use the one-line `git commit -m "My commit message"` method of committing your code. When you squash it down at the end of the pull request, you want a good commit message for your contribution. There are many great resources on the internet about writing quality commit messages. [This one from cbeams](https://cbea.ms/git-commit/) is one of my favorites.
98
+ <a name="documentation-contributions"></a>
99
+ ### Documentation contributions
100
+ You don\'t need to be a programmer to contribute to the project! If you have suggestions for clarity on documentation for the project \(as small as fixing a typo or as big as setting up a Wiki category\) you are welcome to contribute. If you aren\'t interested in learning about GitHub, git, or the version control process, you can still [open an issue](https://github.com/statelesscode/nerd_dice/issues) in this GitHub repository and provide your content contributions there. Of course, if you are comfortable with the pull request process from the [code contributions](#code-contributions) section, you are welcome to do so. We just don\'t want that to be a barrier to entry.
101
+
102
+ <a name="art-design-creative-input"></a>
103
+ ### Art, design and creative input
104
+ If you have art, design, or other forms of creative input on the project that don\'t fit the above criteria, you can [open an issue](https://github.com/statelesscode/nerd_dice/issues) in this GitHub repository for that as well. As noted in the [Before you start...](#before-you-start) section, we can\'t accept any contributions unless you agree to match them to the repository standards of CC0 and/or the UNLICENSE.
105
+
106
+ <a name="guidelines-for-etiquette"></a>
107
+ ## Guidelines for etiquette
108
+ See the [Conduct](README.md#conduct) section in the README for more information.
data/Gemfile.lock CHANGED
@@ -1,65 +1,72 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- nerd_dice (0.4.1)
5
- securerandom (~> 0.2, >= 0.2.2)
4
+ nerd_dice (0.5.1)
5
+ securerandom (~> 0.3, >= 0.3.1)
6
6
 
7
7
  GEM
8
8
  remote: https://rubygems.org/
9
9
  specs:
10
10
  ast (2.4.2)
11
- coveralls_reborn (0.27.0)
11
+ coveralls_reborn (0.28.0)
12
12
  simplecov (~> 0.22.0)
13
13
  term-ansicolor (~> 1.7)
14
14
  thor (~> 1.2)
15
15
  tins (~> 1.32)
16
- diff-lcs (1.5.0)
16
+ diff-lcs (1.5.1)
17
17
  docile (1.4.0)
18
- json (2.6.3)
19
- parallel (1.22.1)
20
- parser (3.2.1.0)
18
+ json (2.7.1)
19
+ language_server-protocol (3.17.0.3)
20
+ parallel (1.24.0)
21
+ parser (3.3.0.5)
21
22
  ast (~> 2.4.1)
23
+ racc
24
+ racc (1.7.3)
22
25
  rainbow (3.1.1)
23
- rake (13.0.6)
24
- regexp_parser (2.7.0)
25
- rexml (3.2.5)
26
- rspec (3.12.0)
27
- rspec-core (~> 3.12.0)
28
- rspec-expectations (~> 3.12.0)
29
- rspec-mocks (~> 3.12.0)
30
- rspec-core (3.12.1)
31
- rspec-support (~> 3.12.0)
32
- rspec-expectations (3.12.2)
26
+ rake (13.1.0)
27
+ regexp_parser (2.9.0)
28
+ rexml (3.2.6)
29
+ rspec (3.13.0)
30
+ rspec-core (~> 3.13.0)
31
+ rspec-expectations (~> 3.13.0)
32
+ rspec-mocks (~> 3.13.0)
33
+ rspec-core (3.13.0)
34
+ rspec-support (~> 3.13.0)
35
+ rspec-expectations (3.13.0)
33
36
  diff-lcs (>= 1.2.0, < 2.0)
34
- rspec-support (~> 3.12.0)
35
- rspec-mocks (3.12.3)
37
+ rspec-support (~> 3.13.0)
38
+ rspec-mocks (3.13.0)
36
39
  diff-lcs (>= 1.2.0, < 2.0)
37
- rspec-support (~> 3.12.0)
38
- rspec-support (3.12.0)
39
- rubocop (1.46.0)
40
+ rspec-support (~> 3.13.0)
41
+ rspec-support (3.13.1)
42
+ rubocop (1.60.2)
40
43
  json (~> 2.3)
44
+ language_server-protocol (>= 3.17.0)
41
45
  parallel (~> 1.10)
42
- parser (>= 3.2.0.0)
46
+ parser (>= 3.3.0.2)
43
47
  rainbow (>= 2.2.2, < 4.0)
44
48
  regexp_parser (>= 1.8, < 3.0)
45
49
  rexml (>= 3.2.5, < 4.0)
46
- rubocop-ast (>= 1.26.0, < 2.0)
50
+ rubocop-ast (>= 1.30.0, < 2.0)
47
51
  ruby-progressbar (~> 1.7)
48
52
  unicode-display_width (>= 2.4.0, < 3.0)
49
- rubocop-ast (1.26.0)
53
+ rubocop-ast (1.30.0)
50
54
  parser (>= 3.2.1.0)
51
- rubocop-capybara (2.17.1)
55
+ rubocop-capybara (2.20.0)
52
56
  rubocop (~> 1.41)
53
- rubocop-performance (1.16.0)
54
- rubocop (>= 1.7.0, < 2.0)
55
- rubocop-ast (>= 0.4.0)
57
+ rubocop-factory_bot (2.25.1)
58
+ rubocop (~> 1.41)
59
+ rubocop-performance (1.20.2)
60
+ rubocop (>= 1.48.1, < 2.0)
61
+ rubocop-ast (>= 1.30.0, < 2.0)
56
62
  rubocop-rake (0.6.0)
57
63
  rubocop (~> 1.0)
58
- rubocop-rspec (2.18.1)
59
- rubocop (~> 1.33)
64
+ rubocop-rspec (2.26.1)
65
+ rubocop (~> 1.40)
60
66
  rubocop-capybara (~> 2.17)
61
- ruby-progressbar (1.11.0)
62
- securerandom (0.2.2)
67
+ rubocop-factory_bot (~> 2.22)
68
+ ruby-progressbar (1.13.0)
69
+ securerandom (0.3.1)
63
70
  simplecov (0.22.0)
64
71
  docile (~> 1.1)
65
72
  simplecov-html (~> 0.11)
@@ -70,23 +77,23 @@ GEM
70
77
  sync (0.5.0)
71
78
  term-ansicolor (1.7.1)
72
79
  tins (~> 1.0)
73
- thor (1.2.1)
80
+ thor (1.3.0)
74
81
  tins (1.32.1)
75
82
  sync
76
- unicode-display_width (2.4.2)
83
+ unicode-display_width (2.5.0)
77
84
 
78
85
  PLATFORMS
79
86
  ruby
80
87
 
81
88
  DEPENDENCIES
82
- coveralls_reborn (~> 0.27.0)
89
+ coveralls_reborn (~> 0.28.0)
83
90
  nerd_dice!
84
91
  rake (~> 13.0)
85
92
  rspec (~> 3.12)
86
- rubocop (~> 1.46, >= 1.46.0)
87
- rubocop-performance (~> 1.16, >= 1.16.0)
93
+ rubocop (~> 1.60, >= 1.60.2)
94
+ rubocop-performance (~> 1.20, >= 1.20.2)
88
95
  rubocop-rake (~> 0.6, >= 0.6.0)
89
- rubocop-rspec (~> 2.18, >= 2.18.1)
96
+ rubocop-rspec (~> 2.26, >= 2.26.1)
90
97
  simplecov-lcov (~> 0.8.0)
91
98
 
92
99
  BUNDLED WITH
data/README.md CHANGED
@@ -4,9 +4,11 @@
4
4
  # NerdDice
5
5
  Nerd dice allows you to roll polyhedral dice and add bonuses as you would in a tabletop roleplaying game. You can choose to roll multiple dice and keep a specified number of dice such as rolling 4d6 and dropping the lowest for ability scores or rolling with advantage and disadvantage if those mechanics exist in your game.
6
6
 
7
+ <a name="videos"></a>
7
8
  ## Educational Videos By Stateless Code
8
9
  The end-to-end process of developing this gem has been captured as [instructional videos](https://www.youtube.com/playlist?list=PL9kkbu1kLUeOnUtMpAnJOCtHdThx1Efkt). The videos are in a one-take style so that the mistakes along the way have troubleshooting and the concepts used to develop the gem are explained as they are covered.
9
10
 
11
+ <a name="installation"></a>
10
12
  ## Installation
11
13
 
12
14
  Add this line to your application's Gemfile:
@@ -23,6 +25,7 @@ Or install it yourself as:
23
25
 
24
26
  $ gem install nerd_dice
25
27
 
28
+ <a name="usage"></a>
26
29
  ## Usage
27
30
  After the gem is installed, you can require it as you would any other gem.
28
31
 
@@ -30,9 +33,11 @@ After the gem is installed, you can require it as you would any other gem.
30
33
  require 'nerd_dice'
31
34
  ```
32
35
 
36
+ <a name="module-methods-or-method-missing"></a>
33
37
  ### Module methods or a dynamic method_missing DSL
34
38
  There are two main patterns for using NerdDice in your project. You can invoke the module-level methods like `NerdDice.total_dice` or you can include the `NerdDice::ConvenienceMethods` module to your class \(or IRB \). Once mixed in, you can dynamically invoke methods like `roll_d20_with_advantage` or `total_3d8_plus5`. See the [Convenience Methods Mixin](#convenience-methods-mixin) section for usage details.
35
39
 
40
+ <a name="configuration"></a>
36
41
  ### Configuration
37
42
  You can customize the behavior of NerdDice via a configuration block as below or by assigning an individual property via the ```NerdDice.configuration.property = value``` syntax \(where ```property``` is the config property and ```value``` is the value you want to assign\)\. The available configuration options as well as their defaults, if applicable, are listed in the example configuration block below:
38
43
 
@@ -78,6 +83,7 @@ end
78
83
  ```
79
84
  **Note:** You cannot set `ability_score_dice_kept` greater than `ability_score_dice_rolled`. If you try to set `ability_score_dice_kept` higher than `ability_score_dice_rolled`, an error will be raised. If you set `ability_score_dice_rolled` _lower_ than the existing value of `ability_score_dice_kept`, no error will be thrown, but `ability_score_dice_kept` will be _**modified**_ to match `ability_score_dice_rolled` and a warning will be printed.
80
85
 
86
+ <a name="bonus"></a>
81
87
  ### Rolling a number of dice and adding a bonus
82
88
  You can use two different methods to roll dice. The `total_dice` method returns an `Integer` representing the total of the dice plus any applicable bonuses. The `total_dice` method does not support chaining additional methods like `highest`, `lowest`, `with_advantage`, `with_disadvantage`. The `roll_dice` method returns a `DiceSet` collection object, and allows for chaining the methods mentioned above and iterating over the individual `Die` objects. `NerdDice.roll_dice.total` and `NerdDice.total_dice` are roughly equivalent.
83
89
 
@@ -118,6 +124,7 @@ dice_set = NerdDice::DiceSet.new(6, 3, bonus: 2, randomization_technique: :rando
118
124
  damage_type: 'psychic', foreground_color: '#FFF', background_color: '#0FF')
119
125
 
120
126
  ```
127
+ <a name="available-options"></a>
121
128
  #### Available options for NerdDice::DiceSet objects
122
129
  There are a number of options that can be provided when initializing a `NerdDice::DiceSet` object after specifying the mandatory number of sides and the optional number of dice \(default: 1\). The list below provides the options and indicates whether they are cascaded to the Die objects in the collection.
123
130
  * `bonus` \(Duck-type Integer, _default: 0_\): Bonus or penalty to apply to the total after all dice are rolled. _**Not applied** to Die objects_
@@ -126,6 +133,7 @@ There are a number of options that can be provided when initializing a `NerdDice
126
133
  * `foreground_color` \(String, _default: `NerdDice.configuration.die_foreground_color`_\): Intended foreground color to apply to the dice in the `DiceSet`. Should be a valid CSS color but is not validated or enforced and doesn\'t currently have any real functionality associated with it. _**Applied** to Die objects by default with ability to modify_
127
134
  * `background_color` \(String, _default: `NerdDice.configuration.die_background_color`_\): Intended background color to apply to the dice in the `DiceSet`. Should be a valid CSS color but is not validated or enforced and doesn\'t currently have any real functionality associated with it. _**Applied** to Die objects by default with ability to modify_
128
135
 
136
+ <a name="properties-of-die-objects"></a>
129
137
  #### Properties of individual Die objects
130
138
  When initialized from a `DiceSet` object most of the properties of the `Die` object are inherited from the `DiceSet` object. In addition, there is an `is_included_in_total` public attribute that can be set to indicate whether the value of that particular die should be included in the total for its parent `DiceSet`. This property always starts out as true when the `Die` is initialized, but can be set to false.
131
139
 
@@ -144,6 +152,7 @@ die.value # => Integer between 1 and number_of_sides
144
152
  # Rolls/rerolls the Die, sets value to the result of the roll, and returns the new value
145
153
  die.roll # => Integer.
146
154
  ```
155
+ <a name="iterating"></a>
147
156
  #### Iterating through dice in a DiceSet
148
157
  The `DiceSet` class mixes in the `Enumerable` module and the `Die` object mixes in the `Comparable` module. This allows you to iterate over the dice in the collection. The `sort` method on the dice will return the die objects in ascending value from lowest to highest.
149
158
 
@@ -165,6 +174,7 @@ dice_set.each do |die|
165
174
  # do other things
166
175
  end
167
176
  ```
177
+ <a name="method-chaining"></a>
168
178
  #### Methods and method chaining on the DiceSet
169
179
  Since the DiceSet is an object, you can call methods that operate on the result returned and allow for things like the 5e advantage/disadvantage mechanic, the ability to re-roll all of the dice in the `DiceSet`, or to mark them all as included in the total.
170
180
 
@@ -203,7 +213,7 @@ dice_set.reroll_all!
203
213
  # include_all_dice! method
204
214
  dice_set.include_all_dice! # resets is_included_in_total to true for all Die objects
205
215
  ```
206
-
216
+ <a name="ability-scores"></a>
207
217
  ### Rolling Ability Scores
208
218
  You can call `roll_ability_scores` or `total_ability_scores` to get back an array of `DiceSet` objects or `Integer` objects, respectively. The `total_ability_scores` method calls `total` on each `DiceSet` and returns those numbers with one value per ability score. The `Configuration` object defaults to 6 ability scores using a methodology of __4d6 drop the lowest__ by default.
209
219
 
@@ -244,6 +254,7 @@ NerdDice.roll_ability_scores(
244
254
  ```
245
255
  **Note:** If you try to call this method with `ability_score_dice_kept` greater than `ability_score_dice_rolled` an error will be raised.
246
256
 
257
+ <a name="refreshing-seed"></a>
247
258
  ### Manually setting or refreshing the random generator seed
248
259
  For randomization techniques other than `:securerandom` you can manually set or refresh the generator's seed by calling the `refresh_seed!` method. This is automatically called at the interval specified in `NerdDice.configuration.refresh_seed_interval` if it is not nil.
249
260
 
@@ -261,8 +272,10 @@ NerdDice.refresh_seed!(randomization_technique: :randomized,
261
272
  ```
262
273
  __NOTE:__ Ability to specify a seed is primarily provided for testing purposes. This makes all random numbers generated _transparently deterministic_ and should not be used if you want behavior approximating randomness.
263
274
 
275
+ <a name="utility-methods"></a>
264
276
  ### Utility Methods
265
277
 
278
+ <a name="harvest-totals"></a>
266
279
  #### Harvesting Totals from DiceSets
267
280
  The `harvest_totals` method take any collection of objects where each element responds to `total` and return an array of the results of the total method.
268
281
  ```ruby
@@ -281,11 +294,13 @@ totals_array = NerdDice.harvest_totals(totals_array)
281
294
  ### Convenience Methods Mixin
282
295
  NerdDice provides an optional mixin `NerdDice::ConvenienceMethods` that uses Ruby\'s `method_missing` metaprogramming pattern to allow you to roll any number of dice with bonuses and/or the advantage/disadvantage mechanic by dynamically responding to methods that you type that match the `roll_` or `total_` pattern.
283
296
 
297
+ <a name="considerations-for-convenience-methods"></a>
284
298
  #### Considerations for ConvenienceMethods
285
299
  Before mixing in this method with a class, be aware of other `method_missing` gems that you are also mixing into your project and be sure to write robust tests. We have sought to use `method_missing` in a responsible manner that delegates back to the default implementation using `super` if the method does not match the `ConvenienceMethods` pattern, but there is no guarantee that other gems included in your project are doing the same. If you run into problems with the `ConvenienceMethods` module interacting with other `method_missing` gems, everything that the `ConvenienceMethods` module does can be replicated using the module\-level methods described above or by calling the convenience method on `NerdDice`.
286
300
 
287
301
  Once a particular method has been called, it will define that method so that the next time it will invoke the method directly instead of traversing up the call stack for `method_missing`, which improves performance. The method will remain defined for the duration of the Ruby interpreter process.
288
302
 
303
+ <a name="magic-nerd-dice-class-methods"></a>
289
304
  #### Calling ConvenienceMethods as NerdDice class methods
290
305
  NerdDice extends the `ConvenienceMethods` module into the top-level module as class methods, so you can call the methods on the NerdDice module without needing to worry about the implications of extending it into your own class.
291
306
  ```ruby
@@ -294,7 +309,7 @@ require 'nerd_dice'
294
309
  NerdDice.roll_3d6_lowest2_minus1
295
310
  NerdDice.total_d20_with_advantage_p6
296
311
  ```
297
-
312
+ <a name="mixing-in-convenience-methods"></a>
298
313
  #### Mixing in the ConvenienceMethods module
299
314
  To mix the NerdDice DSL into your class, make sure the gem is required if not already and then use `include NerdDice::ConvenienceMethods` as shown below:
300
315
  ```ruby
@@ -324,7 +339,7 @@ class OtherClass
324
339
  end
325
340
  OtherClass.roll_3d6_lowest2_minus1 # returns NerdDice::DiceSet
326
341
  ```
327
-
342
+ <a name="convenience-methods-usage"></a>
328
343
  #### ConvenienceMethods usage examples
329
344
  Any invocation of `NerdDice.roll_dice` and `NerdDice.total_dice` can be duplicated using the `NerdDice::ConvenienceMethods` mixin. Here are some examples of what you can do with the return types and equivalent methods in the comments:
330
345
 
@@ -387,6 +402,7 @@ roll_d20_with_advantage # => DiceSet: NerdDice.roll_dice(20, 2).with_advantage(1
387
402
  # equal to total_2d20_with_advantage but more natural
388
403
  total_d20_with_advantage # => Integer: NerdDice.roll_dice(20, 2).with_advantage(1).total
389
404
  ```
405
+ <a name="convenience-methods-error-handling"></a>
390
406
  #### ConvenienceMethods error handling
391
407
  * If you try to call with a plus and a minus, an Exception is raised
392
408
  * If you call with a bonus and a keyword argument and they don't match, an Exception is raised
@@ -397,17 +413,19 @@ roll_3d8_plus3 bonus: 1 # will raise NerdDice::Error with message about "Bonus i
397
413
  roll_d20_with_advantage_lowest # will raise NameError using super method_missing
398
414
  total_4d6_lowest3_highest2 # will raise NameError using super method_missing
399
415
  ```
416
+ <a name="code-along"></a>
417
+ ## Code Along!
400
418
 
401
- ## Development
402
-
403
- After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
419
+ You can contribute to this project in a variety of ways. See the [CONTRIBUTING](CONTRIBUTING.md) page for more details. You don't need to be a programmer to contribute. We welcome [feature requests](CONTRIBUTING.md#feature-requests), [bug reports](CONTRIBUTING.md#bug-reports), [code contributions](CONTRIBUTING.md#code-contributions), and [documentation contributions](CONTRIBUTING.md#documentation-contributions) as well as [art, design and/or creative input](CONTRIBUTING.md#art-design-creative-input).
404
420
 
405
- To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
421
+ <a name="conduct"></a>
422
+ ## Conduct
406
423
 
407
- ## Contributing
424
+ Just be polite and courteous in your interactions. It is possible to disagree passionately about ideas without making it personal. You can make a point without using language that leads to escalation. Nobody working on this project is perfect. In the event that something goes wrong, seek forgiveness and reconciliation with one another. **[Mercy triumphs over judgment](https://www.biblegateway.com/passage/?search=James+2&version=ESV)**.
408
425
 
409
- Bug reports and pull requests are welcome on GitHub at https://github.com/statelesscode/nerd_dice/issues. We welcome and encourage your participation in this open-source project. We welcome those of all backgrounds and abilities, but we refuse to adopt the Contributor Covenant for reasons outlined in [BURN_THE_CONTRIBUTOR_COVENANT_WITH_FIRE.md](BURN_THE_CONTRIBUTOR_COVENANT_WITH_FIRE.md)
426
+ We welcome and encourage your participation in this open-source project. We welcome those of all backgrounds and abilities, but we refuse to adopt the Contributor Covenant or any similar code of conduct for reasons outlined in [BURN_THE_CONTRIBUTOR_COVENANT_WITH_FIRE](BURN_THE_CONTRIBUTOR_COVENANT_WITH_FIRE.md). We welcome those who disagree about codes of conduct to contribute to this project, but we want to make it abundantly clear that Code of Conduct Trolls have no power here.
410
427
 
428
+ <a name="legal"></a>
411
429
  ## Unlicense, License, and Copyright
412
430
 
413
431
  The project is dual-licensed under the [MIT](https://opensource.org/licenses/MIT) license and the [UNLICENSE](https://unlicense.org/) \(with strong preference toward the UNLICENSE\)\. The content is released under [CC0](https://creativecommons.org/share-your-work/public-domain/cc0/) \(no rights reserved\). You are free to include it in its original form or modified with or without additional modification in your own project\.
data/SECURITY.md ADDED
@@ -0,0 +1,21 @@
1
+ # Security Policy
2
+
3
+ ## Supported Versions
4
+
5
+ As-of right now, the latest patch version of each minor version is supported, but versions earlier than `0.5.x` are deprecated and will not receive additional updates after their certificate expires on February 23, 2024.
6
+
7
+ | Version | Supported | End of Life |
8
+ | ------- | -------------------------- | ----------- |
9
+ | 0.5.x | :white_check_mark: Current | |
10
+ | 0.4.x | :warning: Deprecated | 2024-02-23 |
11
+ | 0.3.x | :warning: Deprecated | 2024-02-23 |
12
+ | 0.2.x | :warning: Deprecated | 2024-02-23 |
13
+ | 0.1.x | :warning: Deprecated | 2024-02-23 |
14
+
15
+ ## Certificate Signing and Checksums
16
+
17
+ The gem is currently released with a certificate so it can be installed with the `HighSecurity` policy. The SHA-256 and SHA-512 of each released version of the gem is kept in the `checksum` directory of the GitHub repository.
18
+
19
+ ## Reporting a Vulnerability
20
+
21
+ Please report (suspected) security vulnerabilities to security@statelesscode.com. We make no guarantees related to turnaround time. If the issue is confirmed, we will release a patch as soon as possible depending on complexity and severity.
@@ -1,27 +1,27 @@
1
1
  -----BEGIN CERTIFICATE-----
2
2
  MIIEhTCCAu2gAwIBAgIBATANBgkqhkiG9w0BAQsFADBEMRYwFAYDVQQDDA1zdGF0
3
3
  ZWxlc3Njb2RlMRUwEwYKCZImiZPyLGQBGRYFZ21haWwxEzARBgoJkiaJk/IsZAEZ
4
- FgNjb20wHhcNMjMwMjIzMjMyMTQwWhcNMjQwMjIzMjMyMTQwWjBEMRYwFAYDVQQD
4
+ FgNjb20wHhcNMjQwMjI1MDUwMjMyWhcNMjUwMjI0MDUwMjMyWjBEMRYwFAYDVQQD
5
5
  DA1zdGF0ZWxlc3Njb2RlMRUwEwYKCZImiZPyLGQBGRYFZ21haWwxEzARBgoJkiaJ
6
- k/IsZAEZFgNjb20wggGiMA0GCSqGSIb3DQEBAQUAA4IBjwAwggGKAoIBgQCxVzHS
7
- gYszan//tjTSO0z59UO1rUiT5G0//iyhiaYIiuwxhYFbfD+wOCou4M18pQtEb4qx
8
- o67tPfGimBAVak6fGfo8fo1ByHiKCvx3jgOjxNifT9pRFlBSr6ZvyXeu7zA0ddLr
9
- slw92DNqeRlZXqB0mxDtpKWONGc1XhAqEjEP3VL7g7x0xPQShcpXg/OyRPR5vyv8
10
- 66pXdFrXYZGrySfIB6ZOWFV6wGB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hIqK01NSGv7v7/BLj8dkIovGU3ZGOS/dt1C+SIGPU
23
+ eqrWOdAE4uMEoaV4Wg/99C5Wh492EMkfc21e94txLrjwsrpCmQ/rJ3C9m9sNJc2x
24
+ 9K9Wl/3ET4PcRcOkctsJGKWRMW+KY5LEUSxMg0jURQIR0cKDfv/zGmvBAkvG6ULq
25
+ XSkYcMWowop72jQqf0edJiaEIypupYqx/DPoKRyroiNl3LXwfjZzjd1wZSrM2A+s
26
+ iOVXSt3E06vw
27
27
  -----END CERTIFICATE-----
@@ -78,10 +78,10 @@ module NerdDice
78
78
  # roll_d20_with_advantage_lowest # will raise NameError using super method_missing
79
79
  # total_4d6_lowest3_highest2 # will raise NameError using super method_missing
80
80
  module ConvenienceMethods
81
- DIS = /_(with_disadvantage|lowest)/.freeze
82
- ADV = /_(with_advantage|highest)/.freeze
83
- MOD = /(_p(lus)?\d+|_m(inus)?\d+)/.freeze
84
- OVERALL_REGEXP = /\A(roll|total)_\d*d\d+((#{ADV}|#{DIS})\d*)?#{MOD}?\z/.freeze
81
+ DIS = /_(with_disadvantage|lowest)/
82
+ ADV = /_(with_advantage|highest)/
83
+ MOD = /(_p(lus)?\d+|_m(inus)?\d+)/
84
+ OVERALL_REGEXP = /\A(roll|total)_\d*d\d+((#{ADV}|#{DIS})\d*)?#{MOD}?\z/
85
85
 
86
86
  # Override of method_missing
87
87
  # * Attempts to match pattern to the regular expression matching the methods
@@ -90,11 +90,11 @@ module NerdDice
90
90
  # * Subsequent calls to the same method name will not hit method_missing
91
91
  # * If the method name does not match the regular expression pattern, the default
92
92
  # implementation of method_missing is called by invoking super
93
- def method_missing(method_name, *args, **kwargs, &block)
93
+ def method_missing(method_name, ...)
94
94
  # returns false if no match
95
- if match_pattern_and_delegate(method_name, *args, **kwargs, &block)
95
+ if match_pattern_and_delegate(method_name, ...)
96
96
  # send the method after defining it
97
- send(method_name, *args, **kwargs, &block)
97
+ send(method_name, ...)
98
98
  else
99
99
  super
100
100
  end
@@ -111,12 +111,10 @@ module NerdDice
111
111
  # Compares the method name to the regular expression patterns for the module
112
112
  # * If the pattern matches the convenience method is defined and a truthy value is returned
113
113
  # * If the pattern does not match then the method returns false and method_missing invokes `super`
114
- def match_pattern_and_delegate(method_name, *args, **kwargs, &block)
114
+ def match_pattern_and_delegate(method_name, ...)
115
115
  case method_name.to_s
116
- when /\Aroll_\d*d\d+((#{ADV}|#{DIS})\d*)?#{MOD}?\z/o then define_roll_nndnn(method_name, *args, **kwargs,
117
- &block)
118
- when /\Atotal_\d*d\d+((#{ADV}|#{DIS})\d*)?#{MOD}?\z/o then define_total_nndnn(method_name, *args, **kwargs,
119
- &block)
116
+ when /\Aroll_\d*d\d+((#{ADV}|#{DIS})\d*)?#{MOD}?\z/o then define_roll_nndnn(method_name, ...)
117
+ when /\Atotal_\d*d\d+((#{ADV}|#{DIS})\d*)?#{MOD}?\z/o then define_total_nndnn(method_name, ...)
120
118
  else
121
119
  false
122
120
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module NerdDice
4
- VERSION = "0.4.1"
4
+ VERSION = "0.5.1"
5
5
  end
data/nerd_dice.gemspec CHANGED
@@ -18,7 +18,7 @@ Gem::Specification.new do |spec|
18
18
  GEM_DESCRIPTION
19
19
  spec.homepage = "https://github.com/statelesscode/nerd_dice"
20
20
  spec.licenses = %w[Unlicense MIT]
21
- spec.required_ruby_version = Gem::Requirement.new(">= 2.7.0")
21
+ spec.required_ruby_version = Gem::Requirement.new(">= 3.0.0")
22
22
 
23
23
  spec.metadata["allowed_push_host"] = "https://rubygems.org"
24
24
 
@@ -44,13 +44,13 @@ Gem::Specification.new do |spec|
44
44
  spec.signing_key = File.expand_path("~/.ssh/gem-private_key.pem") if $PROGRAM_NAME.end_with?("gem")
45
45
 
46
46
  # Dependencies
47
- spec.add_dependency "securerandom", "~> 0.2", ">= 0.2.2"
47
+ spec.add_dependency "securerandom", "~> 0.3", ">= 0.3.1"
48
48
 
49
49
  # Development Dependencies
50
- spec.add_development_dependency "coveralls_reborn", "~> 0.27.0"
51
- spec.add_development_dependency "rubocop", "~> 1.46", ">= 1.46.0"
52
- spec.add_development_dependency "rubocop-performance", "~> 1.16", ">= 1.16.0"
50
+ spec.add_development_dependency "coveralls_reborn", "~> 0.28.0"
51
+ spec.add_development_dependency "rubocop", "~> 1.60", ">= 1.60.2"
52
+ spec.add_development_dependency "rubocop-performance", "~> 1.20", ">= 1.20.2"
53
53
  spec.add_development_dependency "rubocop-rake", "~> 0.6", ">= 0.6.0"
54
- spec.add_development_dependency "rubocop-rspec", "~> 2.18", ">= 2.18.1"
54
+ spec.add_development_dependency "rubocop-rspec", "~> 2.26", ">= 2.26.1"
55
55
  spec.add_development_dependency "simplecov-lcov", "~> 0.8.0"
56
56
  end
data.tar.gz.sig CHANGED
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nerd_dice
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.1
4
+ version: 0.5.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michael Duchemin
@@ -12,31 +12,31 @@ cert_chain:
12
12
  -----BEGIN CERTIFICATE-----
13
13
  MIIEhTCCAu2gAwIBAgIBATANBgkqhkiG9w0BAQsFADBEMRYwFAYDVQQDDA1zdGF0
14
14
  ZWxlc3Njb2RlMRUwEwYKCZImiZPyLGQBGRYFZ21haWwxEzARBgoJkiaJk/IsZAEZ
15
- FgNjb20wHhcNMjMwMjIzMjMyMTQwWhcNMjQwMjIzMjMyMTQwWjBEMRYwFAYDVQQD
15
+ FgNjb20wHhcNMjQwMjI1MDUwMjMyWhcNMjUwMjI0MDUwMjMyWjBEMRYwFAYDVQQD
16
16
  DA1zdGF0ZWxlc3Njb2RlMRUwEwYKCZImiZPyLGQBGRYFZ21haWwxEzARBgoJkiaJ
17
- k/IsZAEZFgNjb20wggGiMA0GCSqGSIb3DQEBAQUAA4IBjwAwggGKAoIBgQCxVzHS
18
- gYszan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G7UekkYs+Dj5KAf10rA9fhxRjqKCmvVXpRqLifF4eJDv1zkXOv4/0KVm
31
+ xUBMDFKxzYPyuIw3RrwiW2Zsv9C67cD108LIOJ2ieqDHmW/vSrysYcjf5iQuVz98
32
+ 7nKraLZJRukjFo01lYCLu2Wz6Ey+3WodcRmArrcWFaYnz2WsX1WMB4HTK9F1a4WA
33
+ HdOa8ywu3BeV9D6S7630G9AhIqK01NSGv7v7/BLj8dkIovGU3ZGOS/dt1C+SIGPU
34
+ eqrWOdAE4uMEoaV4Wg/99C5Wh492EMkfc21e94txLrjwsrpCmQ/rJ3C9m9sNJc2x
35
+ 9K9Wl/3ET4PcRcOkctsJGKWRMW+KY5LEUSxMg0jURQIR0cKDfv/zGmvBAkvG6ULq
36
+ XSkYcMWowop72jQqf0edJiaEIypupYqx/DPoKRyroiNl3LXwfjZzjd1wZSrM2A+s
37
+ iOVXSt3E06vw
38
38
  -----END CERTIFICATE-----
39
- date: 2023-02-24 00:00:00.000000000 Z
39
+ date: 2024-02-25 00:00:00.000000000 Z
40
40
  dependencies:
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: securerandom
@@ -44,74 +44,74 @@ dependencies:
44
44
  requirements:
45
45
  - - "~>"
46
46
  - !ruby/object:Gem::Version
47
- version: '0.2'
47
+ version: '0.3'
48
48
  - - ">="
49
49
  - !ruby/object:Gem::Version
50
- version: 0.2.2
50
+ version: 0.3.1
51
51
  type: :runtime
52
52
  prerelease: false
53
53
  version_requirements: !ruby/object:Gem::Requirement
54
54
  requirements:
55
55
  - - "~>"
56
56
  - !ruby/object:Gem::Version
57
- version: '0.2'
57
+ version: '0.3'
58
58
  - - ">="
59
59
  - !ruby/object:Gem::Version
60
- version: 0.2.2
60
+ version: 0.3.1
61
61
  - !ruby/object:Gem::Dependency
62
62
  name: coveralls_reborn
63
63
  requirement: !ruby/object:Gem::Requirement
64
64
  requirements:
65
65
  - - "~>"
66
66
  - !ruby/object:Gem::Version
67
- version: 0.27.0
67
+ version: 0.28.0
68
68
  type: :development
69
69
  prerelease: false
70
70
  version_requirements: !ruby/object:Gem::Requirement
71
71
  requirements:
72
72
  - - "~>"
73
73
  - !ruby/object:Gem::Version
74
- version: 0.27.0
74
+ version: 0.28.0
75
75
  - !ruby/object:Gem::Dependency
76
76
  name: rubocop
77
77
  requirement: !ruby/object:Gem::Requirement
78
78
  requirements:
79
79
  - - "~>"
80
80
  - !ruby/object:Gem::Version
81
- version: '1.46'
81
+ version: '1.60'
82
82
  - - ">="
83
83
  - !ruby/object:Gem::Version
84
- version: 1.46.0
84
+ version: 1.60.2
85
85
  type: :development
86
86
  prerelease: false
87
87
  version_requirements: !ruby/object:Gem::Requirement
88
88
  requirements:
89
89
  - - "~>"
90
90
  - !ruby/object:Gem::Version
91
- version: '1.46'
91
+ version: '1.60'
92
92
  - - ">="
93
93
  - !ruby/object:Gem::Version
94
- version: 1.46.0
94
+ version: 1.60.2
95
95
  - !ruby/object:Gem::Dependency
96
96
  name: rubocop-performance
97
97
  requirement: !ruby/object:Gem::Requirement
98
98
  requirements:
99
99
  - - "~>"
100
100
  - !ruby/object:Gem::Version
101
- version: '1.16'
101
+ version: '1.20'
102
102
  - - ">="
103
103
  - !ruby/object:Gem::Version
104
- version: 1.16.0
104
+ version: 1.20.2
105
105
  type: :development
106
106
  prerelease: false
107
107
  version_requirements: !ruby/object:Gem::Requirement
108
108
  requirements:
109
109
  - - "~>"
110
110
  - !ruby/object:Gem::Version
111
- version: '1.16'
111
+ version: '1.20'
112
112
  - - ">="
113
113
  - !ruby/object:Gem::Version
114
- version: 1.16.0
114
+ version: 1.20.2
115
115
  - !ruby/object:Gem::Dependency
116
116
  name: rubocop-rake
117
117
  requirement: !ruby/object:Gem::Requirement
@@ -138,20 +138,20 @@ dependencies:
138
138
  requirements:
139
139
  - - "~>"
140
140
  - !ruby/object:Gem::Version
141
- version: '2.18'
141
+ version: '2.26'
142
142
  - - ">="
143
143
  - !ruby/object:Gem::Version
144
- version: 2.18.1
144
+ version: 2.26.1
145
145
  type: :development
146
146
  prerelease: false
147
147
  version_requirements: !ruby/object:Gem::Requirement
148
148
  requirements:
149
149
  - - "~>"
150
150
  - !ruby/object:Gem::Version
151
- version: '2.18'
151
+ version: '2.26'
152
152
  - - ">="
153
153
  - !ruby/object:Gem::Version
154
- version: 2.18.1
154
+ version: 2.26.1
155
155
  - !ruby/object:Gem::Dependency
156
156
  name: simplecov-lcov
157
157
  requirement: !ruby/object:Gem::Requirement
@@ -188,11 +188,13 @@ files:
188
188
  - ".rubocop.yml"
189
189
  - BURN_THE_CONTRIBUTOR_COVENANT_WITH_FIRE.md
190
190
  - CHANGELOG.md
191
+ - CONTRIBUTING.md
191
192
  - Gemfile
192
193
  - Gemfile.lock
193
194
  - LICENSE.txt
194
195
  - README.md
195
196
  - Rakefile
197
+ - SECURITY.md
196
198
  - UNLICENSE.txt
197
199
  - bin/console
198
200
  - bin/generate_checksums
@@ -247,14 +249,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
247
249
  requirements:
248
250
  - - ">="
249
251
  - !ruby/object:Gem::Version
250
- version: 2.7.0
252
+ version: 3.0.0
251
253
  required_rubygems_version: !ruby/object:Gem::Requirement
252
254
  requirements:
253
255
  - - ">="
254
256
  - !ruby/object:Gem::Version
255
257
  version: '0'
256
258
  requirements: []
257
- rubygems_version: 3.4.7
259
+ rubygems_version: 3.5.6
258
260
  signing_key:
259
261
  specification_version: 4
260
262
  summary: A Ruby Gem for rolling polyhedral dice.
metadata.gz.sig CHANGED
Binary file