Ignored Lines in my GEDCOM file

Take a look at the MultiMergeGramplet, a Gramps addon from the Isotammi project of Finland.

Places category has an automerge option for duplicate places:

The MultiMerge gramplet has different capabilities in the different Categories. For instance, the Notes can combine (collate) the content of near duplicate Notes being merged. (This helps when Notes have identical text but with different markup. Markup cannot be clipboarded between notes but does work within a single note… so long as the ‘active’ focus doesn’t move outside the Note Editor dialog. So a merged note with links and font stylings can be collapsed. (Hint… a Notes gramplet undocked from the Notes category an expanded on a 2nd screen in portrait mode lets you browse through the Note records without having to open and close windows.

There’s also a Tool → Family Tree Processing → Find Possible Duplicate People…. However, it only combines the Person objects. So all the duplicate secondary objects have to be handled separately.