Adding Your Blog to JuliaBloggers

Hi everyone!

If you have a personal blog where you write on Julia, consider adding it to JuliaBloggers! This post will serve to contain info for various website hosting solutions and how you can add your own blog’s RSS to JuliaBloggers. If you don’t see a platform listed and want to have it included, ping me and I can add it to the main post.

Franklin Websites

You need to first define these variables in your Franklin website to enable RSS: https://franklinjl.org/syntax/page-variables/index.html#rss

Then, to get all the posts on your site that are tagged for Julia, you can simply have your website URL like this to get every post tagged as a Julia related post like this: https://fredrikekre.se/tag/julia/feed.xml

(Thanks to @fredrikekre for this solution)

Jekyll Websites

Include this in an xml file that is at the root of your website’s directory. You could name it, rss_julia.xml:

---
layout: null
---
<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>ADD THE TITLE OF YOUR BLOG HERE!!!</title>
    <description>ADD THE DESCRIPTION OF YOUR BLOG HERE!!!</description>
    <link>{{ site.url }}</link>
    {% for post in site.posts %}
		{% unless post.draft %}
			{% for tag in post.tags %}	
				{% if tag == 'julia' %}
				  <item>
					  <title>{{ post.title | xml_escape }}</title>
					  <description>{{ post.content | xml_escape }}</description>
					  <pubDate>{{ post.date | date_to_xmlschema }}</pubDate>
					  <link>{{ post.url | prepend: site.url }}</link>
					  <guid isPermaLink="true">{{ post.url | prepend: site.url }}</guid>
				  </item>
				{% endif %}
			{% endfor %}
		 {% endunless %}
    {% endfor %}
  </channel>
</rss>

Make sure each of your posts that contain Julia related content have been tagged as Julia in a post like this:

---
title: "NeuriViz (Part 1) - Performant Graphics for Neuroinformatics"
image:
  path: /assets/brain_tiles.png
comments: true
share: true
tags:
    - julia
---

Here is my blog.
I am writing on how awesome it is!

Then, once you rebuild your site, copy the url to that file and submit it to JuliaBloggers. Here is how I did it for mine: http://jacobzelko.com/rss_julia.xml

(Thanks to @oxinabox for this solution)

6 Likes

I have not blogged for a while, but the RSS generator below worked with Hugo (maybe it needs dusting off).

2 Likes

Is there any configuration for Franklin?

Yes, for Franklin you need to define these variables: https://franklinjl.org/syntax/page-variables/index.html#rss for RSS in general.
Franklin supports tag-filtered feeds (https://github.com/tlienart/Franklin.jl/pull/684), so for tag X you get a filtered feed that includes only posts with the X tag at /tag/X/feed.xml.

For example, here is my global feed: https://fredrikekre.se/feed.xml and here is my julia-tag feed: https://fredrikekre.se/tag/julia/feed.xml.

4 Likes

Hey @Tamas_Papp - thanks for this! Do you happen to know how to filter it for Julia tagged posts?

More blessed content. Great work!

Hugo will create tag-based rss feeds for you with the above setup, eg

1 Like

Is there a recipe of setting up a blog via github that would work with Julia Bloggers? Does Julia Bloggers have history and/or keyword search facility?

Hey @cce - I would strongly suggest checking this out: Working with Franklin

Franklin.jl is made quite specifically for the use case you just described. If you have any questions, hop onto the Julia Slack (link if you aren’t there already: The Julia Language Slack) and ask in the Franklin channel. @tlienart is awesome and I am sure would be happy to help you out as well as anyone else in the Franklin channel. :slight_smile:

3 Likes

For what it is worth, I thought I’d mention that you can style your xml page using css as well. You can see an example of that here:

https://blog.kdheepak.com/tags/julia/rss.xml