To make clean-up less painful in Sigil, I did the following:
1. Open Sigil, turn off Preview
2. Use Sigil to load the epub
3. Go make coffee while Sigil loads the one huge line :-)
4. Immediately after it finally open, do nothing except:
Right click in the window and select Mend
5. Go refill your coffee :-)
Sigil should now be able to at least function a bit more rapidly now that the file is not just one giant single line.
6. Use Find and Replace to insert a Sigil Split Marker
Code:
<hr class="sigil_split_marker" />
immediately before each "<h1", and then split on split markers.
7. Turn back on Preview
You are finally back to something still very horrible but workable.