def format_list(str_list):
    """ convert a list of strings to a string with square brackets "[\"something\", \"something\"]"
        which is suitable for subprocess.run
    """
    list_repr = ['\"{}\"'.format(item).replace("\"", "\\\"") for item in str_list]
    joint_str = ",".join(list_repr)
    return joint_str