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

Idea: browse_package() #1303

Closed
pat-s opened this issue Apr 13, 2020 · 2 comments
Closed

Idea: browse_package() #1303

pat-s opened this issue Apr 13, 2020 · 2 comments

Comments

@pat-s
Copy link
Contributor

pat-s commented Apr 13, 2020

EDIT: This was aimed to be an issue in usethis, not pkgdown. Can someone please transfer it? Thanks and sorry. 😆

I often find myself in the situation wanting to browse the pkgdown site of a package rather than its GitHub or CRAN site.

I am currently using browseURL(desc::desc_get_urls()[1]) for this which opens the pkgdown site if it exists in the URL field and comes first. If missing, the GitHub page is opened. If no URL field exists, it errors obviously.

Some pkgs do not have a URL field at all and while usethis::browse_github() already falls back to usethis::browse_cran(), I have the feeling that a wrapper function like browse_package() could be helpful.

Essentially it would try to look for a pkgdown page first, fall back to the GitHub page and last to the CRAN page.

@jayhesselberth
Copy link
Collaborator

Closed by r-lib/usethis#1102

@pat-s
Copy link
Contributor Author

pat-s commented Apr 22, 2020

Closed by r-lib/usethis#1102

This is a different FR. I'll open this one again in {usethis} then.

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

No branches or pull requests

2 participants