def configset(config, section, var, value, overwrite=False):
    """
    Sets a string in the in memory representation of the config object
    Deos NOT overwrite existing values if overwrite is set to False (default)

    Input:
        - config - python ConfigParser object
        - section - section in the file
        - var - variable (key) to set
        - value - the value to set
        - overwrite (optional, default is False)

    Returns:
        - nothing

    """
    if not config.has_section(section):
        config.add_section(section)
        config.set(section, var, value)
    elif not config.has_option(section, var):
        config.set(section, var, value)
    elif overwrite:
        config.set(section, var, value)
