git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Igor Djordjevic <igor.d.djordjevic@gmail.com>
To: Jason Pyeron <jpyeron@pdinc.us>, git@vger.kernel.org
Subject: Re: Rules for backup discussion
Date: Sat, 28 Oct 2017 16:27:51 +0200	[thread overview]
Message-ID: <3028f1a1-1311-b9e2-562f-08817a9daa94@gmail.com> (raw)
In-Reply-To: <C29FBE3637EA47B9AEDD7895339AB8C8@blackfat>

Hi Jason,

On 28/10/2017 14:49, Jason Pyeron wrote:
> I would like to efficiently backup my project directories.
> 
> I am thinking that the backup of a git enabled project should only backup the following sets of files:
> 
> Files under .git/
> The results of git clean -ndx
> The results of git status
> 
> Does this make sense? Is there a less expensive way to calculate the backup file set? I ask because sometime git status takes a long time.

What do you consider being an "efficient backup", which files are you 
actually interested in making the backup of...?

Do you use submodules? If not, and if your backup thoughts show the 
idea of files you want to keep (committed + untracked + ignored + 
modified, basically all of them), I think the easiest approach is to 
just backup the whole project folder - that way you keep committed 
history (".git" subfolder/repository) plus all additional uncommitted 
work as well (untracked/ignored/modified files inside the working 
tree), and no extra calculations are needed.

In case you don`t care about uncommitted stuff, you can just backup 
".git" subfolder (the repository), it keeps project`s whole history, 
with all versions of all the files in it (thus latest included).

Regards,
Buga

      reply	other threads:[~2017-10-28 14:28 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-10-28 12:49 Rules for backup discussion Jason Pyeron
2017-10-28 14:27 ` Igor Djordjevic [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3028f1a1-1311-b9e2-562f-08817a9daa94@gmail.com \
    --to=igor.d.djordjevic@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=jpyeron@pdinc.us \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).