コード例 #1
0
ファイル: GitRepository.cs プロジェクト: SQureshi33/Demo
        private IDictionary <string, IGitTfsRemote> ReadTfsRemotes()
        {
            // does this need to ensuretfsauthenticated?
            _repository.Config.Set("tfs.touch", "1"); // reload configuration, because `git tfs init` and `git tfs clone` use Process.Start to update the config, so _repository's copy is out of date.
            var remotes = _remoteConfigReader.Load(_repository.Config).Select(x => BuildRemote(x)).ToDictionary(x => x.Id);

            bool shouldExport = GetConfig(GitTfsConstants.ExportMetadatasConfigKey) == "true";

            foreach (var remote in remotes.Values)
            {
                var metadataExportInitializer = new ExportMetadatasInitializer(_globals);
                metadataExportInitializer.InitializeRemote(remote, shouldExport);
            }

            return(remotes);
        }
コード例 #2
0
ファイル: GitRepository.cs プロジェクト: LevShisterov/git-tfs
 private IDictionary <string, IGitTfsRemote> ReadTfsRemotes()
 {
     // does this need to ensuretfsauthenticated?
     _repository.Config.Set("tfs.touch", "1"); // reload configuration, because `git tfs init` and `git tfs clone` use Process.Start to update the config, so _repository's copy is out of date.
     return(_remoteConfigReader.Load(_repository.Config).Select(x => BuildRemote(x)).ToDictionary(x => x.Id));
 }