Improvements to Planet Perl and Perlanet
Tags: programming, docker, perlanet, planetperl
Published: 2023-03-03 10:24:30

---
title: Improvements to Planet Perl and Perlanet
published: true
date: 2023-03-03 10:16:30 UTC
tags: Programming,docker,perlanet,planetperl
canonical_url: https://perlhacks.com/2023/03/improvements-to-planet-perl-and-perlanet/
cover_image: https://dev-to-uploads.s3.amazonaws.com/uploads/articles/euw4rpgg4ws6jfcm4iyo.jpg
---

This is a story of one of those nice incidents where something starts off simple, then spirals out of control for a while but, in the end, everyone wins.

On Reddit, a few days ago, someone asked [‘Is there a “Planet Perl” with an RSS feed?’](https://www.reddit.com/r/perl/comments/119hu00/perl_rss_feeds/) and a few people replied, pointing out the existence of Planet Perl (which is the first Google result for [“Planet Perl”](https://www.google.com/search?q=planet+perl)). I’m obviously not marketing that site very well as every time I mention it, I get people (pleasantly) surprised that it exists.

On this occasion, it was [Elvin Aslanov](https://www.reddit.com/user/rwp0/) who seemed to discover my site for the first time. And, very soon afterwards, he started sending [pull requests](https://github.com/davorg/planetperl/pulls) to add feeds to the site. As a result, we now have three more feeds that are being pulled into the site.

- [Perl on Medium](https://medium.com/tag/perl). I’m slightly embarrassed that I hadn’t thought of this myself. I did, after all, once try to start [a Perl publication on Medium](https://medium.com/cultured-perl). I think I must have decided that there are better sites for technical blogging and blanked it from consideration. Medium’s not the busiest of places for Perl bloggers, but there are a few posts there and they’re mostly from people who are outside of the echo chamber – so getting more eyes on their posts is a good idea.
- [Perl questions on Stack Overflow](https://stackoverflow.com/feeds/tag/perl). Another one that would have been obvious if I had thought for a second. I’ve been answering questions on SO for years. It’s a good way to get more perspective on how Perl is being used across the industry. Unfortunately, the feed only includes the titles of the posts – you’ll need to click the link to actually see the question.
- [Perl commits on GitHub](https://github.com/Perl/perl5/commits/blead.atom). I’m interested in hearing how useful people think this is. I worry slightly that there will be times when the number of commits will overwhelm the other feeds. But maybe that’s a good idea. Perhaps it’s good for more people to see just how busy the Perl 5 Porters are. I’m a bit annoyed that the feed puts everything in a fixed-width font, but not (yet) annoyed enough to do anything about it.

You might know that Planet Perl is driven by [Perlanet](https://metacpan.org/pod/Perlanet). So adding new feeds is just a case of adding a few lines to [a configuration file](https://github.com/davorg/planetperl/blob/master/perlanetrc). And looking at the pull requests I got from Elvin, showed a potential problem in the way the configuration was laid out. Each feed has three lines of YAML configuration. There’s a title for the feed, a URL for a web page that displays the content of the feed and the URL for the feed itself. They’re called “title”, “web” and “url”. And it’s that last name that’s slightly problematic – it’s just not clear enough. Elvin got “web” and “url” muddled up in one of his PRs and, when I pointed that out to him, he suggested that renaming “url” to “feed” would make things much clearer.

I agreed, and the next day I hacked away for a while before releasing [version 3.0.0 of Perlanet](https://metacpan.org/release/DAVECROSS/Perlanet-v3.0.0/view/lib/Perlanet.pm). In this version, the “url” key is renamed to “feed”. It still accepts the old name (so older config files will still work) but you’ll get a warning if you try to use a config name in the old config.

I didn’t stop there. Last year, I wrote [a blog post about producing a docker image that already had Perlanet installed](https://dev.to/davorg/building-a-perlanet-container-43cm) – so that it was quicker to rebuild my various planets every few hours. Since then I’ve been rebuilding [that image](https://hub.docker.com/repository/docker/davorg/perl-perlanet/general) every time I updated Perlanet. But it’s been rather a manual process. And because I’m old and decrepit, I can never remember the steps I go through to rebuild it, tag it correctly and push it to the Docker Hub. This means it always takes far longer than it’s supposed to. So this time, I wrote [a script to do that for me](https://github.com/davorg/perl-perlanet-docker/blob/main/build). And because I now have the kind of mind set that sees GitHub Workflows everywhere I look, I wrote [a Workflow definition that builds and publishes the image](https://github.com/davorg/perl-perlanet-docker/blob/main/.github/workflows/publish_image.yml) any time the Dockerfile changes. I guess the next step will be to write an action that automatically updates the Dockerfile (thereby triggering the rebuild) each time I release a new version of Perlanet.

But that’s a problem for another day. For now, I’m happy with the improvements I’ve made to Planet Perl, Perlanet and the Perlanet Docker infrastructure.

The post [Improvements to Planet Perl and Perlanet](https://perlhacks.com/2023/03/improvements-to-planet-perl-and-perlanet/) appeared first on [Perl Hacks](https://perlhacks.com).