Teach LockFile how to append to an existing file
commit8d69ae6a2a15f9f65cc76081579f0957a0545035
authorShawn O. Pearce <spearce@spearce.org>
Sun, 27 Apr 2008 20:53:41 +0000 (27 16:53 -0400)
committerShawn O. Pearce <spearce@spearce.org>
Sun, 11 May 2008 05:16:29 +0000 (11 01:16 -0400)
tree9f2787433a2b6bc81d17d9ef35cf3f87b31c1f7d
parentec8cd2e1367320c06c7aae9025ee9df80eb64467
Teach LockFile how to append to an existing file

In some cases we may want to safely append to a file by copying the
current file content into the temporary file, and then leaving the
temporary file available for further writing by the caller.  This is
technique is really only suitable for smaller files, such as the text
based MERGE_HEAD or FETCH_HEAD.  Binary pack files would not be a good
candidate to append onto with this strategy.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
org.spearce.jgit/src/org/spearce/jgit/lib/LockFile.java