class Utils::ConfigFile
def parse_config_file(config_file_path)
- Note: - The method will output a warning message to standard error if it fails
Raises:
-
(SystemCallError)
- if there is an issue reading the configuration file
Returns:
-
(Utils::ConfigFile)
- returns self after parsing the configuration file
Parameters:
-
config_file_path
(String
) -- the path to the configuration file to be parsed
def parse_config_file(config_file_path) config_file_path = File.expand_path(config_file_path) File.open(config_file_path) do |cf| parse cf.read end self rescue SystemCallError => e $DEBUG and warn "Couldn't read config file "\ "#{config_file_path.inspect}: #{e.class} #{e}" return nil end