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
[Doc] Link to doc/contributing.rdoc from CONTRIBUTING.md #4266
Conversation
CONTRIBUTING.md
Outdated
|
||
[official issue tracker]: https://bugs.ruby-lang.org | ||
[contributing.rdoc]: https://github.com/ruby/ruby/blob/master/doc/contributing.rdoc |
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.
Shouldn't it be a link to the local file?
[contributing.rdoc]: https://github.com/ruby/ruby/blob/master/doc/contributing.rdoc | |
[contributing.rdoc]: rdoc-ref:contributing.rdoc |
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.
Oh, I don't know the feature rdoc-ref
! 😮
Is it a RDoc
feature? So can't we use it in Markdown?
https://github.com/ruby/ruby/blob/db0ad48309edae28a65e3d18e9b3a15753eda777/doc/NEWS-3.0.0.md
Above doc having similar style, it shows GFM as below
And this change so on...
c5795c3
https://github.com/ruby/ruby/blob/c5795c37e61de30df15501e48ad61167e5841953/CONTRIBUTING.md
Do we need to handle .md
files as a rdoc in this repository?
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.
It is possible in also RDoc's Markdown, but GitHub doesn't support it of course, even in *.rdoc files.
In RDoc, "rdoc-ref:" link generates a URL from the path under the certain rule.
I made ruby/rdoc#800 to enable it for explicit references without the prefix.
Once this gets applied, the above link no longer needs the prefix.
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.
Thank you for the rdoc improvement! 😂
I have applied your suggestion cc779f4
$ rdoc --version
6.3.0
$ rdoc CONTRIBUTING.md --op tmp-rdoc
$ open tmp-rdoc/CONTRIBUTING_md.html
It looks not a link 🤔
It makes same even if adding doc/
prefix as rdoc-ref:doc/contributing.rdoc
.
But https://docs.ruby-lang.org/en/master/doc/NEWS-3_0_0_md.html shows as link.
Hmm… Definitely I do not know something about rdoc 🙇
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.
ruby/rdoc#800 is not merged yet.
And it doesn't change the result for "rdoc-ref:", the line needs to be [doc/contributing.rdoc]: doc/contributing.rdoc
without the schema prefix.
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.
https://github.com/ruby/ruby/blob/f2ad63b361236df26aae33a19c851f106e752b1b/CONTRIBUTING.md
Ah… I may understand it finally. 😓
f2ad63b is this correct understanding?
I didn't know Markdown can use relative path, This is so useful!
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.
Exactly.
This patch by nobu (Nobuyoshi Nakada) ref: ruby#4266 (comment) Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org>
This patch by nobu (Nobuyoshi Nakada), thank you! ref: ruby#4266 (comment) Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org>
cc779f4
to
f2ad63b
Compare
Thank you! 🙏 Of course I am appreciating to ruby/rdoc#800 😂 |
https://github.com/ruby/ruby/blob/c7e6914b3947cdf0e9c0d28d1162a084d0138887/doc/contributing.rdoc looks the active one of
How to contribute
. So adding link inCONTRIBUTING.md
might help someone like me 🙏In my case...
I often forgot
How to test specific test file with the built ruby?
Nothing in README. And I can't find it in https://bugs.ruby-lang.org/projects/ruby/wiki/HowToContribute
But the rdoc describes as below.
It solved all.☺️