posener / goreadme

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

Add -generated-notice, as suggested by #99Add -generated-file-notice, as suggested by #99 #132

Closed alexandregv closed 3 months ago

alexandregv commented 3 months ago

As suggested by #99, this PR adds a new flag allowing to add a "Generated file" notice in the raw README, via a HTML comment.
This makes the comment invisible in rendered Markdown, but visible when editing the raw file.

CLI flag is -generated-notice and JSON field is generated_notice.
Default value is false (compatible with current behavior).

I feel like this one could be true by default. If true by default, I'm not sure how to implement it with the JSON config, or if I should change it to something like skip-generated-notice?

Any opinion/idea is welcome.

Test has been added too.

Closes #99

codecov[bot] commented 3 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 69.87%. Comparing base (8283e66) to head (03a0d61). Report is 1 commits behind head on master.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #132 +/- ## ======================================= Coverage 69.87% 69.87% ======================================= Files 3 3 Lines 83 83 ======================================= Hits 58 58 Misses 15 15 Partials 10 10 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.