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

Re: [RFC] git rm -u

From
TCTomas Carnecky <tomas.carnecky@gmail.com>
Date
Jan 19, 2013, 21:47 UTC
Message-ID
<1358632037-ner-2564@calvin>
In-Reply-To
<50FB1196.2090309@gmail.com>
On Sat, 19 Jan 2013 16:35:18 -0500, Eric James Michael Ritz <lobbyjones@gmail.com> wrote:
Show 24 quoted lines
> Hello everyone,
> 
> I am thinking about implementing a feature but I would appreciate any
> feedback before I begin, because more experienced Git developers and
> users may see some major problem that I do not.
> 
> Earlier today I deleted a file from a repository.  I deleted it
> normally, not by using `git rm`.  So when I looked at `git status` on
> my terminal it told me about the file no longer being there.  In my
> sleepy state of mind I ran `git rm -u` without thinking about.  I did
> this because I have a habit of using `git add -u`.  I know `git rm`
> does not support that option, but I tried it anyways without thinking
> about it.
> 
> When I came to my senses and realized that does not work I began to
> wonder if `git rm -u` should exist.  If any deleted, tracked files are
> not part of the index to commit then `git rm -u` would add that change
> to the index.  This would save users the effort of having to type out
> `git rm <filename>`, and could be useful when a user is deleting
> multiple files.
> 
> Does this sound like a reasonable, useful feature to Git?  Or is there
> already a way to accomplish this which I have missed out of ignorance?
> Any thoughts and feedback would be greatly appreciated.
Does `git add -A` do what you want?
Previous: Eric James Michael RitzNext: Antoine Pelisse
Message 2 of 53 in “[RFC] git rm -u”
  1. Eric James Michael RitzJan 19, 2013
  2. Tomas CarneckyJan 19, 2013
  3. Antoine PelisseJan 19, 2013
  4. Eric James Michael RitzJan 19, 2013
  5. Junio C HamanoFeb 25, 2013
  6. Antoine PelisseFeb 25, 2013
  7. Matthieu MoyFeb 25, 2013
  8. Antoine PelisseFeb 25, 2013
  9. Matthieu MoyFeb 25, 2013
  10. Junio C HamanoFeb 25, 2013
  11. Jonathan NiederJan 19, 2013
  12. Eric James Michael RitzJan 19, 2013
  13. Matthieu MoyJan 20, 2013
  14. Junio C HamanoJan 20, 2013
  15. Junio C HamanoJan 20, 2013
  16. Martin von ZweigbergkJan 20, 2013
  17. Matthieu MoyJan 21, 2013
  18. Junio C HamanoJan 20, 2013
  19. Eric James Michael RitzJan 20, 2013
  20. Piotr KrukowieckiJan 21, 2013
  21. Matthieu MoyJan 21, 2013
  22. Junio C HamanoJan 21, 2013
  23. Junio C HamanoJan 21, 2013
  24. Matthieu MoyJan 21, 2013
  25. Junio C HamanoJan 21, 2013
  26. Piotr KrukowieckiJan 21, 2013
  27. add: warn when -u or -A is used without filepatternMatthieu Moy, Jan 21, 2013
  28. Robin RosenbergJan 21, 2013
  29. Matthieu MoyJan 21, 2013
  30. Robin RosenbergJan 21, 2013
  31. Junio C HamanoJan 21, 2013
  32. Piotr KrukowieckiJan 21, 2013
  33. Matthieu MoyJan 21, 2013
  34. Matthieu MoyJan 21, 2013
  35. Jonathan NiederJan 21, 2013
  36. Matthieu MoyJan 22, 2013
  37. add: warn when -u or -A is used without filepatternMatthieu Moy, Jan 25, 2013
  38. Junio C HamanoJan 25, 2013
  39. Matthieu MoyJan 27, 2013
  40. Junio C HamanoJan 27, 2013
  41. Matthieu MoyJan 28, 2013
  42. add: warn when -u or -A is used without filepatternMatthieu Moy, Jan 28, 2013
  43. Jonathan NiederJan 28, 2013
  44. Michael J GruberJan 28, 2013
  45. Junio C HamanoJan 28, 2013
  46. Matthieu MoyJan 28, 2013
  47. Junio C HamanoJan 28, 2013
  48. Junio C HamanoFeb 14, 2013
  49. Junio C HamanoFeb 14, 2013
  50. Matthieu MoyFeb 15, 2013
  51. Jonathan NiederJan 27, 2013
  52. Duy NguyenJan 22, 2013
  53. Junio C HamanoJan 22, 2013

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.