Supersonido / rebar_mix

rebar3 plugin for building Elixir dependencies with mix
Apache License 2.0
53 stars 20 forks source link

fix pattern matching on resized tuple #32

Open bsanyi opened 2 years ago

bsanyi commented 2 years ago

The original pattern {hex, App, Version, _, _, _, _} changed to {hex, App, Version, _, _, _, _, _} with my rebar version. (That is, one more underscore in the pattern.) This change accepts any tuple size flagged by the atom hex and gets the App and Version values from the 2nd and 3rd positions in the tuple. This works with the old and new rebar tupple sizes, and is also immune to further added fields.