diff options
| -rw-r--r-- | Library/Homebrew/download_strategy.rb | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/Library/Homebrew/download_strategy.rb b/Library/Homebrew/download_strategy.rb index 9cb56cd21..3f94ccbd1 100644 --- a/Library/Homebrew/download_strategy.rb +++ b/Library/Homebrew/download_strategy.rb @@ -642,6 +642,12 @@ class CVSDownloadStrategy < VCSDownloadStrategy def initialize(name, resource) super @url = @url.sub(%r[^cvs://], "") + + if meta.key?(:module) + @module = meta.fetch(:module) + else + @module, @url = split_url(@url) + end end def stage @@ -659,15 +665,9 @@ class CVSDownloadStrategy < VCSDownloadStrategy end def clone_repo - # URL of cvs cvs://:pserver:anoncvs@www.gccxml.org:/cvsroot/GCC_XML:gccxml - # will become: - # cvs -d :pserver:anoncvs@www.gccxml.org:/cvsroot/GCC_XML login - # cvs -d :pserver:anoncvs@www.gccxml.org:/cvsroot/GCC_XML co gccxml - mod, url = split_url(@url) - HOMEBREW_CACHE.cd do - quiet_safe_system cvspath, { :quiet_flag => "-Q" }, "-d", url, "login" - quiet_safe_system cvspath, { :quiet_flag => "-Q" }, "-d", url, "checkout", "-d", cache_filename, mod + quiet_safe_system cvspath, { :quiet_flag => "-Q" }, "-d", @url, "login" + quiet_safe_system cvspath, { :quiet_flag => "-Q" }, "-d", @url, "checkout", "-d", cache_filename, @module end end |
