HowTo: git diff mit OpenDocument global für alle Repositories anschalten

  • OpenDocument == Tarball mit viel XML.
  • odt2txt macht aus OpenDocument Text für die Kommandozeile

1. In der ~/.gitconfig die 2 folgenden Zeilen hinzufügen:

[diff "odf"]
      textconv=odt2txt

2. Im Ordner ~/.config/git eine Datei namens “attributes” mit folgendem Inhalt anlegen.

*.ods diff=odf
*.odt diff=odf
*.odp diff=odf
*.odg diff=odf

3. Sicherstellen, dass odt2txt installiert und im Pfad ist.

4. Profit! :-)

git diff $commit-id foo.odg/t/p/f

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.