def create_config_(self, index=<NUM_LIT:0>, update=False):
if not self.config_files_[index:]:<EOL><INDENT>return<EOL><DEDENT>path = self.config_files_[index]<EOL>if not path.parent.exists():<EOL><INDENT>path.parent.mkdir(parents=True)<EOL><DEDENT>conf_dict = {}<EOL>for section in self.sections_():<EOL><INDENT>conf_opts = [o for o, m in self[section].defaults_() if m.conf_arg]<EOL>if not conf_opts:<EOL><INDENT>continue<EOL><DEDENT>conf_dict[section] = {}<EOL>for opt in conf_opts:<EOL><INDENT>conf_dict[section][opt] = (self[section][opt] if update else<EOL>self[section].def_[opt].default)<EOL><DEDENT><DEDENT>with path.open('<STR_LIT:w>') as cfile:<EOL><INDENT>toml.dump(conf_dict, cfile)<EOL><DEDENT>
Create config file.

        Create config file in :attr:`config_files_[index]`.

        Parameters:
            index(int): index of config file.
            update (bool): if set to True and :attr:`config_files_` already
                exists, its content is read and all the options it sets are
                kept in the produced config file.