def update_values(new_values, conf_file):

    # make sure the file exists
    open(conf_file, 'a').close()

    with open(conf_file, 'r+b') as output_file:
        # load the config
        json = output_file.read()

        if not json:
            json = '{}'

        config = loads(json)
        config.update(new_values)
        # rewind to the begining of the file
        output_file.seek(0)
        # output the new content, and make sure no extra content is present
        dump(config, output_file, indent=4)
        output_file.truncate()
Update some values in the config file
dataset/ETHPy150Open MrMitch/realdebrid-CLI/rdcli/config.py/update_values