posener / goreadme

Generate readme file from Go doc. Now available as a Github action!
MIT License
213 stars 31 forks source link

Add option to include the exported types #95

Closed romainbou closed 3 years ago

romainbou commented 3 years ago

New feature to include the types #94 using the -types argument It replaces the body of structs by an ellipsis "...", similarly to go doc

New types section like this:

Types

type Config

type Config struct { ... }

type GoReadme

type GoReadme struct { ... }

GoReadme enables getting readme.md text from a go package.

Fixes #94

codecov[bot] commented 3 years ago

Codecov Report

Merging #95 into master will decrease coverage by 6.57%. The diff coverage is 33.33%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #95      +/-   ##
==========================================
- Coverage   76.08%   69.51%   -6.58%     
==========================================
  Files           3        3              
  Lines          92       82      -10     
==========================================
- Hits           70       57      -13     
- Misses         14       15       +1     
- Partials        8       10       +2     
Impacted Files Coverage Δ
goreadme.go 67.34% <33.33%> (-7.66%) :arrow_down:
godoc.go 53.84% <0.00%> (-8.66%) :arrow_down:
fetcher.go 85.00% <0.00%> (-2.50%) :arrow_down:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 02292f3...7498c51. Read the comment docs.

romainbou commented 3 years ago

Yes indeed, I added a type to pkg1 and a new pkg8_types just for the types