lib/bundler/source/git.rb in bundler-2.5.17 vs lib/bundler/source/git.rb in bundler-2.5.18

- old
+ new

@@ -186,13 +186,15 @@ changed end def specs(*) - set_cache_path!(app_cache_path) if has_app_cache? && !local? + set_cache_path!(app_cache_path) if use_app_cache? if requires_checkout? && !@copied + FileUtils.rm_rf(app_cache_path) if use_app_cache? && git_proxy.not_a_bare_repository? + fetch checkout end local_specs @@ -317,9 +319,13 @@ @install_path = path end def has_app_cache? cached_revision && super + end + + def use_app_cache? + has_app_cache? && !local? end def requires_checkout? allow_git_ops? && !local? && !cached_revision_checked_out? end