'Modify given ``conf.py`` file from a whitelisted user\'s project.'

def append_conf(self, **__):

    try:
        self.version.get_conf_py_path()
    except ProjectImportError:
        master_doc = self.create_index(extension='rst')
        self._write_config(master_doc=master_doc)
    try:
        outfile_path = self.project.conf_file(self.version.slug)
        outfile = codecs.open(outfile_path, encoding='utf-8', mode='a')
    except (ProjectImportError, IOError):
        trace = sys.exc_info()[2]
        six.reraise(ProjectImportError('Conf    file    not    found'), None, trace)
    tmpl = template_loader.get_template('doc_builder/conf.py.tmpl')
    rendered = tmpl.render(self.get_config_params())
    with outfile:
        outfile.write('\n')
        outfile.write(rendered)
    self.run('cat', os.path.relpath(outfile_path, self.project.checkout_path(self.version.slug)), cwd=self.project.checkout_path(self.version.slug))
