I am processing a polyline file that contains multiple lines representing city roads. I would like to join the lines together into as few lines as possible. I've tried using the 'join multiple lines' plugin, but that creates additional lines that I do not want. Is there a way to only join all the lines that have the exact same endpoint/startpoint?
For context, I'm printing the vector file to a laser engraver. Unfortunately the laser engraver draws the lines in a (seemingly) random order, resulting in a very long print time (hours). I am trying to join the lines together to force the printer to draw connected lines in a logical order. I've tried the 'merge' command, but this hasn't worked because it doesn't change the order of the actual nodes.
I am using QGIS but am open to using other open source software to solve this problem.