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

Re: [PATCH] Add git-edit-index.perl

From
Junio C Hamano <gitster@pobox.com>
Date
Dec 18, 2008, 21:40 UTC
Message-ID
<7vprjpf9gt.fsf@gitster.siamese.dyndns.org>
In-Reply-To
<20081218140411.GB6706@coredump.intra.peff.net>
Jeff King <peff@peff.net> writes:
Show 7 quoted lines
> On Thu, Dec 18, 2008 at 02:48:39PM +0100, Johannes Schindelin wrote:
>
>> Yes, it is a neat idea.  But I always keep in mind what Junio had to say 
>> about my "add -e" thing (that I use pretty frequently myself): you will 
>> put something into the index that has _never_ been tested.
>> 
>> Would we really want to bless such a workflow with "official" support?

Back in stone ages of git, there wasn't usable tool support to make random unproven commits, later to be tested separately before releasing. The old aversion to committing something that has never existed as a whole in the work tree comes from those days.

The world has changed quite a bit since then, and I do not think the argument holds anymore when better tool support for "commit first, validate and fix-up as needed later" workflow is available.

Show 15 quoted lines
> That is definitely something to be concerned about. Which is why my
> workflow is something like:
>
>   $ hack hack hack
>   $ while ! git diff; do
>       git add -p
>       git commit
>     done
>   $ for i in `git rev-list origin..`; do
>       git checkout $i && make test || barf
>     done
>
> That is, it is not inherently a problem to put something untested into
> the index as long as you are doing it so that you can go back and test
> later.
Yeah, I do not think there is anything inherently wrong about it, either.
Previous: Johannes Schindelin
Message 8 of 8 in “Add git-edit-index.perl”
  1. Add git-edit-index.perlNeil Roberts, Dec 17, 2008
  2. Jeff KingDec 18, 2008
  3. Johannes SchindelinDec 18, 2008
  4. Jeff KingDec 18, 2008
  5. Johannes SchindelinDec 18, 2008
  6. Miklos VajnaDec 18, 2008
  7. Johannes SchindelinDec 18, 2008
  8. Junio C HamanoDec 18, 2008

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.