Parse the config file in a separate method

Preparation for #3