Esempio n. 1
0
        public async Task AnalyzeUpdatesAsync(string gitDiffOutput)
        {
            var solutionFolder    = Path.GetDirectoryName(solutionPath);
            var modifiedDocuments = gitDiffOutput.Split('\n')
                                    .Where(docPath => !string.IsNullOrEmpty(docPath))
                                    .Select(docPath => docPath.Replace("/", @"\"))
                                    .Select(docPath => Path.Combine(solutionFolder, docPath))
                                    .ToList();

            await analyzer.ApplyModificationsAsync(modifiedDocuments);
        }
Esempio n. 2
0
        private void UpdateAnalysis()
        {
            var solutionFolder    = Path.GetDirectoryName(solutionPath);
            var modifiedDocuments = gitDiffOutput.Split('\n')
                                    .Where(docPath => !string.IsNullOrEmpty(docPath))
                                    .Select(docPath => docPath.Replace("/", @"\"))
                                    .Select(docPath => Path.Combine(solutionFolder, docPath))
                                    .ToList();

            Console.WriteLine("Starting incremental analysis...");

            analyzer.ApplyModificationsAsync(modifiedDocuments).Wait();

            Console.WriteLine("Incremental analysis finish");

            //var callGraph = analyzer.GenerateCallGraphAsync().Result;
            //callGraph.Save(CallGraphPath);
        }