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

Re: [Qgit RFC] commit --amend

From
MCMarco Costalba <mcostalba@gmail.com>
Date
Jul 6, 2007, 07:54 UTC
Message-ID
<e5bfff550707060054qdbe7e50ic217b8ed6927408e@mail.gmail.com>
In-Reply-To
<20070704182806.GA3268@efreet.light.src>
On 7/4/07, Jan Hudec <bulb@ucw.cz> wrote:
Show 6 quoted lines
>
> > 3- More robust to API change
> > 4- Less easy to break by changes in git.
>
> Actually, no. The porcelains are more likely to change than the plumbing.
>

Well, changing internal API does not break compatibility, _modifying_ user commands behaviour yes and you need to release a new version for this.

If for "change" you mean adding stuff then, yes, I agree with you, but adding stuff is not a problem.

Show 25 quoted lines
> > Having said that, from '-F' option documentation:
> >
> > -F <file>::
> >       Take the commit message from the given file.  Use '-' to
> >       read the message from the standard input.
> >
> > Jan, what about to use '-' and feed message from stdin?
>
> I actually am, because I am rewriting it to use plumbing, which means
> git-write-tree and git-commit-tree directly. And git-commit-tree always reads
> commit message from stdin.
>
> > Indeed the full signature of run() is:
> >
> > bool Git::run(SCRef runCmd, QString* runOutput, QObject* receiver, SCRef
> > buf)
> >
> > Where the last parameter 'buf' it's a string that, if not empty, is
> > passed to the launched program stdin.
>
> ... except if I read the code correctly, it will create a temporary file
> anyway. The comment in QGit::startProcess says it is because of windows, but
> there is nothing to disable it in Unix, so to me it seems temporary file is
> used anyway.
>
Yes you are right, but the file is redirected to process stdin by the call
proc->setStandardInputFile()

just below the comment you reported. I can assure you it works because to read file names it is used "git diff-tree -r -C --stdin" without problems.

Sorry for mt late reply, but I'm abroad this week and can access the email only seldom.

Marco
Previous: Junio C HamanoNext: Jan Hudec
Message 13 of 17 in “[Qgit RFC] commit --amend”
  1. Jan HudecJun 10, 2007
  2. Marco CostalbaJun 10, 2007
  3. Jan HudecJun 11, 2007
  4. Marco CostalbaJun 11, 2007
  5. Marco CostalbaJun 11, 2007
  6. Jan HudecJul 1, 2007
  7. Marco CostalbaJul 1, 2007
  8. Jan HudecJul 2, 2007
  9. Junio C HamanoJul 4, 2007
  10. Marco CostalbaJul 4, 2007
  11. Jan HudecJul 4, 2007
  12. Junio C HamanoJul 4, 2007
  13. Marco CostalbaJul 6, 2007
  14. Jan HudecJul 5, 2007
  15. Marco CostalbaJul 6, 2007
  16. Jan HudecJul 8, 2007
  17. Marco CostalbaJul 8, 2007

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.