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] GitHub action for testing urls #241

Open
cansavvy opened this issue Sep 28, 2020 · 5 comments
Open

[Idea] GitHub action for testing urls #241

cansavvy opened this issue Sep 28, 2020 · 5 comments

Comments

@cansavvy
Copy link
Contributor

There's a lot of links everywhere in the material for this repo. I would hate for broken links to slip through to be found by users.

https://github.com/marketplace/actions/url-checker

This says it's for testing markdown links, but I think? It might work for Rmds too?

Obviously, this wouldn't catch incorrect links: one's that work but aren't going to the right place according to the context, but if its simple enough to implement I think it would be a nice add.

@cansavvy cansavvy changed the title [Idea] GitHub action for testing links [Idea] GitHub action for testing urls Sep 28, 2020
@cansavvy
Copy link
Contributor Author

cansavvy commented Oct 5, 2020

@jashapiro , is this something we could/should add to docker-build-push.yml before we push the htmls? I can take a whack at this if so.

@jashapiro
Copy link
Member

I think adding it to the build stage is too late. I would prefer it run at the same time as spell checking. I am not sure how that particular action handles local links (i.e. if a user links to an html file that is not yet on alexslemonade.github.io/refinebio-examples).

That actually brings up another issue which is that we should consider updating all links to https://alexslemonade.github.io/refinebio-examples/* to relative links. If the base url is moved to refine.bio, this will allow links to work without modification.

@cansavvy
Copy link
Contributor Author

cansavvy commented Oct 5, 2020

local links (i.e. if a user links to an html file that is not yet on alexslemonade.github.io/refinebio-examples).

I am unsure. My guess is it probably doesn't do well.

Would relative links work if users are looking at the Rmd locally? (Also would users want to access links while on the Rmd locally, my thought is maybe?)

@jashapiro
Copy link
Member

Relative links should work locally. They are a very common way to write markdown links.

@jashapiro
Copy link
Member

Would relative links work if users are looking at the Rmd locally? (Also would users want to access links while on the Rmd locally, my thought is maybe?)

This was something I hadn't considered: I was thinking about local development, not end users downloading a single .Rmd file and only having access to that file. In that case, yes, we should keep the full links, but we may want to update when implementing any changes to the base url, as discussed in AlexsLemonade/refinebio#2542

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants