Re: ignored file can be deleted silently
- From
Nguyen Thai Ngoc Duy <pclouds@gmail.com>
- Date
- May 5, 2011, 14:18 UTC
- Message-ID
- <BANLkTi=C4pO83mT3pO0B_AMaK3RMOC4V8g@mail.gmail.com>
- In-Reply-To
- <BANLkTinEupQKfBofhH-qKD6gLGWyWRbGvw@mail.gmail.com>
On Thu, May 5, 2011 at 3:40 PM, Daniele Segato <daniele.bilug@gmail.com> wrote:
Show 5 quoted lines
> I noticed that when i put a file in the git ignore If i switch to a > branch where the file is present and versioned git delete my local > ignored file replacing it with the content of the branch I switched > this is done silently and the file is gone forever if I don't have a > copy somewhere
This is on purpose. Commit f8a9d42 (read-tree: further loosen "working file will be lost" check. - 2006-12-04) allowed ignored files to be overwritten. Perhaps we can have a config to tighten the check again?
-- Duy