Is Rsyncing git repo good enough backup solution?

后端 未结 3 604
太阳男子
太阳男子 2020-12-29 14:04

I often backup my laptop to an external hard drive. Is rsyncing git repos over good enough backup solution or are there any problems with this method?

3条回答
  •  无人及你
    2020-12-29 14:48

    rsync is a good solution for this. It may be a good idea to run git gc and git repack (neither with any arguments) before doing your backup; this may significantly reduce the number of files, and increase the chance of the data not changing too much by next time. Neither will lose any data.

    See http://sethrobertson.github.com/GitBestPractices/#backups for a write-up of why doing this with git isn't such a good solution.

提交回复
热议问题