Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

Tag regions of Asciidoctor snippets to allow their contents to be selectively included

Aperta
#495 3 commenti 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
30/100
Tipo di issue
Funzionalità
Chiarezza
Abbastanza chiara
Stato di attività
Ferma
Ambito
documentation

Direzione di ricerca

Start by reviewing the generated http-response.adoc and the related snippet files: curl-request.adoc, http-request.adoc, httpie-request.adoc, request-body.adoc, and response-body.adoc. Read the linked Asciidoctor tagged-regions documentation to understand the proposed inclusion mechanism. Done means documenting response headers separately, either through a dedicated snippet or selectable tagged regions, without brittle line ranges.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

type: enhancement

When documenting some endpoint which returns protobuf format, I'd find it useful to be able to document the response headers without the body. Currently this is what I get:

HTTP/1.1 200 OK
Content-Type: application/x-protobuf
X-Protobuf-Schema: proto1.proto
X-Protobuf-Message: com.org.project.Proto1
Content-Length: 226


�
GBP�"33.31*
GBP�2
GBP��

Sadly, the automatically generated snippets are:

  • curl-request.adoc
  • http-request.adoc
  • http-response.adoc
  • httpie-request.adoc
  • request-body.adoc
  • response-body.adoc

Note that there is not one that includes just the response headers without the body. I can work around this in a slightly hacky way by doing my include like this include::filename.txt[lines=0..5] however, obviously this is a little brittle if new headers should appear and I don't update this to include them (they will be chopped off).

I'd like to request as a feature either:

  1. Adding a new snippet with just the response headers and no body.
  2. Ascii doctors seems to support a concept of tagged regions as seen here: https://asciidoctor.org/docs/user-manual/#by-tagged-regions which would allow the http-response.adoc to potentially include tags for the headers and body which could then improve how I can include just the headers.
Lingua principale
Java
Stelle
1.2k
Fork
733
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di spring-projects/spring-restdocs

Tutte le issue di spring-projects/spring-restdocs

Issue simili

Altre issue su Java

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.