From 5aa6aefa9664597ae9f004a9e0cb58edd31a2d6e Mon Sep 17 00:00:00 2001 From: Adam Vandenberg Date: Sun, 11 Mar 2012 14:37:44 -0700 Subject: [PATCH] Allow multiple digits in GitHub version parts --- Library/Homebrew/extend/pathname.rb | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Library/Homebrew/extend/pathname.rb b/Library/Homebrew/extend/pathname.rb index 34f692f28c..6057c14374 100644 --- a/Library/Homebrew/extend/pathname.rb +++ b/Library/Homebrew/extend/pathname.rb @@ -154,21 +154,21 @@ class Pathname end # github tarballs, like v1.2.3 - %r[github.com/.*/(zip|tar)ball/v?((\d\.)+\d+)$].match to_s + %r[github.com/.*/(zip|tar)ball/v?((\d+\.)+\d+)$].match to_s return $2 if $2 # eg. https://github.com/sam-github/libnet/tarball/libnet-1.1.4 - %r[github.com/.*/(zip|tar)ball/.*-((\d\.)+\d+)$].match to_s + %r[github.com/.*/(zip|tar)ball/.*-((\d+\.)+\d+)$].match to_s return $2 if $2 # dashed version # eg. github.com/isaacs/npm/tarball/v0.2.5-1 - %r[github.com/.*/(zip|tar)ball/v?((\d\.)+\d+-(\d+))$].match to_s + %r[github.com/.*/(zip|tar)ball/v?((\d+\.)+\d+-(\d+))$].match to_s return $2 if $2 # underscore version # eg. github.com/petdance/ack/tarball/1.93_02 - %r[github.com/.*/(zip|tar)ball/v?((\d\.)+\d+_(\d+))$].match to_s + %r[github.com/.*/(zip|tar)ball/v?((\d+\.)+\d+_(\d+))$].match to_s return $2 if $2 # eg. boost_1_39_0