Git and Documentation
When you try to merge a .docx with git, it isint always beautiful.
It get even worst if you try to merge an image or some PDF documents.
I had a few ideas such as:
- one person working on one document at the time and then pushing immediatly,
- always pull before pushing and see what other peoples changed then merge manually and push
- not using git for documentation…
So my question is, how do you manage your documentation with git?
4 Solutions collect form web for “Git and Documentation”
Simple — for documentation, use a plain text format, which is what git is built for. You could use LaTeX, Sphinx, Markdown, or any other number of things. Messy XML formats like .docx will not merge well.
I use a textual format, like Docbook or TeX or HTML or (gasp) text for my documentation.
Docbook in particular generates lots of output formats (HTML, PDF, etc) and is a great standardized way of writing documentation.
You can also use external synchronization to pass virtual updating tokens. We coordinate on irc or mail when we have to do stuff that might conflict.
You can follow the example of Git project: they wrote the user manual in AsciiDoc.
The unhelpful answer is: Don’t try to do such merges. Use an external diff tool that is suitable for the problem format. Or, as other has said, use a format that is amenable to having a plain old merge that won’t cause grief.