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

Link to CUDA.jl 5.0 blog post. #38

Merged
merged 2 commits into from
Sep 26, 2023
Merged

Link to CUDA.jl 5.0 blog post. #38

merged 2 commits into from
Sep 26, 2023

Conversation

maleadt
Copy link
Member

@maleadt maleadt commented Sep 20, 2023

No description provided.

@github-actions
Copy link

Once the build has completed, you can preview your PR at this URL: https://juliagpu.org/previews/PR38/ in a couple of minutes.

@maleadt
Copy link
Member Author

maleadt commented Sep 20, 2023

Looks like the RSS feed doesn't include links to external entries. Will need to fix that.

@maleadt
Copy link
Member Author

maleadt commented Sep 21, 2023

@tlienart is there a way for the external entries (i.e. posts that just link to another URL, as added in this PR) to show up in the RSS feed? IIRC, that's why with Hugo I used to have actual posts for external entries, but with a special tag redirect = "http://..." that generated a meta http-equiv="Refresh" header, instead of adding a special external_entries to the index like you did when porting our Hugo website to Franklin.jl (also because RSS entries need additional information, like the author, etc).

@maleadt
Copy link
Member Author

maleadt commented Sep 25, 2023

@tlienart Friendly ping; happy to take a look myself if you could give me some pointers 🙂

@tlienart
Copy link
Contributor

tlienart commented Sep 25, 2023

so there's this Franklin.RSS_ITEMS list which you could push to in a hfun, elements of it are Franklin.RSSItem with fields

item::String
date::Date
tags::Vector{String} # <-- in your case empty

so you could have a hfun called from post/index.md which pushes these external entries to it. This will get picked up and sorted by rss_generator() afterwards. the add_rss_item which generates these elements for posts with rss stuff in it should be useful too: https://github.com/tlienart/Franklin.jl/blob/5b82e05d1aaf7f54957aeeaa04a2683326205daf/src/manager/rss_generator.jl#L133-L151

I'd suggest using this and then if you think it'd be nice to have an actual clean pattern for this in Franklin, open an issue there? I'm just a bit slow at opening new features there as I'd first like to make a new release (I've been wanting to do that for a very long time and am struggling to push it over the line due to time constraints..)

@maleadt
Copy link
Member Author

maleadt commented Sep 26, 2023

Thanks for the suggestion. I'd really to avoid further special-casing in index.md though. Isn't it possible to re-use the existing functionality for emitting RSS entries, i.e., by creating an actual post, and redirecting to the external entry? If it's too hard to do that 'properly' (by emitting a meta http-equiv="Refresh" header tag), some inline Javascript should be able to redirect as well. Is it possible to use inline HTML/Javascript in a post to do so?

EDIT: I'll try with a custom hfun. But emitting a meta header would be better.

@maleadt maleadt merged commit 0fe2b7b into master Sep 26, 2023
1 check passed
@maleadt maleadt deleted the tb/cuda_5.0 branch September 26, 2023 08:39
@tlienart
Copy link
Contributor

Yeah I understand, was just trying to give you a quick way out given I can't currently commit time to a nicer solution.

A note that {{redirect ...}} is already defined (your definition will take over so that's fine if it works for you), see https://franklinjl.org/syntax/page-variables/index.html#basic_functions

glad that you figured out an acceptable path for now

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

Successfully merging this pull request may close these issues.

2 participants