Add repo_valid? to remaining VCS strategies

This commit is contained in:
Jack Nagel 2014-12-06 12:29:15 -05:00
parent a2dbcfee5b
commit 8debc18839

View File

@ -68,6 +68,10 @@ class VCSDownloadStrategy < AbstractDownloadStrategy
"#{name}--#{cache_tag}" "#{name}--#{cache_tag}"
end end
def repo_valid?
true
end
def extract_ref(specs) def extract_ref(specs)
key = REF_TYPES.find { |type| specs.key?(type) } key = REF_TYPES.find { |type| specs.key?(type) }
return key, specs[key] return key, specs[key]
@ -609,6 +613,10 @@ class CVSDownloadStrategy < VCSDownloadStrategy
"cvs" "cvs"
end end
def repo_valid?
@clone.join("CVS").directory?
end
def split_url(in_url) def split_url(in_url)
parts=in_url.sub(%r[^cvs://], '').split(/:/) parts=in_url.sub(%r[^cvs://], '').split(/:/)
mod=parts.pop mod=parts.pop
@ -752,6 +760,10 @@ class FossilDownloadStrategy < VCSDownloadStrategy
"fossil" "fossil"
end end
def repo_valid?
true
end
def fossilpath def fossilpath
@path ||= %W[ @path ||= %W[
#{which("fossil")} #{which("fossil")}