diff options
| author | Jack Nagel | 2014-12-05 18:57:28 -0500 |
|---|---|---|
| committer | Jack Nagel | 2014-12-05 18:57:28 -0500 |
| commit | 853399da445cfa4f305a9162264f7a7bdee425b2 (patch) | |
| tree | 0f4fe032b87ef7959720fc3ad0c539fb40026551 | |
| parent | 68a5268aef12ae684550157f635fadff16c94e8c (diff) | |
| download | brew-853399da445cfa4f305a9162264f7a7bdee425b2.tar.bz2 | |
Provide VCSDownloadStrategy#head?
| -rw-r--r-- | Library/Homebrew/download_strategy.rb | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/Library/Homebrew/download_strategy.rb b/Library/Homebrew/download_strategy.rb index 1e84bb272..d3b72e09a 100644 --- a/Library/Homebrew/download_strategy.rb +++ b/Library/Homebrew/download_strategy.rb @@ -66,6 +66,10 @@ class VCSDownloadStrategy < AbstractDownloadStrategy def clear_cache cached_location.rmtree if cached_location.exist? end + + def head? + resource.version.head? + end end class CurlDownloadStrategy < AbstractDownloadStrategy @@ -350,7 +354,7 @@ end class SubversionDownloadStrategy < VCSDownloadStrategy def cache_tag - resource.version.head? ? "svn-HEAD" : "svn" + head? ? "svn-HEAD" : "svn" end def repo_valid? |
