Why use version control systems for writing a paper?

tl;dr: Version control is harder to set up, but makes it safe to work on the same file, and makes it easy to track history (i.e. previous versions).

Pros and cons of syncing files

Yes, the biggest advantage of things like Dropbox (I use it as well for backuping and synchronizing my files) and SugarSync is their easiness.

They may work for collaboration on files, but:

  • they are not meant for two people editing the same file at once (no merge functionalities - so one guy changing a file can overwrite changes made by other guy, even without knowing that),
  • you get no history, i.e.:
    • did anyone worked on that file I want to work know?
    • did anyone added or modified any other files?
    • which changes were made?
    • can I go to a previous version, the one I sent to my supervisor?

Depending what you do, it may not be an issue. For example, if only one is editing tex file, while others are only reading or uploading figures - it's perfectly fine.

And also, look at my answer on Simplest way to jointly write a manuscript? with a not technically-inclined collaborators.

Version control

Version control systems require some technical skills.

Two the most common version control systems are Git and Mercurial (with the second one being more Windows-friendly and, arguably, easier to start).

Both by standard comes only with command line access, but there are some graphical interfaces as well (I really recommend starting with SourceTree).

So, if the collaborators are techie, just teach them how to use it. If not - there is a way around.

You can keep track of version control by yourself, without engaging others (I'm doing it just now with 2 collaborators).

Just you start a repository inside folder you share (the examples are with Git):

cd ~/path/to/the/folder
git init                    // start git repository inside this folder
git add .                   // say git to track all files inside it

Now, every time you or your collaborator make some changes (e.g. add some files, correct typos, revise a chapter, ...) you do:

git commit -a -m "Fixed typos in Seciton 3"

Later, you will be able to go back to this version; and also compare, e.g. the current version of your file with the previous one (by default - by line, here - by words):

git diff HEAD~1 --color-words my_file.tex

See also:

  • Got 15 minutes and want to learn Git?
  • git + LaTeX workflow at StackOverflow
  • Writing the PhD thesis: the tools Part I
  • Collaborating with LaTeX and git at ShareLaTeX blog - a great and comprehensive tutorial
  • What are the advantages of using version control (git, CVS etc) in LaTeX documents - TeX.SE
  • https://tex.stackexchange.com/search?q=version+control

And real world example from using diff (it makes my life so much easier :)); commit messages in Polish, but I guess you get the idea:

enter image description here

enter image description here

Otherwise (a strip from PhD Comics):

enter image description here


I'm not entirely sure how dropbox and sugar sync work, but their main aim is not to monitor change, but to keep files in sync over a multitude of platforms and to provide backup. In addition, a good version control system allows you to keep older versions, but also to comment on the changes explain why they where made. The version control is also guaranteed to keep the chain of change of a tex file even over very long periods of time (say submitting to journal a, getting rejected, submitting to journal b, getting reviews, new version, acceptance: such a cycle could easily be 1.5 years).

Also, in a Version Control System (VCS) you decided when you want to save a version, in dropbox I can imagine that the system makes that decision. Being in control yourself is important, for example to be able to generate a difference file when resubmitting a paper (see also my answer to this question on TeX SE).

Using a VCS you can also collaborate easily with people. Just create a private repository at bitbucket (supports mercurial and git), arrange for the other authors to have read and/or write access to your tex files in the repository, and they can change the paper or add to it. The VCS will take care of the merging.

I use Mercurial myself for version controlling papers. However, for version controlling a tex file, a VCS might be overkill. I would still recommend Mercurial though.


Given the praise received by version control systems in the existing answers, I’ll play the devil’s advocate here for a second and underline what I think is a very important point: it strongly depends on what your co-authors are comfortable with.

I use version control for most of the projects I do on my own, from code to papers. However, you have to realize that not everyone is familiar with this paradigm, and those who are familiar with it may not be familiar with a given piece of software (I myself am a heavy Subversion user, but have never used Git…). This is particularly true of people who don't develop software, as those tools come from the field of software development. So, check out what your co-authors use and what they are willing to learn. The great thing about a simple synchronization solution (such as DropBox) with no version control is that its learning curve is flat: just agree on a few rules (date-stamp all files, add initials, always send an email when you have created a new version). Anyone can understand that in a minute.

Finally, I'll add another remark: the need for tracking revision history in the short term needs not necessarily require that you record the revision history for the posterity. For example, my incremental backup system (Apple’s Time Machine) creates snapshots of my files history every hour for a day, every day for the past month, and so on. This covers some of the need for tracking older versions in the short term.