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

About URLs in DESCRIPTION - R-hub blog #47

Open
utterances-bot opened this issue Dec 10, 2019 · 4 comments
Open

About URLs in DESCRIPTION - R-hub blog #47

utterances-bot opened this issue Dec 10, 2019 · 4 comments

Comments

@utterances-bot
Copy link

@utterances-bot utterances-bot commented Dec 10, 2019

About URLs in DESCRIPTION - R-hub blog

https://blog.r-hub.io/2019/12/10/urls/

This comment has been minimized.

Copy link
Contributor

@Bisaloo Bisaloo commented Dec 10, 2019 — with utterances

Great post 😄

It's also worth noting that these URLs are used by pkgdown:

  • the GitHub URL is used to automatically find out the repo containing the source code, and display a handy GitHub icon which links to the repo on the right of the top navbar (with the default theme).
  • the URL to the pkgdown website is used to crosslink to this site from other pkgdown websites, as explained in this vignette, creating a decentralized mesh for documentation, instead of relying on a centralized entity such as http://rdrr.io/.
@maelle

This comment has been minimized.

Copy link
Member

@maelle maelle commented Dec 10, 2019

Thank you @Bisaloo, great points!But if I follow correctly the URL pkgdown uses for the crosslinking has to be in pkgdown config, not in DESCRIPTION?

@Bisaloo

This comment has been minimized.

Copy link
Contributor

@Bisaloo Bisaloo commented Dec 10, 2019

It needs both:

In order for a pkgdown site to be findable, it needs to be listed in two places
[...]
Now, when you build a pkgdown site for a package that links to the dplyr documentation (e.g., dplyr::mutate()), pkgdown looks first in dplyr’s DESCRIPTION to find its website, then it looks for pkgdown.yml, and uses the metadata to generate the corect links.

@maelle

This comment has been minimized.

Copy link
Member

@maelle maelle commented Dec 10, 2019

oooh right now I got it. Say package foo docs mention package bar functions. pkgdown uses the URL in the pkgdown config of package foo when building the docs for package foo. It uses the URL in the DESCRIPTION of package bar and the pkgdown config of package bar when building the docs for package foo. Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.