distributed_merge 0.1.0 → 0.1.1
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 +4 -4
- data/CHANGELOG.md +5 -2
- data/Gemfile.lock +1 -1
- data/README.md +16 -15
- data/lib/distributed_merge/version.rb +1 -1
- metadata +7 -8
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 92ade424d3cb277b686b08c61647c6146692a4b23c7b2ccce5a68b3543d8148d
|
4
|
+
data.tar.gz: c26043ad80bf6b86f27bd8007de647f2c4ab809fdbb745705a1335bf12468303
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 68553abbb9c8785390ead72b10a16b83096b620b4dc9164acfa74a7c3e7c75360df4a0aa96a30de6434bae77cd67b9725b3f2ad2b9df0a689cea810ceb55f163
|
7
|
+
data.tar.gz: 662a5c4c1a000b991006992b30aaf1a052024285a8652ad531ea40eae05ab3c3b2a02c88d6a91f38db9645100a8814d5029a900b8dbdc2be5eef961d17e593de
|
data/CHANGELOG.md
CHANGED
data/Gemfile.lock
CHANGED
data/README.md
CHANGED
@@ -1,40 +1,41 @@
|
|
1
1
|
# DistributedMerge
|
2
2
|
|
3
|
-
[](https://github.com/grosser/single_cov)
|
4
4
|
|
5
5
|
'distributed_merge' is a Ruby gem that adds a method to Array class that allows
|
6
6
|
merge interleaving arrays of non-equal length with elements being equally
|
7
7
|
distributed. The method can be called on a two-dimensional array containing two
|
8
8
|
or more sub-arrays of various size.
|
9
9
|
|
10
|
-
|
11
|
-
Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/distributed_merge`. To experiment with that code, run `bin/console` for an interactive prompt.
|
12
|
-
|
13
10
|
## Installation
|
14
11
|
|
15
|
-
|
16
|
-
|
17
|
-
Install the gem and add to the application's Gemfile by executing:
|
12
|
+
To install the gem run the following command in the terminal:
|
18
13
|
|
19
|
-
$ bundle add
|
14
|
+
$ bundle add distributed_merge
|
20
15
|
|
21
16
|
If bundler is not being used to manage dependencies, install the gem by executing:
|
22
17
|
|
23
|
-
$ gem install
|
18
|
+
$ gem install distributed_merge
|
24
19
|
|
25
20
|
## Usage
|
26
21
|
|
27
|
-
|
22
|
+
To add the distributed_merge method to your project include it in your project like so:
|
23
|
+
```ruby
|
24
|
+
require 'distributed_merge'
|
25
|
+
```
|
28
26
|
|
29
|
-
|
27
|
+
When included the method can be called on any two-dimensional array containing sub-arrays of various size (non-equal length) and it will return a single layer merged array with all the elements of the sub-arrays evenly interleaved and distributed.
|
30
28
|
|
31
|
-
|
32
|
-
|
33
|
-
|
29
|
+
```ruby
|
30
|
+
[[1, 2, 3, 4], ['a', 'b'], ['C']].distributed_merge
|
31
|
+
# => [1, "b", 2, "C", 3, "a", 4]
|
32
|
+
```
|
34
33
|
|
35
34
|
## Contributing
|
36
35
|
|
37
|
-
Bug reports and pull requests are welcome
|
36
|
+
Bug reports and pull requests are welcome at https://github.com/msuliq/distributed_merge. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [code of conduct](https://github.com/msuliq/distributed_merge/blob/main/CODE_OF_CONDUCT.md).
|
37
|
+
|
38
|
+
The best way to contribute would be to fork this repo, create a new branch from main, to merge the branch into main of the fork once the new code is in place and then open a pull request to merge forked main into the main of the present repo.
|
38
39
|
|
39
40
|
## License
|
40
41
|
|
metadata
CHANGED
@@ -1,11 +1,11 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: distributed_merge
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
|
-
-
|
8
|
-
autorequire:
|
7
|
+
- msuliq
|
8
|
+
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
11
|
date: 2023-04-15 00:00:00.000000000 Z
|
@@ -36,11 +36,10 @@ homepage: https://github.com/msuliq/distributed_merge
|
|
36
36
|
licenses:
|
37
37
|
- MIT
|
38
38
|
metadata:
|
39
|
-
allowed_push_host: https://rubygems.org
|
40
39
|
homepage_uri: https://github.com/msuliq/distributed_merge
|
41
40
|
source_code_uri: https://github.com/msuliq/distributed_merge
|
42
|
-
changelog_uri: https://github.com/msuliq/distributed_merge/
|
43
|
-
post_install_message:
|
41
|
+
changelog_uri: https://github.com/msuliq/distributed_merge/blob/main/CHANGELOG.md
|
42
|
+
post_install_message:
|
44
43
|
rdoc_options: []
|
45
44
|
require_paths:
|
46
45
|
- lib
|
@@ -55,8 +54,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
55
54
|
- !ruby/object:Gem::Version
|
56
55
|
version: '0'
|
57
56
|
requirements: []
|
58
|
-
rubygems_version: 3.
|
59
|
-
signing_key:
|
57
|
+
rubygems_version: 3.1.6
|
58
|
+
signing_key:
|
60
59
|
specification_version: 4
|
61
60
|
summary: Gem that adds the method to merge arrays of unequal size with distribution
|
62
61
|
of elements.
|