Beispiel #1
0
        private bool IsPackageConfigFile(AbsolutePath path)
        {
            Contract.Requires(path.IsValid);

            var name = path.GetName(Context.PathTable).ToString(Context.StringTable);

            return(ExtensionUtilities.IsModuleConfigurationFile(name));
        }
Beispiel #2
0
        private static RuleAnalysisScope GetFileScope(ISourceFile file)
        {
            var fileName = Path.GetFileName(file.Path.AbsolutePath);

            if (ExtensionUtilities.IsModuleConfigurationFile(fileName))
            {
                return(RuleAnalysisScope.PackageConfig);
            }

            if (ExtensionUtilities.IsGlobalConfigurationFile(fileName))
            {
                return(RuleAnalysisScope.RootConfig);
            }

            if (ExtensionUtilities.IsBuildListFile(fileName))
            {
                return(RuleAnalysisScope.BuildListFile);
            }

            return(RuleAnalysisScope.SpecFile);
        }
Beispiel #3
0
 private static bool IsModuleConfigFileName(PathAtom fileName, StringTable stringTable)
 {
     return(ExtensionUtilities.IsModuleConfigurationFile(fileName.ToString(stringTable)));
 }