From 466e55c6ab121e5f0008707e4cefff2bac0e8fca Mon Sep 17 00:00:00 2001 From: Sam Ford <1584702+samford@users.noreply.github.com> Date: Sun, 20 Dec 2020 18:13:51 -0500 Subject: [PATCH] Bitbucket: Format regex like other strategies --- Library/Homebrew/livecheck/strategy/bitbucket.rb | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Library/Homebrew/livecheck/strategy/bitbucket.rb b/Library/Homebrew/livecheck/strategy/bitbucket.rb index b28ce5e989..48d20a7860 100644 --- a/Library/Homebrew/livecheck/strategy/bitbucket.rb +++ b/Library/Homebrew/livecheck/strategy/bitbucket.rb @@ -30,10 +30,10 @@ module Homebrew class Bitbucket # The `Regexp` used to determine if the strategy applies to the URL. URL_MATCH_REGEX = %r{ - ^https?://bitbucket\.org/ - (?.+?)/ # The path leading up to the get or downloads part - (?get|downloads)/ # An indicator of the file download type - (?(?:[^/]+?[_-])?) # Filename text before the version + ^https?://bitbucket\.org + /(?.+?) # The path leading up to the get or downloads part + /(?get|downloads) # An indicator of the file download type + /(?(?:[^/]+?[_-])?) # Filename text before the version v?\d+(?:\.\d+)+ # The numeric version (?[^/]+) # Filename text after the version }ix.freeze