katrinleinweber / PhD-thesis

Experimental tech-demo for PhD thesis in Scientific Markdown; official:
http://kops.uni-konstanz.de/handle/123456789/34342
MIT License
43 stars 5 forks source link

Git merge conflicts when dealing with narrative text #2

Open kirmaha opened 4 days ago

kirmaha commented 4 days ago

I am gradually implementing a writing workflow based on Markdown and Pandoc. I started using Git to ensure versioning and traceability of my work. However, I've encountered a significant challenge with merge conflicts when working with narrative text, which I suspect you encountered too: Git highlights differences at the line level, which is not ideal for text where small changes, such as punctuation adjustments or spelling corrections. I'm searching for a way to get a better granularity, closer to what is found in the change tracking features of word processors like LibreOffice Writer or MS Word.

I've explored conflict management tools like Meld and KDiff3, which can highlight changes within lines, but both have limitations that make them "not ready" for narrative text (explained respectively here and here).

Given your experience with academic writing, I wonder if you found any effective strategies or tools to manage merge conflicts in Git when dealing with fine modifications in narrative text? Your insights would be greatly appreciated!

katrinleinweber commented 4 days ago

Thanks for sharing your observations, @kirmaha & greeting to 🇧🇪 :-)

I'm not sure anymore, how often I had merge conflicts… 🤔 Certainly, there were some, but I didn't juggle different contributors. So all conflicts must have been triggred by me, probably due to parallelising too many tasks. 🦶🔫

As for merge tools, I bought Kaleidoscope early on. To some extend, it can auto-resolve conflicts. Never having tried another properly, I can't compare it, though.

Also, to avoid conflicts in the first place, I'd suggest to:

  1. break sentences up into multiple lines, see this longer discussion about various approaches.
  2. fix as many little things as possible quickly (before or after content commits). Uusing any spellchecker, LanguageTool (helper one & two), Vale, or similar should help, but overdoing it can distract from the actual writing and your own tone/style/voice.
  3. Not worrying about clean Git history. Some cleanup is possible without conflicts, but even that seems hardly worth the time. Good commit messages on the other hand are a good skill to have!
  4. Good old paper task list, to force as many tasks as possible into a linear sequence.