Exemple #1
0
        public static bool IsAssemblyAttributesExists(string svnpath, string platform, string projectname, string format)
        {
            ProjectLocation objlocation         = new ProjectLocation();
            string          projectfileLocation = string.Empty;
            bool            isExists            = true;

            projectfileLocation = objlocation.projectPath(svnpath, platform, projectname);
            if (File.Exists((projectfileLocation + "\\AssemblyInfo.cs")))
            {
                isExists = searchAssemblyAttributes(projectfileLocation + "\\AssemblyInfo.cs", format);
            }
            else if (File.Exists(projectfileLocation + "\\Properties\\AssemblyInfo.cs"))
            {
                isExists = searchAssemblyAttributes(projectfileLocation + "\\Properties\\AssemblyInfo.cs", format);
            }
            return(isExists);
        }
Exemple #2
0
        public static bool isDelaysignExists(string svnpath, string platform, string projectname)
        {
            ProjectLocation objlocation         = new ProjectLocation();
            string          projectfileLocation = string.Empty;
            bool            isExists            = true;

            projectfileLocation = objlocation.projectPath(svnpath, platform, projectname);
            if (!platform.ToLower().Equals("silverlight") || (platform.ToLower().Equals("silverlight") && !projectname.ToLower().Contains("dll.design")))
            {
                if (File.Exists((projectfileLocation + "\\AssemblyInfo.cs")))
                {
                    isExists = searchDelaySign(projectfileLocation + "\\AssemblyInfo.cs");
                }
                else if (File.Exists(projectfileLocation + "\\Properties\\AssemblyInfo.cs"))
                {
                    isExists = searchDelaySign(projectfileLocation + "\\Properties\\AssemblyInfo.cs");
                }
            }
            return(isExists);
        }
        /// <summary>
        /// This function retuns the boolean value based on the DefineConstants values which is in project file
        /// </summary>
        /// <param name="svnpath"></param>
        /// <param name="platform"></param>
        /// <param name="projectname"></param>
        /// <returns></returns>
        public bool isDefineConstantMismatch(string svnpath, string platform, string projectname, string VSVersion)
        {
            // Local variables
            bool   isMismatch = false, isSlnMismatch = false;
            string projectfilePath = string.Empty;

            ProjectLocation objLocation     = new ProjectLocation();
            string          projectLocation = string.Empty;

            // Set VS2005 project file location, if platform is equal to windows or base
            projectfilePath = objLocation.projectPath(svnpath, platform, projectname);
            if (platform.ToLower().Equals("windows") || platform.ToLower().Equals("base"))
            {
                projectLocation = projectfilePath + "\\Syncfusion." + projectname + "_2005.csproj";
                if (File.Exists(projectLocation))
                {
                    isMismatch = parsingProjectFile(projectLocation);
                }
            }

            // Set VS2008 project files, if platform is equal to wpf or windows or web or base
            if (platform.ToLower().Equals("base") || platform.ToLower().Equals("wpf") || platform.ToLower().Equals("windows") || platform.ToLower().Equals("web"))
            {
                projectLocation = projectfilePath + "\\Syncfusion." + projectname + "_2008.csproj";
                if (File.Exists(projectLocation))
                {
                    isMismatch = parsingProjectFile(projectLocation);
                }
            }

            // Set VS2010 and VS2012 project files, if platform is not equal to silverlight
            if (!platform.ToLower().Equals("silverlight"))
            {
                projectLocation = projectfilePath + "\\Syncfusion." + projectname + "_" + VSVersion + ".csproj";
                if (File.Exists(projectLocation))
                {
                    isMismatch = parsingProjectFile(projectLocation);
                }
            }

            // Only for silverlight projects
            if (platform.ToLower().Equals("silverlight") && !projectname.ToLower().Contains("dll.design"))
            {
                // For silverlight 4 projects
                projectLocation = projectfilePath + "\\Syncfusion." + projectname + "_2010.csproj";
                if (File.Exists(projectLocation))
                {
                    isMismatch = parsingProjectFile(projectLocation);
                }

                // For silverlight5 projeccts
                projectLocation = projectfilePath + "\\Syncfusion." + projectname + "5_2010.csproj";
                // Check file existence
                if (File.Exists(projectLocation))
                {
                    isMismatch = parsingProjectFile(projectLocation);
                }
            }

            return(isMismatch);
        }