Ferry Boender
Programmer, DevOpper, Open Source enthusiast.
In kind of a follow up to my previous post on using find and sed to search and replace multiple files, I found out something else. I needed to find and replace something in every file, except for any files which had “.svn” in them. After struggling for a few fruitless minutes with -regex, I […]
I’ve released Templum v0.4.0 Templum is an extremely lightweight, simple yet powerful and fast templating engine for PHP. It re-uses the power of PHP itself for rendering templates, but provides additional features making it easier to write templating code. Rendering templates using Templum is very fast; it approximates native PHP rendering speed for include() statements. […]
I always kept a small Python script around for searching and replacing in Linux. Turns out that GNU sed has an inline edit mode which I didn’t know about: -i[SUFFIX], –in-place[=SUFFIX] edit files in place (makes backup if extension supplied) This makes searching and replacing in files as simple as: find . -name “*.txt” -print0 […]
Python dynamic nature continues to astound me. I was working on a small library when I noted it did a lot of redundant IO calls. Now I’m not one for premature optimization, but a while ago I was thinking about writing a decorator or something that would wrap around functions and methods, and cache the […]
I wrote a little IRC server in Python: HIrcd is a minimal, hacky implementation of an IRC server daemon written in Python in about 400 lines of code, including comments, etc. It is mostly useful as a testing tool or perhaps for building something like a private proxy on. Do NOT use it in any […]
I do a lot of stuff in text file on my system. I keep notes and todo’s in them, I write drafts using a text editor and even complete user guides and other documentation. I also keep my personal planning in Gnome Planner which stores its data in an XML file, which in essence is […]
There’s a whole slew of information regarding all kinds of encoding issues out there on the big bad Internet. Some deal with how unicode works, some with what UTF-8 is and how it relates to other encodings and some with how to transform from one encoding to another. All that theory is nice, but I’ve […]
SQL’s aggregate functions (COUNT, MIN, MAX, etc) in combination with GROUP BY is great for generating statistics from a database. It’s quite easy to retrieve a count of the rows in a database grouped by week number or month. When there are no data points in the table for a particular week or month, however, […]
I just released v0.2.0 of Templum, a simple templating engine for PHP. About From the homepage: Templum is an extremely lightweight, simple yet powerful and fast templating engine for PHP. It re-uses the power of PHP itself for rendering templates, but provides additional features making it easier to write templating code. Rendering templates using Templum […]
In the last couple of years, I’ve done a lot of performance optimization. I’ve optimized raw C, Python and PHP code. I’ve optimized databases: tweaked settings, memory usage, caches, SQL code, the query analyzer, hardware and indexes. I’ve optimized templates for disk I/O, compilation and rendering. I’ve optimize various caches and all kinds of other […]
Search this blog:
The text of all posts on this blog, unless specificly mentioned otherwise, are licensed under this license.