-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Support quotes and tabs in general API description #743
Conversation
Re-add escaping of quotes when applying template in ReadDoc() Add test for verifying output of ReadDoc()
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
@j0s sorry, because ci check had some issue there before. could you help retry the build again? eg: some minor changes |
Codecov Report
@@ Coverage Diff @@
## master #743 +/- ##
==========================================
- Coverage 84.83% 82.09% -2.75%
==========================================
Files 8 8
Lines 1649 1737 +88
==========================================
+ Hits 1399 1426 +27
- Misses 145 193 +48
- Partials 105 118 +13
Continue to review full report at Codecov.
|
Ok, so I fixed a linting error. But the coverage must be caused by codecov not being run for a while right? It's complaining that coverage of |
Is there anything blocking this from being merged, except for the travis job that does not seem to run? |
I would still like this to be merged if it looks good to you. |
Any movement on this? |
Describe the PR
Handle quotes and tabs in general API description. The two-stage application of templates when generating
docs.go
, and then applying a template inReadDoc()
, resulted in escaping of quotation mark getting lost. This PR re-adds adds those quotations using a less than beautiful workaround, but at least it works on my test cases.It also adds a test that compiles the generated file
docs.go
, runs theReadDoc()
method, and compares the output to a template.Related issue
#738
Additional context
I stumbled upon this when expanding my documentation using markdown. When writing long descriptions, supporting quotation marks and tabs would be very useful.