예제 #1
0
파일: hierarchy.py 프로젝트: mottosso/bcore
    def _find_config_files(self):
        """Traverse our configuration directories and obtain all yaml files, which are returned as list"""
        tags = (self._platform_id_short(), str(int_bits()))
        config_paths = list()
        
        for path in self._filter_trees(self.config_trees()):
            config_paths.extend(tagged_file_paths(path, tags, '*' + YAMLKeyValueStoreModifier.StreamSerializerType.file_extension))
        # end for each path in directories

        # Finally, add additional ones on top to allow them to override everything
        config_paths.extend(self._additional_config_files)
        
        # We may have no configuration files left here, as the filter could remove them all (in case they
        # are non-unique)
        # for now, no writer
        return tuple(self._filter_files(config_paths))
예제 #2
0
 def config_fixtures(cls, tag_list):
     """@return all configuration fixture paths which match the given tags"""
     return tagged_file_paths(cls.fixture_path(''), tag_list, '*.yaml')