File tree Expand file tree Collapse file tree 1 file changed +6
-13
lines changed
lib/shopify_ruby_definitions Expand file tree Collapse file tree 1 file changed +6
-13
lines changed Original file line number Diff line number Diff line change @@ -4,21 +4,14 @@ module ShopifyRubyDefinitions
4
4
module RubyVersions
5
5
VERSIONS_DIRECTORY = File . expand_path ( "../../../rubies" , __FILE__ )
6
6
ALL_VERSIONS = Dir [ "#{ VERSIONS_DIRECTORY } /*" ] . map { |f | File . basename ( f ) }
7
+ VERSION_OVERRIDES = ALL_VERSIONS . sort_by do |version |
8
+ version . scan ( /\d +/ ) . map ( &:to_i )
9
+ end . to_h do |version |
10
+ [ version . split ( "-" ) . first , version ]
11
+ end . freeze
7
12
8
13
def version_overrides
9
- {
10
- "3.0.0" => "3.0.0-pshopify9" ,
11
- "3.0.1" => "3.0.1-pshopify2" ,
12
- "3.0.2" => "3.0.2-pshopify3" ,
13
- "3.1.0" => "3.1.0-pshopify1" ,
14
- "3.1.1" => "3.1.1-pshopify2" ,
15
- "3.1.2" => "3.1.2-pshopify2" ,
16
- "3.1.3" => "3.1.3-pshopify1" ,
17
- "3.1.4" => "3.1.4-pshopify1" ,
18
- "3.2.0" => "3.2.0-pshopify2" ,
19
- "3.2.1" => "3.2.1-pshopify5" ,
20
- "3.2.2" => "3.2.2-pshopify3" ,
21
- } . freeze
14
+ VERSION_OVERRIDES
22
15
end
23
16
24
17
def resolve_version ( version )
You can’t perform that action at this time.
0 commit comments