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

Re: git-walkthrough-add script

From
Junio C Hamano <gitster@pobox.com>
Date
Jan 5, 2008, 02:50 UTC
Message-ID
<7vprwhf0kf.fsf@gitster.siamese.dyndns.org>
In-Reply-To
<1199500441-sup-4067@south>
William Morgan <wmorgan-git@masanjin.net> writes:
Show 8 quoted lines
> Excerpts from Jeff King's message of Fri Jan 04 13:07:51 -0800 2008:
>> But if you have interface improvement suggestions for "git-add -i" or
>> "git-add -p", I'm sure they would be well-received (post-1.5.4
>> release, of course).
>
> Not to show off my git newbness any more than necessary, but when I run
> both git-add -i and git-add -p, I see exactly the same output and
> interface. Are they meant to be different?
They are meant to be different.
    $ git reset --hard
    $ echo >>Makefile
    $ echo >>psql/Makefile
    $ git add -p
    diff --git a/Makefile b/Makefile
    index a2177bc..eb250b0 100644
    --- a/Makefile
    +++ b/Makefile
    @@ -54,3 +54,4 @@ snapdiff ::
            latest=`ls -1dr $(_snap)/release-????-??-?? | head -n 1` &&
            \
            diff -X dontdiff -ru "$$latest" .
    +
    Stage this hunk [y/n/a/d/?]? ^C
    $ git add -i
               staged     unstaged path
      1:    unchanged        +1/-0 Makefile
      2:    unchanged        +1/-0 psql/Makefile
    *** Commands ***
      1: [s]tatus     2: [u]pdate     3: [r]evert     4: [a]dd
      untracked
      5: [p]atch      6: [d]iff       7: [q]uit       8: [h]elp
    What now> ^C
There may be something broken with your git installation.
Previous: William MorganNext: Junio C Hamano
Message 6 of 16 in “git-walkthrough-add script”
  1. William MorganJan 4, 2008
  2. Jeff KingJan 4, 2008
  3. William MorganJan 4, 2008
  4. Jeff KingJan 4, 2008
  5. William MorganJan 5, 2008
  6. Junio C HamanoJan 5, 2008
  7. Junio C HamanoJan 5, 2008
  8. William MorganJan 5, 2008
  9. Pedro MeloJan 5, 2008
  10. Pedro MeloJan 4, 2008
  11. Junio C HamanoJan 4, 2008
  12. William MorganJan 5, 2008
  13. Pedro MeloJan 5, 2008
  14. Miklos VajnaJan 5, 2008
  15. William MorganJan 5, 2008
  16. Jeff KingJan 5, 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.