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

Re: [PATCH v13 02/10] imap-send: add support for OAuth2.0 authentication

From
Junio C Hamano <gitster@pobox.com>
Date
Jun 6, 2025, 17:03 UTC
Message-ID
<xmqqbjr03ipu.fsf@gitster.g>
In-Reply-To
<PN3PR01MB959762A91208AEF089D3302BB86EA@PN3PR01MB9597.INDPRD01.PROD.OUTLOOK.COM>
Aditya Garg <gargaditya08@live.com> writes:
> I was thinking the same but though the code would be more readable
> in case if repeats.

Sorry but I do not understand this comment at all. Not repeating so that you do not have to fix or update all the repetitions later when the code needs to do something different is one of the basics in the software engineering, and less repetitious code is also easier to understnad in the art of software field.

If you start from a 20-line block and repeat it 5 times to grow it 100 lines of code, the eyes of readers will start coasting over after a few repetitions, and you may be able to smuggle unwanted lines unnoticed. Unless you are aiming for such technique to do something malicious, don't go there.

Previous: Aditya GargNext: Aditya Garg
Message 5 of 7 in “Re: [PATCH v13 02/10] imap-send: add support for OAuth2.0 authentication”
  1. Aditya GargJun 6, 2025
  2. Aditya GargJun 6, 2025
  3. Junio C HamanoJun 6, 2025
  4. Aditya GargJun 6, 2025
  5. Junio C HamanoJun 6, 2025
  6. Aditya GargJun 6, 2025
  7. Aditya GargJun 6, 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.