<commit_before>import os
import ConfigParser

class GogSettings:

    configfile = ""
    data = {}
    
    # creates new settings if they don't already exit
    def __init__(self, path):
        if not os.path.exists(path):
            os.makedirs(path)
        self.configfile = os.path.join(path,"config")
        if not os.path.exists(self.configfile):
            self.obtain_default()
            self.store()
        else:
            self.load()

    def obtain_default(self):
        self.data["install_path"] = os.path.join(os.getenv("HOME"),"games","gog")
        self.data["use_virtual_desktop"] = False
        self.data["profile_update"] = 120
        self.data["virtual_resolution"] = "800x600"
        self.data["access_beta"] = False

    def load(self):
        parser = ConfigParser.ConfigParser()
        parser.read(self.configfile)
        section = "settings"
        for opt in parser.options(section):
            try:
                self.data[opt] = parser.get(section, opt)
            except:
                print "Exception in config parsing on %s " % option
                self.data[opt] = None

    def store(self):
        path = os.path.join(os.getenv("HOME"),".gog-tux")<commit_msg>fixed missing variable in gog_settings<commit_after>import os
import ConfigParser

class GogSettings:

    configfile = ""
    data = {}
    
    # creates new settings if they don't already exit
    def __init__(self, path):
        if not os.path.exists(path):
            os.makedirs(path)
        self.configfile = os.path.join(path,"config")
        if not os.path.exists(self.configfile):
            self.obtain_default()
            self.store()
        else:
            self.load()

    def obtain_default(self):
        self.data["install_path"] = os.path.join(os.getenv("HOME"),"games","gog")
        self.data["use_virtual_desktop"] = False
        self.data["profile_update"] = 120
        self.data["virtual_resolution"] = "800x600"
        self.data["access_beta"] = False

    def load(self):
        parser = ConfigParser.ConfigParser()
        parser.read(self.configfile)
        section = "settings"
        for opt in parser.options(section):
            try:
                self.data[opt] = parser.get(section, opt)
            except:
                print "Exception in config parsing on %s " % opt
                self.data[opt] = None

    def store(self):
        path = os.path.join(os.getenv("HOME"),".gog-tux")
{'fraction_non_alphanumeric': 0.12428919577579203, 'fraction_numerical': 0.007311129163281885, 'mean_word_length': 2.11378002528445, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7428435', 'n_tokens_mistral': 754, 'n_tokens_neox': 715, 'n_words': 151}