Skip to content

Add HasBranches method to Repository

Sami Hiltunen requested to merge smh-add-has-branches into master
  • Adds HasBranches to Repository for checking whether the repository has local branches or not. Some operations service calls need to know whether a repository has branches or not.

  • Change remote repository to dial in the constructor once and to reuse the connection in method calls. Deduplicates some of the code and simplifies the struct as we have to hold less information.

  • Repositories service has some duplicated code with git.LocalRepository. This changes the service to reuse the existing implementation to check if the repository contains branches.

Needed for addressing #3254 (comment 449143737)

Edited by Sami Hiltunen

Merge request reports