예제 #1
0
        public void AddAureliaToProject(int templateId, string sourcePath)
        {
            var p       = Path.Combine(ContentRootPath, $"Content\\{templateId}\\patch\\patch.json");
            var results = LoadPatchJson(p);

            //get the users project name from the IDE generated files
            var projectName = GetSourceProjectName(templateId, sourcePath);

            //generate mappings
            var mapModel = new TemplateFileMappingsModel();

            mapModel.ProjectName = projectName;
            mapModel.TemplateId  = templateId;
            tfm = new TemplateFileMapper(mapModel);

            ApplyAureliaPatch(results, templateId, sourcePath);
        }
예제 #2
0
 public TemplateFileMapper(TemplateFileMappingsModel model)
 {
     this.model = model;
     mappings   = GetTemplateMappings(model.TemplateId);
 }