Ejemplo n.º 1
0
        private string GetBranchNameSuffix(string repositoryPath, string noBranchText)
        {
            if (AppSettings.ShowRepoCurrentBranch && !VsrModule.IsBareRepository(repositoryPath))
            {
                return(" " + GetModuleBranch(repositoryPath, noBranchText));
            }

            return(string.Empty);
        }
Ejemplo n.º 2
0
        private void GetRepositorySubmodulesStructure(SubmoduleInfoResult result, string noBranchText)
        {
            foreach (var submodule in result.Module.GetSubmodulesLocalPaths().OrderBy(submoduleName => submoduleName))
            {
                var    name = submodule;
                string path = result.Module.GetSubmoduleFullPath(submodule);
                if (AppSettings.ShowRepoCurrentBranch && !VsrModule.IsBareRepository(path))
                {
                    name = name + " " + GetModuleBranch(path, noBranchText);
                }

                var smi = new SubmoduleInfo {
                    Text = name, Path = path
                };
                result.OurSubmodules.Add(smi);
            }
        }