bottle_version: handle libpano.
This commit is contained in:
parent
bb167ef902
commit
7a06bc067e
@ -16,6 +16,10 @@ class BottleVersion < Version
|
||||
m = /(00-\d+\.\d+(\.\d+)+)/.match(stem)
|
||||
return m.captures.first unless m.nil?
|
||||
|
||||
# e.g. 13-2.9.19 from libpano-13-2.9.19_1.yosemite.bottle.tar.gz
|
||||
m = /\D+-(\d+-[\d\.]+)/.match(stem)
|
||||
return m.captures.first unless m.nil?
|
||||
|
||||
# e.g. 1.6.39 from pazpar2-1.6.39.mavericks.bottle.tar.gz
|
||||
m = /-(\d+\.\d+(\.\d+)+)/.match(stem)
|
||||
return m.captures.first unless m.nil?
|
||||
|
||||
@ -55,4 +55,9 @@ class BottleVersionParsingTests < Homebrew::TestCase
|
||||
assert_version_detected 'R16B03-1',
|
||||
'erlang-R16B03-1.mavericks.bottle.2.tar.gz'
|
||||
end
|
||||
|
||||
def test_libpano_style
|
||||
assert_version_detected '13-2.9.19',
|
||||
'libpano-13-2.9.19_1.yosemite.bottle.tar.gz'
|
||||
end
|
||||
end
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user