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

Re: git credential management Mac OS

From
Koji Nakamaru <koji.nakamaru@gree.net>
Date
Apr 13, 2025, 03:11 UTC
Message-ID
<CAOTNsDwaVGrpcuT42RUt37NPm9PwnrLz3dJv7JEfRLd4krY_KQ@mail.gmail.com>
In-Reply-To
<CAEbzv6TfMai+vu76Jw157KyMNScwW6pUZaDXbN_u-XRKz_3wnQ@mail.gmail.com>
On Fri, Apr 11, 2025 at 8:14 PM Lukas Michael <lukas.23022005@gmail.com> wrote:
> I want to know if there is a possibility to set my GitHub PAT as
> credential without the need to clone or push a repository at the
> moment. I want to setup my Mac and store the token for further git
> clone / push operations which then need the token.
You can utilize "git credential approve" as below:

cat <<EOF | git credential approve protocol=https host=github.com username=$USER password=$PAT EOF

Koji Nakamaru
Previous: Lukas Michael
Message 2 of 2 in “git credential management Mac OS”
  1. Lukas MichaelApr 11, 2025
  2. Koji NakamaruApr 13, 2025

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.