README 2.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. -*- mode:org -*-
  2. #+Title: Org Merge Driver
  3. * Introduction
  4. This is Org Merge Driver, a program for merging changes to Org mode
  5. files.
  6. This project is currently being developed under Google Summer of Code
  7. 2012 for the Gnu organization.
  8. The project page can be found [[http://orgmode.org/worg/org-contrib/gsoc2012/student-projects/git-merge-tool/index.html][here]].
  9. The homepage of Org is [[http://orgmode.org][here]].
  10. * Dependancies
  11. This program requires [[http://www.gnu.org/software/gnulib/][Gnulib]], Flex (not lex) and GNU Autotools to compile.
  12. To obtain Gnulib:
  13. #+begin_src sh
  14. git clone git://git.savannah.gnu.org/gnulib.git
  15. or
  16. cvs -d :pserver:anonymous@pserver.git.sv.gnu.org:/gnulib.git co -d gnulib HEAD
  17. #+end_src
  18. * Compiling
  19. To Compile simply run:
  20. #+begin_src sh
  21. cd $(top_srcdir)
  22. ~/gnulib/gnulib-tool --add-import
  23. autoreconf -i
  24. ./configure && make
  25. #+end_src
  26. * Using
  27. ** Using and Installation
  28. ** Git users:
  29. 1. Add to .git/config of the checkout (or to your ~/.gitconfig) the
  30. lines
  31. #+begin_src
  32. [merge "merge-orgmode"]
  33. name = Org Mode merge driver
  34. driver = /usr/local/bin/org-merge-driver %O %A %B
  35. #+end_src
  36. 2. In every directory with ormode files make a .gitattributes , or
  37. .git/info/attributes if you don't want to have the file committed
  38. with the project. Add the following line to the file:
  39. #+begin_src
  40. *.org merge=merge-orgmode
  41. #+end_src
  42. (See "man 5 gitattributes" for more info.)
  43. ** Bazaar users:
  44. 1. Install the [[http://doc.bazaar.canonical.com/plugins/en/index.html][extmerge bzr plug-in]]
  45. 2. Add to your ~/.bazaar/bazaar.conf the line
  46. #+begin_src
  47. external_merge = org-merge-driver %b %T %o
  48. #+end_src
  49. 3. Then, to merge a conflict in a ChangeLog file, use
  50. #+begin_src
  51. $ bzr extmerge --all --verbose
  52. #+end_src
  53. ** Mercurial users:
  54. 1. Add to your $HOME/.hgrc the lines
  55. #+begin_src
  56. [merge-patterns]
  57. **.org = org-merge-driver
  58. [merge-tools]
  59. org-merge-driver.executable = /usr/local/bin/org-merge-driver
  60. org-merge-driver.args = $base $local $other
  61. #+end_src
  62. See [[http://www.selenic.com/mercurial/hgrc.5.html][Configuration files for Mercurial]], section merge-tools for
  63. reference.