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

Re: [PATCH_v1] add 'git credential' plumbing command

From
Matthieu Moy <matthieu.moy@grenoble-inp.fr>
Date
Jun 11, 2012, 18:02 UTC
Message-ID
<vpqr4tl4ti9.fsf@bauges.imag.fr>
In-Reply-To
<20120610115619.GA6453@sigill.intra.peff.net>
Jeff King <peff@peff.net> writes:
> It's nice to have an example like this, but there's much detail missing
> in how the format is specified. However, this format is already
> documented in the "helpers" section of api-credentials.txt, so it
> probably makes sense to refer to that document.

I'd do it the other way around. api-credentials.txt is in technical/, while the document we're writing will end-up in a man page, which cannot link to technical/.

So, it makes more sense to move the format specification to git-credential.txt, and link to it from api-credentials.txt (now that we have a nice way to link to manpages from technical/ ;-) ).

Show 9 quoted lines
> I assume this got copied by looking at test-credential. I'd be OK with
> including this feature in git-credential (and converting our test
> scripts to use it, so we can drop test-credential entirely). But
> probably it should not soak up all of the command-line arguments, and
> instead should be a hidden option like:
>
>   git credential --helper=cache fill
>
> That will give us more flexibility later down the road.
Actually, this should already be possible with
  git -c credential.helper=cache credential fill

I suspect that this feature will never be used outside tests, and if so, I don't think it deserves a command-line option.

Show 13 quoted lines
> I am tempted to suggest that this actually output the _whole_
> credential, not just the username and password. Coupled with the above
> behavior, you would get:
>
>   $ git credential fill https://example.com/foo.git
>   protocol=https
>   host=example.com
>   path=foo.git
>   username=bob
>   password=secr3t
>
> which happens to be exactly what you want to feed back to the "approve"
> and "reject" actions (and it is not really any harder to parse).
I like that, yes.
-- 
Matthieu Moy
http://www-verimag.imag.fr/~moy/
Previous: Jeff KingNext: Jeff King
Message 13 of 15 in “[PATCH_v1] add 'git credential' plumbing command”
  1. javier.roucher-iglesias@ensimag.imag.frJun 9, 2012
  2. konglu@minatec.inpg.frJun 9, 2012
  3. roucherjJun 10, 2012
  4. Matthieu MoyJun 10, 2012
  5. Junio C HamanoJun 10, 2012
  6. Matthieu MoyJun 10, 2012
  7. Jonathan NiederJun 10, 2012
  8. Jonathan NiederJun 10, 2012
  9. Junio C HamanoJun 11, 2012
  10. Jeff KingJun 10, 2012
  11. Junio C HamanoJun 11, 2012
  12. Jeff KingJun 11, 2012
  13. Matthieu MoyJun 11, 2012
  14. Jeff KingJun 11, 2012
  15. Matthieu MoyJun 10, 2012

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.