My blog
Here are the latest blog posts I’ve written. My plan is to write entries more frequent in the future, but often actual hacking comes in the way.
Why I don’t need an ORM
Once upon a time, I thought ORM’s was the meaning of life. I bought into the idea that it was much better to leave generating the SQL to a library that was smarter than me. And also, of course when you change between SQLite, Postgres and MySQL every week, then you would be crazy to maintain your own…
I’m getting rusty
I’ve been using Perl and Javascript for about 24 years, and haven’t really used any other programming languages - at least not for creating applications from the ground up. This makes 2024 a very exciting year for me, since I have now started using both …
Finally got Nextcloud running with Caddy and php-fpm
I’ve been running Nextcloud for many years, but it has annoyed me greatly that I had to use Apache to access it, when there’s a php-fpm alternative, and I’m using Caddy as my reverse proxy.My setup involves running both Caddy and Nextcloud as containers, with Podman,…
My take on gpg forwarding
I’ve been searching around the Internet for how to forward gpg sockets, but after solving and forgetting how to solve the the problem multiple times, I decided to write down my notes.Hopefully I will remember to look them up next time…Make sure the following lines ar present in …
Mojo::IOLoop likes running programs asynchronously
Want to be able to run programs and arbitrary Perl code asynchronously, while being able to read from STDOUT and STDERR, and also write to STDIN? Try out Mojo::Run3!When working with Mojo::IOLoop, you might find yourself in a situation where you want to run another program, but you also don…
Write and test Perl command line tools with ease
Writing command line tools often involves a lot of boilerplate and they can be hard to test. Getopt::App is a module that helps you structure your command line applications without getting in the way.I already have a competing module called Applify on CPAN. This module aims to…
Browser testing is hard. Let’s go shopping
Tonight at the monthly Oslo.pm meetup, I gave a talk about how to test your web application in a real browser. This blog entry is a collection of the steps I went through while running live demos showcasing my module Test::Mojo::Role::Selenium.My module uses…
Rewriting Mojolicious::Plugin::AssetPack
Update: I suggest checking out Mojolicious::Plugin::Webpack instead.AssetPack is a Mojolicious plugin which helps you process CSS and JavaScript assets. It can convert other formats, such as SASS, Less, CoffeScript (and many more) into a format the browser…
How I write web applications
This blog post is about the standard components I use when I develop and deploy my web applications.When I make a web page or web application I use Mojolicious. Mojolicious is this awesome realtime web framework, which makes web development a walk in the park…
Testing with a real database
Writing tests against a database is a struggle. Maybe the best way is to not test against a database at all, but providing a mocked interface instead. Even if this could be true in many cases, you still need to write integration tests for your models against a real database.
Convos revamped!
Convos is a chat application that runs in your browser. It allows you to be persistently connected to IRC servers, where you can leave the office and up the conversation on the bus without being disconnected.Convos was born in June 2012. It has been developed to scratch an itch…
Reasons for choosing Mojolicious
This blog post is a response to http://perlmonks.org/?node_id=1133505. I tried to reply directly, but I got “access denied” for some reason, so I decided to write a blog post about it instead.The post on perlmonks was:Good day fellow monks,I am starting a new project, with a clean slate, this is a wonderful…
@swaggerapi and #Mojolicious – How to validate your input/output with a schema
This blog post is outdated. You might want to check out A RESTful API with OpenAPI instead.Mojolicious is an awesome web framework which allow you concentrate on the business logic, while the rest Just Works ™.Swagger is “The World’s Most Popular Framework for…
The Lenovo Thinkpad x240 is awful, but…
The thinkpad has an awful touchpad. Or even worse: it’s a clickpad! A clickpad is a touchpad without physical buttons. This means that it seems like you only have one big super-sensitive button in Linux. You do actually have two buttons, but they are at the bottom of the clickpad,…
How to deploy #Mojolicious apps on @DigitalOcean
Mojolicious is truly a modern web framework. It keeps up to date with the HTTP, HTML, WebSockets and JSON specifications so you don’t have to worry about doing that right. It’s a framework where you implement the core business logic, while everything else Just Works ™.
Howto set up Convos on @digitalocean
From convos.by:Convos is the simplest way to use IRC. It is always online, and accessible to your web browser, both on desktop and mobile. Run it on your home server, or cloud service easily. It can be deployed to Heroku or Docker-based cloud services, or you can just run it as a…
Mojopaste – A #pastebin based on #Mojolicious
Today I released my 13th Mojolicious based project to CPAN, but the 1st open source Mojolicious based application.It feels good.The application is a pastebin. That is a web application which you can paste text to, hit the “Paste” button and it will save it and generate a unique URL which you…
Continuous deployment with #Mojolicious and @github
After hearing Curtis Poe giving the talk “Agile Companies Go P.O.P.‎” at the YAPC I thought I should finally get the word out about my extension to Mojolicious, which allow continuous deployment using a github post-receive hook.So… Mojolicious has this marvelous web server called…
Howto deploy #Mojolicious to @dotcloud
After sending some tweetswith dotcloud I’ve figured out how to deploy Mojolicious todotcloud as a perl-worker.The way I previously deployed was using the standardperl service, with a uWSGIfrontend. The really cool thing about a perl-worker is that the mojo…
Applify: Scripting without boilerplate
Applify is a module which helps you write scripts with less boilerplate code. The scripts written with Applify can also be tested easily.I started out using plain , but I thought it was clumsy to combine with my OO code. Then I started using and and life was starting to get good …
A #Mojolicious lite app that use @Cloudinary
So earlier this week I’ve written about How to deliver your images through Cloudinary with Perl and Cloudinary examples for applying effects to your images. Today I’m posting a Mojolicious lite app which can upload images to your Cloudinary account, show them on a web page and allow the visitor to delete them.
Cloudinary examples for applying effects to your images
So yesterday I blogged about the basic functionality about Cloudinary, but there are so much more than scaling images that you can do.examples from Cloudinary’s own blog.Mojolicious::Plugin::Cloudinary, but you can also use the Cloudinary module directly if…
How to deliver your images through Cloudinary with Perl
Cloudinary is a cloud-based service for image management & manipulation. From their about page:Use Cloudinary to: * Manage all your assets and web resources in the cloud. * Allow any web application, large or small, to enjoy modern web delivery platforms. …
My x200 used to say “beep”
I’ve been using my Thinkpad x200 for about a year now, and I’m pretty sure it started beeping some time this winter: A short “beep” occurred each time it came back from suspend or the power cord was plugged in. It has been pretty annoying, but it has not been…
Xperia X10 mini
So I’ve been using my X10 mini for ten days now, and it has been quite a bumpy ride:Last weekend I had to charge it about every six/eight hour. I have to admit that I did use it a lot in the beginning, but i was still shocked to see how bad the batteryAfter I got back from my weekend I decided to change back to my …
Online DOCSIS config file editor
I’ve written an online DOCSIS config file editor which (of course) can be used to generate config files for equipment that follow the DOCSIS specification.The frontend is written using Catalyst, and the “backend” use DOCSIS::ConfigFile, meaning the whole thing is powered by …
CatalystX::Controller::Sugar
I’ve written a module I think is rather useful: CatalystX::Controller::Sugar. This module (will hopefully) make chained actions be your default when writing a controller in Catalyst. I remember when I first started looking at Catalyst – I didn’t see the reason for…
rt.cpan.org – great fun!
I must say I enjoy getting rt-tickets. “Why?”, you might ask. Well, It’s probably the only way I can actually know that someone use, or has tried to use a module I’ve written. The bad (if you can call it bad) thing about getting a ticket is that it…
Line noise: parentheses
I’ve been discussing how bad perl code looks and I’m a bit surprised: I consider () more noisy than $, %, @ and friends, while the people I discuss this with, really likes parentheses. Consider this:Versus:I don’t understand how the first one is less noisy than the second (!).
Wow, Moose is cool!
I was introducing Moose (and perl oo) to a java guy the other day, and he replied: “No, shit. Is that possible?”, “Now I understand the fuzz about multiple inheritance” and “Wow, Moose is cool!”.I must confess: It brings comfort to my heart to hear a…
Which name to pick?
I’m writing a new module, which is currently named “Net::DHCPd”. It’s not a good name imo, since Net::DHCPd sounds more like a module that actually is a dhcp server, which mine is not.This is what it can, or is supposed to support in the future:So what should it be called? I…
Multimedia updates (partially old news)
I’ve been enjoying xbox mediacenter on my xbox 1.x for several years now and I’ve finally gotten the opportunity to install it on my htpc as well. This is because the xbmc-team has ported it to Windows, Mac and Linux.To my big surprise I was able to install the …
More perl modules
I’m working on some more perl-modules now: YAML::Object and POE::Component::TFTPd. I’ve also fixed some issues with SNMP::Effective, and written a new implementation, that uses Net::SNMP instead of SNMP.The YAML-module is a result of bad typing: I’m quite sick of doing…
Fixed overscan
I’ve been googling for quite som time now, and finally I found settings that works for my 720p DFP.I don’t think the specs are important, but I’ll list them anyway:ModeLine “720p” : This is the modeline that works for me. I’ve commented out the other…
2007 09 01 quelea cable modems and cmts
This project is shut down.The idea was a system which could monitor and provision a variety of network equipment.The primary target was cable modems and CMTS, but to do that the project had to containmore functionalityThe cable modem and customer computer equipment need IP addresses. I decided to use…
YAPC::Europe::2007 Vienna
YAPC::Europe::2007 was a blast! I can’t really put my finger on what was the best, because it was all good. I really recommend every Perl-programmer out there to come to next years YAPC in Denmark/Copenhagen.I had a talk this year as well (Operator overloading, one of the magicks of Perl), but I wasn…
YAPC::Europe::2006 Birmingham
4th of September, 2006{.blog_info_published}Hello peeps. It’s been a while now, but I finally got some spare time to communicate with the world again…I’ve been to the YAPC::Europe this week, and I must say it was quite fun — or at least the time I actually…
Xgl
I’ve managed to get Xgl to work! (Special thanks to DavidK-64 for A: telling me about Xgl It’s really amazing, you just got to see for yourself to get the real impression. The compiz manager features Wobbling windows, transparancy, a new “switcher”…
SNMP::Effective
I’m done writing the code for SNMP::Effective now. It has show to be quite promising after some tests: 4000 hosts in 50 seconds is quite better than what I had with a previous module. I’m hoping to release SNMP::Effective on CPAN, later this year. But first I…