{"thread":{"id":"7831","subject":"git-ls-files -m lists the same file multiple times","startedAt":"2007-04-25T09:35:26Z","lastAt":"2007-04-25T20:47:10Z","messageCount":5,"participants":["Andy Parkins","Junio C Hamano"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"40393","messageId":"200704251035.33713.andyparkins@gmail.com","threadId":"7831","inReplyTo":null,"subject":"git-ls-files -m lists the same file multiple times","fromName":"Andy Parkins","fromEmail":"andyparkins@gmail.com","sentAt":"2007-04-25T09:35:26Z","receivedAt":"2007-04-25T09:35:26Z","isPatch":false,"sender":{"key":"andyparkins@gmail.com","avatar":null},"body":"Hello,\n\nI did a merge, which had conflicts, and then fixed the conflicts.  To see what \nfiles I'd changed I did git-ls-files -m.  This listed the same file multiple \ntimes.  Some of them twice and some of them three times.\n\nI guess that it's showing different stages; but as the list is just filename, \nthere is no way to tell which is which and it is just confusing.\n\n\nAndy\n-- \nDr Andy Parkins, M Eng (hons), MIET\nandyparkins@gmail.com\n"},{"id":"40417","messageId":"7v8xcgz4ye.fsf@assigned-by-dhcp.cox.net","threadId":"7831","inReplyTo":"200704251035.33713.andyparkins@gmail.com","subject":"Re: git-ls-files -m lists the same file multiple times","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2007-04-25T18:25:45Z","receivedAt":"2007-04-25T18:25:45Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Andy Parkins <andyparkins@gmail.com> writes:\n\n> I did a merge, which had conflicts, and then fixed the conflicts.  To see what \n> files I'd changed I did git-ls-files -m.  This listed the same file multiple \n> times.  Some of them twice and some of them three times.\n>\n> I guess that it's showing different stages; but as the list is just filename, \n> there is no way to tell which is which and it is just confusing.\n\nI did not imagine that anybody actually found 'ls-files -m'\nuseful, either during a conflicted merge or under the normal\nsituation.  'git diff --stat' is usually much more pleasant to\nsee.\n\nUse 'ls-files -u' during conflicted merge and be happy.\n"},{"id":"40419","messageId":"200704251952.07644.andyparkins@gmail.com","threadId":"7831","inReplyTo":"7v8xcgz4ye.fsf@assigned-by-dhcp.cox.net","subject":"Re: git-ls-files -m lists the same file multiple times","fromName":"Andy Parkins","fromEmail":"andyparkins@gmail.com","sentAt":"2007-04-25T18:52:04Z","receivedAt":"2007-04-25T18:52:04Z","isPatch":false,"sender":{"key":"andyparkins@gmail.com","avatar":null},"body":"On Wednesday 2007, April 25, Junio C Hamano wrote:\n> Andy Parkins <andyparkins@gmail.com> writes:\n> > I did a merge, which had conflicts, and then fixed the conflicts. \n> > To see what files I'd changed I did git-ls-files -m.  This listed\n> > the same file multiple times.  Some of them twice and some of them\n> > three times.\n> >\n> > I guess that it's showing different stages; but as the list is just\n> > filename, there is no way to tell which is which and it is just\n> > confusing.\n>\n> I did not imagine that anybody actually found 'ls-files -m'\n> useful, either during a conflicted merge or under the normal\n> situation.  'git diff --stat' is usually much more pleasant to\n> see.\n\nDefinitely.  You see I am in the strange position of being able to type \nfaster than I can think, so typing\n\n git-ls-files -m | xargs git add\n\nSaves me the trouble of engaging my brain :-)\n\n> Use 'ls-files -u' during conflicted merge and be happy.\n\nGreat stuff - that's the one I wanted; in fact git-ls-files -m did what \nI wanted, because it didn't matter that xargs listed the same file \nmultiple times.\n\nThanks\n\n\nAndy\n\n-- \nDr Andy Parkins, M Eng (hons), MIET\nandyparkins@gmail.com\n"},{"id":"40425","messageId":"7v8xcgxnun.fsf@assigned-by-dhcp.cox.net","threadId":"7831","inReplyTo":"200704251952.07644.andyparkins@gmail.com","subject":"Re: git-ls-files -m lists the same file multiple times","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2007-04-25T19:20:32Z","receivedAt":"2007-04-25T19:20:32Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Andy Parkins <andyparkins@gmail.com> writes:\n\n> Definitely.  You see I am in the strange position of being able to type \n> faster than I can think, so typing\n>\n>  git-ls-files -m | xargs git add\n>\n> Saves me the trouble of engaging my brain :-)\n\nWell, I do not think being able to type faster is so unique.  I\nknow more than a handful people who share that ;-).\n\nYou can use \"git add -u\" in 1.5.2 ;-)\n"},{"id":"40449","messageId":"200704252147.12000.andyparkins@gmail.com","threadId":"7831","inReplyTo":"7v8xcgxnun.fsf@assigned-by-dhcp.cox.net","subject":"Re: git-ls-files -m lists the same file multiple times","fromName":"Andy Parkins","fromEmail":"andyparkins@gmail.com","sentAt":"2007-04-25T20:47:10Z","receivedAt":"2007-04-25T20:47:10Z","isPatch":false,"sender":{"key":"andyparkins@gmail.com","avatar":null},"body":"On Wednesday 2007, April 25, Junio C Hamano wrote:\n\n> Well, I do not think being able to type faster is so unique.  I\n> know more than a handful people who share that ;-).\n\n:-) Absolutely - not thinking laterally enough there was I?\n\n> You can use \"git add -u\" in 1.5.2 ;-)\n\nAhead of me again. :-) good stuff.\n\n\nAndy\n-- \nDr Andy Parkins, M Eng (hons), MIET\nandyparkins@gmail.com\n"}]}