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

Fix broken YARD documents #1484

Merged
merged 14 commits into from
Feb 12, 2024
Merged

Fix broken YARD documents #1484

merged 14 commits into from
Feb 12, 2024

Conversation

manicmaniac
Copy link
Member

@manicmaniac manicmaniac commented Feb 12, 2024

Overview

Close #1483

Currently API document hosted in https://rubydoc.info/gems/danger/ looks broken.

  • All comments are written in GitHub-Flavored Markdown but YARD recognizes them as RDoc
  • There's some typos, misindentations and misused tags

This PR fixes those problems.

Screenshots

before after
image image

@manicmaniac manicmaniac force-pushed the fix-yard-doc branch 2 times, most recently from fe3c943 to d57adb2 Compare February 12, 2024 09:34
@manicmaniac manicmaniac self-assigned this Feb 12, 2024
@manicmaniac manicmaniac force-pushed the fix-yard-doc branch 2 times, most recently from dc4f9b2 to 7d5d818 Compare February 12, 2024 14:36
Comment on lines +3 to +4
--tag tags:tags
--tag availability:availability
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It does the same as PluginParser does but in the command-line option form.

YARD::Tags::Library.define_tag('tags', :tags)
YARD::Tags::Library.define_tag('availability', :availability)

@@ -13,12 +13,13 @@ module Danger
# If it's not called again on subsequent runs.
#
# Each of `message`, `warn`, `fail` and `markdown` support multiple passed arguments
# @example
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@example tag needs the title.

@@ -46,6 +46,8 @@ def messages_are_equivalent(m1, m2)
m1 == m2
end

# @endgroup
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Without @endgroup, the rest lines in this file are treated as in the same group.

@manicmaniac manicmaniac marked this pull request as ready for review February 12, 2024 14:55
@manicmaniac manicmaniac merged commit 1efd102 into danger:master Feb 12, 2024
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

YARD document does not render Markdown
2 participants