File: //lib/python2.7/site-packages/setuptools/config.pyo
ó
Àfc @@ sú d d l m Z m Z d d l Z d d l Z d d l Z d d l m Z d d l m Z d d l
m Z d d l m
Z
m Z d d l m Z e e d „ Z d „ Z e d
„ Z d e f d „ ƒ YZ d
e f d „ ƒ YZ d e f d „ ƒ YZ d S( i ( t absolute_importt unicode_literalsN( t defaultdict( t partial( t
import_module( t DistutilsOptionErrort DistutilsFileError( t string_typesc C@ sù d d l m } m } t j j | ƒ } t j j | ƒ sM t d | ƒ ‚ n t j ƒ } t j t j j
| ƒ ƒ zl | ƒ } | r | j ƒ n g } | | k r² | j | ƒ n | j
| d | ƒt | | j d | ƒ} Wd t j | ƒ Xt | ƒ S( u, Read given configuration file and returns options from it as a dict.
:param str|unicode filepath: Path to configuration file
to get options from.
:param bool find_others: Whether to search for other configuration files
which could be on in various places.
:param bool ignore_option_errors: Whether to silently ignore
options, values of which could not be resolved (e.g. due to exceptions
in directives such as file:, attr:, etc.).
If False exceptions are propagated as expected.
:rtype: dict
i ( t Distributiont
_Distributionu% Configuration file %s does not exist.t filenamest ignore_option_errorsN( t setuptools.distR R t ost patht abspatht isfileR t getcwdt chdirt dirnamet find_config_filest appendt parse_config_filest parse_configurationt command_optionst configuration_to_dict( t filepatht find_othersR R R t current_directoryt distR
t handlers( ( s5 /usr/lib/python2.7/site-packages/setuptools/config.pyt read_configuration
s$
c C@ s’ t t ƒ } x | D]w } | j } | j } x\ | j D]Q } t | d | d ƒ } | d k ro t | | ƒ } n | ƒ } | | | | <q5 Wq W| S( u» Returns configuration data gathered by given handlers as a dict.
:param list[ConfigHandler] handlers: Handlers list,
usually from parse_configuration()
:rtype: dict
u get_%sN( R t dictt section_prefixt
target_objt set_optionst getattrt None( R t config_dictt handlert obj_aliasR"