DupeParser

DupeParser generates a list of potential duplicate files based on name. It does this via curated clonelists (currently only retool).

If priorities are present in the retool clonelist, it will use these to prioritise particular release versions versus others

For more details on the DupeParser arguments, see the config file documentation.

API

class romsearch.DupeParser(platform=None, config_file=None, config=None, default_config=None, regex_config=None, logger=None, log_line_sep='=', log_line_length=100)[source]

Tool for figuring out a list of dupes

Parameters:
  • platform (str, optional) – Platform name. Defaults to None, which will throw a ValueError.

  • config_file (str, optional) – Path to config file. Defaults to None

  • config (dict, optional) – Configuration dictionary. Defaults to None

  • default_config (dict, optional) – Default configuration dictionary. Defaults to None

  • regex_config (dict, optional) – Configuration dictionary for regex search. Defaults to None

  • logger (logging.Logger, optional) – Logger instance. Defaults to None

  • log_line_length (int, optional) – Line length of log. Defaults to 100

Todo

  • At some point, we might want to consider adding in the retool supersets

download_retool_dupe(out_file=None, just_date=False)[source]

Download the retool curated list, optionally just returning the last modified date

get_dupe_dict()[source]

Loop through potentially the retool file to get out dupes

get_retool_dupe_dict()[source]

Pull the retool duplicates out of the clonelist file

get_retool_dupes(dupe_dict=None)[source]

Get dupes from the retool curated list

run()[source]

Run the dupe parser