line1 = "['a.b.c','b.c.a','c.d.e']"
line2 = "['def','efg']"
line3 = "['f']"
line4 = "['g']"
SumLine = []
for x in (line1, line2, line3, line4):
    SumLine.extend(ast.literal_eval(x))
print(SumLine)
Convert and merge strings into a list in Python