public void GenerateSpecificVersion(RepositoryUrl repositoryUrl, string commit) { var pathResolver = new PathResolver(repositoryUrl.Url, commit); var repositoryFolder = pathResolver.GetRepositoryPath(); var repository = new Repository(repositoryFolder + "/.git"); repository.Checkout(commit); var commitFolder = pathResolver.GetVersionPath(); Directory.CreateDirectory(commitFolder); DirectoryCopy(repositoryFolder, commitFolder, true); repository.Checkout(repository.Branches["master"]); }
public Solution(RepositoryUrl repositoryUrl, string commit) { _repositoryUrl = repositoryUrl; _commit = commit; _pathResolver = new PathResolver(repositoryUrl.Url, commit); _metricServices = new List<MetricService>() { new PowerMetricsService(_pathResolver) }; var solutionFiles = GetVersionPath().SearchFor("*.sln"); SolutionPath = solutionFiles[0].FullName; Projects = GetProjects(); }
public PowerMetricsService(PathResolver pathResolver) : base(pathResolver) { }
private IQueryable<Commit> GetCommits(RepositoryUrl repositoryUrl) { var pathResolver = new PathResolver(repositoryUrl.Url); var repository = new Repository(pathResolver.GetRepositoryPath()); return repository.Commits.OrderByDescending(x => x.Author.When.UtcDateTime).AsQueryable(); }
private void CloneProject(RepositoryUrl repositoryUrl) { var pathResolver = new PathResolver(repositoryUrl.Url); Repository.Clone(repositoryUrl.Url, pathResolver.GetRepositoryPath()); }
protected MetricService(PathResolver pathResolver) { PathResolver = pathResolver; }
public FxCopService(PathResolver pathResolver) : base(pathResolver) { }
public StyleCopService(PathResolver pathResolver) : base(pathResolver) { }