From: Jon Seymour <jon.seymour@gmail.com>
To: Git Mailing List <git@vger.kernel.org>
Cc: Linus Torvalds <torvalds@osdl.org>,
Junio C Hamano <junkio@cox.net>, Petr Baudis <pasky@ucw.cz>
Subject: Semantics of a workspace checkpoint
Date: Thu, 16 Jun 2005 18:21:28 +1000 [thread overview]
Message-ID: <2cfc4032050616012146948b49@mail.gmail.com> (raw)
I'd like to propose these as the semantics for the checkpointing of a workspace
On checkpoint, create a file called:
.git/checkpoint/<treeid>
where the contents of the file are:
exactly identical to the index file immediately prior to the
checkpoint being performed
and the treeid is the tree that results from:
git-update-cache $(git-diff-files | cut -f2)
git-write-tree
To restore from the checkpoint, one does:
/* magic to remove files that are not in the resulting tree */
git-read-tree -m <treeid>
git-checkout-cache -u -f -a
cp .git/checkpoints/<treeid> .git/index
Comments?
--
homepage: http://www.zeta.org.au/~jon/
blog: http://orwelliantremors.blogspot.com/
next reply other threads:[~2005-06-16 8:16 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-06-16 8:21 Jon Seymour [this message]
2005-06-16 8:28 ` Semantics of a workspace checkpoint Petr Baudis
2005-06-16 9:00 ` Jon Seymour
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=2cfc4032050616012146948b49@mail.gmail.com \
--to=jon.seymour@gmail.com \
--cc=git@vger.kernel.org \
--cc=jon@blackcubes.dyndns.org \
--cc=junkio@cox.net \
--cc=pasky@ucw.cz \
--cc=torvalds@osdl.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.