{"thread":{"id":"63282","subject":"git credential management Mac OS","startedAt":"2025-04-11T11:09:47Z","lastAt":"2025-04-13T03:11:38Z","messageCount":2,"participants":["Lukas Michael","Koji Nakamaru"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"515995","messageId":"CAEbzv6TfMai+vu76Jw157KyMNScwW6pUZaDXbN_u-XRKz_3wnQ@mail.gmail.com","threadId":"63282","inReplyTo":null,"subject":"git credential management Mac OS","fromName":"Lukas Michael","fromEmail":"lukas.23022005@gmail.com","sentAt":"2025-04-11T11:09:19Z","receivedAt":"2025-04-11T11:09:47Z","isPatch":false,"sender":{"key":"lukas.23022005@gmail.com","avatar":null},"body":"Dear git kernel team,\n\nI want to know if there is a possibility to set my GitHub PAT as\ncredential without the need to clone or push a repository at the\nmoment. I want to setup my Mac and store the token for further git\nclone / push operations which then need the token.\n\nI hope you can understand my issue 😅\n\nKind regards\n"},{"id":"516056","messageId":"CAOTNsDwaVGrpcuT42RUt37NPm9PwnrLz3dJv7JEfRLd4krY_KQ@mail.gmail.com","threadId":"63282","inReplyTo":"CAEbzv6TfMai+vu76Jw157KyMNScwW6pUZaDXbN_u-XRKz_3wnQ@mail.gmail.com","subject":"Re: git credential management Mac OS","fromName":"Koji Nakamaru","fromEmail":"koji.nakamaru@gree.net","sentAt":"2025-04-13T03:11:26Z","receivedAt":"2025-04-13T03:11:38Z","isPatch":false,"sender":{"key":"koji.nakamaru@gree.net","avatar":"https://avatars.githubusercontent.com/u/2645978?v=4"},"body":"On Fri, Apr 11, 2025 at 8:14 PM Lukas Michael <lukas.23022005@gmail.com> wrote:\n> I want to know if there is a possibility to set my GitHub PAT as\n> credential without the need to clone or push a repository at the\n> moment. I want to setup my Mac and store the token for further git\n> clone / push operations which then need the token.\n\nYou can utilize \"git credential approve\" as below:\n\ncat <<EOF | git credential approve\nprotocol=https\nhost=github.com\nusername=$USER\npassword=$PAT\nEOF\n\nKoji Nakamaru\n"}]}