def _is_already_configured ( configuration_details ) : path = Path ( configuration_details . path ) . expanduser ( ) with path . open ( 'r' ) as shell_config : return configuration_details . content in shell_config . read ( )
check config value is defined in python
Returns True when alias already in shell config .
def _is_already_configured(configuration_details):
    """Returns `True` when alias already in shell config."""
    path = Path(configuration_details.path).expanduser()
    with path.open('r') as shell_config:
        return configuration_details.content in shell_config.read()