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

protocol: add Accept-Language header if possible

From
Llilinchao@oschina.cn <lilinchao@oschina.cn>
Date
Jun 2, 2022, 03:18 UTC
Message-ID
<2022060211034177301214@oschina.cn>

Git server end's ability to accept Accept-Language header was introduced in f18604bbf2(http: add Accept-Language header if possible) but it seems that only refs discovering stage has this ability: " ╰─$ GIT_CURL_VERBOSE=1 git ls-remote ... 10:42:36.939108 http.c:623              => Send header: GET /opensource/test.git/info/refs?service=git-upload-pack HTTP/1.1 10:42:36.939112 http.c:623              => Send header: Host: gitee.com 10:42:36.939114 http.c:623              => Send header: User-Agent: git/2.35.1.102.g2b9c120970 10:42:36.939116 http.c:623              => Send header: Accept: */* 10:42:36.939117 http.c:623              => Send header: Accept-Encoding: deflate, gzip 10:42:36.939118 http.c:623              => Send header: Accept-Language: en-US, *;q=0.9 10:42:36.939120 http.c:623              => Send header: Pragma: no-cache 10:42:36.939121 http.c:623              => Send header: Git-Protocol: version=2 10:42:36.939123 http.c:623              => Send header: ... 10:42:36.999012 http.c:611              => Send header, 0000000302 bytes (0x0000012e) 10:42:36.999034 http.c:623              => Send header: GET /opensource/test.git/info/refs?service=git-upload-pack HTTP/1.1 10:42:36.999039 http.c:623              => Send header: Host: gitee.com 10:42:36.999041 http.c:623              => Send header: Authorization: Basic <redacted> 10:42:36.999042 http.c:623              => Send header: User-Agent: git/2.35.1.102.g2b9c120970 10:42:36.999044 http.c:623              => Send header: Accept: */* 10:42:36.999063 http.c:623              => Send header: Accept-Encoding: deflate, gzip 10:42:36.999081 http.c:623              => Send header: Accept-Language: en-US, *;q=0.9 10:42:36.999101 http.c:623              => Send header: Pragma: no-cache 10:42:36.999105 http.c:623              => Send header: Git-Protocol: version=2 10:42:36.999106 http.c:623              => Send header: ... 10:42:37.098325 http.c:611              => Send header, 0000000341 bytes (0x00000155) 10:42:37.098368 http.c:623              => Send header: POST /opensource/test.git/git-upload-pack HTTP/1.1 10:42:37.098377 http.c:623              => Send header: Host: gitee.com 10:42:37.098381 http.c:623              => Send header: Authorization: Basic <redacted> 10:42:37.098384 http.c:623              => Send header: User-Agent: git/2.35.1.102.g2b9c120970 10:42:37.098387 http.c:623              => Send header: Accept-Encoding: deflate, gzip 10:42:37.098417 http.c:623              => Send header: Content-Type: application/x-git-upload-pack-request 10:42:37.098421 http.c:623              => Send header: Accept: application/x-git-upload-pack-result 10:42:37.098425 http.c:623              => Send header: Git-Protocol: version=2 10:42:37.098428 http.c:623              => Send header: Content-Length: 118 10:42:37.098431 http.c:623              => Send header: ... " Why git-upload-pack/git-receive-pack stage doesn't enable this ability?

-------------- lilinchao@oschina.cn

Next: lilinchao@oschina.cn
Message 1 of 4 in “protocol: add Accept-Language header if possible”
  1. lilinchao@oschina.cnJun 2, 2022
  2. lilinchao@oschina.cnJun 3, 2022
  3. Junio C HamanoJun 3, 2022
  4. lilinchao@oschina.cnJun 4, 2022

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.