Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hide line support in @snip directive #157

Closed
2m opened this issue Oct 5, 2017 · 2 comments
Closed

Hide line support in @snip directive #157

2m opened this issue Oct 5, 2017 · 2 comments

Comments

@2m
Copy link
Contributor

2m commented Oct 5, 2017

The old sphinx doc tool-chain in akka-http supported hiding arbitrary code lines from inclusion in the snippets by adding a // hide to the end of the line. This is now lacking in the current @snip directive. Instead current akka-http docs contain // hide comments in some of the pages, like this one.

There are 18 such comments in the akka-http docs currently.

docs/src/test/scala/docs/http/scaladsl/HttpServerExampleSpec.scala:                complete("") // hide
docs/src/test/scala/docs/http/scaladsl/server/CaseClassExtractionExamplesSpec.scala:          null // hide
docs/src/test/scala/docs/http/scaladsl/server/CaseClassExtractionExamplesSpec.scala:    Get("/color?red=1&green=2&blue=3") ~> route ~> check { responseAs[String] shouldEqual "Color(1,2,3)" } // hide
docs/src/test/scala/docs/http/scaladsl/server/CaseClassExtractionExamplesSpec.scala:          null // hide
docs/src/test/scala/docs/http/scaladsl/server/CaseClassExtractionExamplesSpec.scala:    Get("/color?red=1&green=2&blue=3") ~> route ~> check { responseAs[String] shouldEqual "Color(1,2,3)" } // hide
docs/src/test/scala/docs/http/scaladsl/server/CaseClassExtractionExamplesSpec.scala:          null // hide
docs/src/test/scala/docs/http/scaladsl/server/CaseClassExtractionExamplesSpec.scala:    Get("/color/abc?r=1&g=2&b=3") ~> route ~> check { responseAs[String] shouldEqual "Color(abc,1,2,3)" } // hide
docs/src/test/scala/docs/http/scaladsl/server/DirectiveExamplesSpec.scala:    verify(route) // hide
docs/src/test/scala/docs/http/scaladsl/server/DirectiveExamplesSpec.scala:    verify(route) // hide
docs/src/test/scala/docs/http/scaladsl/server/DirectiveExamplesSpec.scala:    verify(route) // hide
docs/src/test/scala/docs/http/scaladsl/server/DirectiveExamplesSpec.scala:    verify(route) // hide
docs/src/test/scala/docs/http/scaladsl/server/DirectiveExamplesSpec.scala:    verify(route) // hide
docs/src/test/scala/docs/http/scaladsl/server/DirectiveExamplesSpec.scala:    verify(route) // hide
docs/src/test/scala/docs/http/scaladsl/server/DirectiveExamplesSpec.scala:    verify(route) // hide
docs/src/test/scala/docs/http/scaladsl/server/DirectiveExamplesSpec.scala:    verify(route) // hide
docs/src/test/scala/docs/http/scaladsl/server/ExceptionHandlerExamplesSpec.scala:        null // hide
docs/src/test/scala/docs/http/scaladsl/server/ExceptionHandlerExamplesSpec.scala:      null // hide
docs/src/test/scala/docs/http/scaladsl/server/RejectionHandlerExamplesSpec.scala:      null // hide
@2m 2m added the enhancement label Oct 5, 2017
@bantonsson
Copy link
Contributor

bantonsson commented Oct 5, 2017

This is available if you write // #hide instead (or actually // #whateveryoulike), but maybe you wan't to join the discussion in #149

@2m
Copy link
Contributor Author

2m commented Oct 6, 2017

Roger. Fixed the issue in akka-http: akka/akka-http#1457

@ennru ennru added this to the invalid/not release-bound milestone Nov 5, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants