Skip to content

Template-extractor #50

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Apr 30, 2025
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
demo generator changes to create artifacts.
  • Loading branch information
Priya-Solanki committed Apr 1, 2025
commit 07a7e7f5b817e98a667a729bb2bb048dc3f615b7
5 changes: 5 additions & 0 deletions src/ADOGenerator/ADOGenerator.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@

<ItemGroup>
<Compile Remove="IServices\IConfiguration.cs" />
<Compile Remove="Models\Configuration.cs" />
</ItemGroup>
<ItemGroup>
<!-- Include the files you want to copy -->
Expand Down Expand Up @@ -87,4 +88,8 @@
</None>
</ItemGroup>

<ItemGroup>
<Folder Include="ExtractedTemplate\" />
</ItemGroup>

</Project>
32 changes: 32 additions & 0 deletions src/ADOGenerator/IServices/IExtractorService.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
using ADOGenerator.Models;
using RestAPI;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ADOGenerator.IServices
{
public interface IExtractorService
{
ProjectConfigurations ProjectConfiguration(Project model);
int GetTeamsCount(ProjectConfigurations appConfig);
int GetIterationsCount(ProjectConfigurations appConfig);
int GetBuildDefinitionCount(ProjectConfigurations appConfig);
int GetReleaseDefinitionCount(ProjectConfigurations appConfig);
string[] GenerateTemplateArifacts(Project model);
Dictionary<string, int> GetWorkItemsCount(ProjectConfigurations appConfig);
List<RequiredExtensions.ExtensionWithLink> GetInstalledExtensions(ProjectConfigurations appConfig);
void ExportQuries(ProjectConfigurations appConfig);
bool ExportTeams(RestAPI.ADOConfiguration con, Project model);
bool ExportIterations(ProjectConfigurations appConfig);
void ExportWorkItems(ProjectConfigurations appConfig);
void ExportRepositoryList(ProjectConfigurations appConfig);
int GetBuildDefinitions(ProjectConfigurations appConfig);
int GeneralizingGetReleaseDefinitions(ProjectConfigurations appConfig);
void GetServiceEndpoints(ProjectConfigurations appConfig);
void ExportDeliveryPlans(ProjectConfigurations appConfig);

}
}
3 changes: 3 additions & 0 deletions src/ADOGenerator/IServices/IProjectService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ public interface IProjectService
public bool InstallExtensions(Project model, string accountName, string PAT);

public bool WhereDoseTemplateBelongTo(string templatName);
public HttpResponseMessage GetProjects(string accname, string pat, string authScheme);

public Task<List<string>> SelectProject(string accessToken, HttpResponseMessage projectsData);

}
}
6 changes: 5 additions & 1 deletion src/ADOGenerator/IServices/ITemplateService.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
namespace ADOGenerator.IServices
using ADOGenerator.Models;

namespace ADOGenerator.IServices
{
public interface ITemplateService
{
bool AnalyzeProject(Project model);
bool StartEnvironmentSetupProcess(Project model);
}
}
18 changes: 18 additions & 0 deletions src/ADOGenerator/Models/ExtractorAnalysis.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ADOGenerator.Models
{
internal class ExtractorAnalysis
{
public int teamCount { get; set; }
public int IterationCount { get; set; }
public int BuildDefCount { get; set; }
public int ReleaseDefCount { get; set; }
public Dictionary<string, int> WorkItemCounts { get; set; }
public List<string> ErrorMessages { get; set; }
}
}
Loading