Fixes #32848 - Support linking to docs.theforeman.org#9756
Fixes #32848 - Support linking to docs.theforeman.org#9756adamruzicka merged 1 commit intotheforeman:developfrom
Conversation
|
Issues: #32848 |
There was a problem hiding this comment.
I think this should be safe, but I'm not 100% sure.
587c3f9 to
1e1e668
Compare
There was a problem hiding this comment.
external_link_url should receive only two parameters: type and options. I think splitting the section out of the options will cause a different output
There was a problem hiding this comment.
Are you sure? The route is includes the section:
Line 558 in df3a0b0
Now I'll immediately admit my knowledge of Rails routing may be lacking, but I don't see a difference between
type and section there, other than that section is optional.
There was a problem hiding this comment.
Well, you are correct:
[9] pry(main)> external_link_path(type: 'foo', section: 'bar', zzz: 'qqq')
=> "/links/foo/bar?zzz=qqq"
As long as it works - I'm good :)
There was a problem hiding this comment.
I didn't check if passing it without a section also works, but I'm assuming it does.
There was a problem hiding this comment.
It does. When no section is passed, the final url does not contain a fragment.
So, as expected.
There was a problem hiding this comment.
I think generally you don't want to link to other flavors, but this is here so you can do something like "this requires Katello, see katello-flavor".
edcc0ce to
545d262
Compare
|
I think this was during the NodeJS 14 migration: [test unit] |
8674e69 to
f26bb3e
Compare
|
Now with more tests. I think this is ready now. |
There was a problem hiding this comment.
It does. When no section is passed, the final url does not contain a fragment.
So, as expected.
adamruzicka
left a comment
There was a problem hiding this comment.
Two nitpicks, but apart from that it works nicely.
adamruzicka
left a comment
There was a problem hiding this comment.
LGTM, let's get this in
An effort is under way to use docs.theforeman.org as the primary documentation source. It is already the official documentation source for Katello, but until now it wasn't easily possible to (correctly) link to it. The documentation is built in 3 flavors: * Katello (index-katello.html) * Debian/Ubuntu (index-deb.html) * Enterprise Linux (index-el.html)
|
Updated tests to stub |
|
Thank you @ekohl, @Thorben-D & @ShimShtein ! |
An effort is under way to use docs.theforeman.org as the primary documentation source. It is already the official documentation source for Katello, but until now it wasn't easily possible to (correctly) link to it.
The documentation is built in 3 flavors:
This is currently untested, but is based on #8613.