git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Git allow to unconditionaly remove files on other developer host

From
KKES <kes-kes@yandex.ru>
Date
Apr 15, 2017, 11:36 UTC
Message-ID
<4747541492256174@web25g.yandex.ru>
Hi.
That curious, but git allow to unconditionally delete files on other developer host when he do `git pull`
How to reproduce:
1. File should be ignored:
echo "somefile" >> .gitignore
2. Add this ignored file into repository
git add -f somefile
3. Push changes to origin
git push
4. When other developer has also 'somefile' on his host and when he does
git pull
Content of hist local `somefile` file will be replaced by content pushed by first developer
EXPECTED: git should warn about that content will be replaced and do not pull/checkout until we force pull/checkout
Next: Johannes Sixt
Message 1 of 4 in “Git allow to unconditionaly remove files on other developer host”
  1. KESApr 15, 2017
  2. Johannes SixtApr 15, 2017
  3. Konstantin KhomoutovApr 15, 2017
  4. KESJan 6, 2018

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.