@staticmethod
def clean_config_for_write(config):
    """Remove args we don't want to save to a config file."""
    ignore = ['name', 'appid', 'argv', 'writepath', 'config', 'debug',
        'oktapreview', 'password_reset', 'command', 'update']
    for var in ignore:
        del config[var]
    if config['accounts'] is None:
        del config['accounts']
    return config
