accessmod/utils.py
def parse_config(string) -> dict:
    """Parse config option from CLI.

    Can be a path to a JSON file or a base 64 encoded JSON string. Parsed into a
    dictionary.
    """
    if string.endswith(".json"):
        fs = filesystem(string)
        with fs.open(string) as f:
            logger.info(f"Loading config from file {string}")
            return json.load(f)

    else:
        logger.info("Loading config from string")
        return json.loads(base64.b64decode(string.encode()).decode())
Parse config option from CLI.

    Can be a path to a JSON file or a base 64 encoded JSON string. Parsed into a
    dictionary.
    
Parse config option from CLI.
Can be a path to a JSON file or a base 64 encoded JSON string. Parsed into a
dictionary.
Parse config option from CLI . Can be a path to a JSON file or a base 64 encoded JSON string . Parsed into a dictionary .
def parse_config(string) -> dict:
    if string.endswith(".json"):
        fs = filesystem(string)
        with fs.open(string) as f:
            logger.info(f"Loading config from file {string}")
            return json.load(f)
    else:
        logger.info("Loading config from string")
        return json.loads(base64.b64decode(string.encode()).decode())
def parse_config ( string ) -> dict : if string . endswith ( ".json" ) : fs = filesystem ( string ) with fs . open ( string ) as f : logger . info ( f"Loading config from file {string}" ) return json . load ( f ) else : logger . info ( "Loading config from string" ) return json . loads ( base64 . b64decode ( string . encode ( ) ) . decode ( ) )
Parse config option from CLI.
Parse config option from CLI .
"""Parse config option from CLI.

    Can be a path to a JSON file or a base 64 encoded JSON string. Parsed into a
    dictionary.
    """
string