Ejemplo n.º 1
0
        private async Task <TargetsScriptInjector> GetNewTargetsBuildScriptSupportInjector()
        {
            var logger  = Dte.GetLogger();
            var project = GetSelectedProject();
            var result  = new TargetsScriptInjector(project,
                                                    await VsFileSystemManipulatorFactory.GetFileSystemManipulatorForEnvironment(project),
                                                    logger, GetNativeWindow());

            return(result);
        }
Ejemplo n.º 2
0
        private async Task <BuildTimeTransformationsEnabler> GetTransformationsEnabler(Project project)
        {
            string projectName     = null;
            string projectFullName = null;

            try
            {
                projectName     = project.Name;
                projectFullName = project.FullName;
            }
            catch { }
            if (string.IsNullOrEmpty(projectName) || string.IsNullOrEmpty(projectFullName))
            {
                return(null);
            }
            var logger = Dte.GetLogger();
            var io     = await VsFileSystemManipulatorFactory.GetFileSystemManipulatorForEnvironment(project);

            var nativeWindow = GetNativeWindow();

            Debug.Assert(project != null, "project != null");
            return(new BuildTimeTransformationsEnabler(project, logger, io, nativeWindow));
        }