Skip navigation

Category Archives: /dev/blog/

SpamAssassin Logo

Among other things, I run my own mail server for a few domains. On those domains, I use a method of combatting SPAM called greylisting. Basically, when another server wants to deliver mail, my server says “I’m too busy – try again later.” A valid mail server will still be around later to retry. A typical spammer’s ad-hoc server (that’s usually on a hijacked machine) won’t bother to try later even if it’s still around to do so.

In order to receive some time-sensitive mail recently, I turned greylisting off on a particular domain for the last 24 hours or so. The result was dramatic. Read More »

inBuckets()One of the biggest nightmares I’ve had to deal with is unpredictable cache keys. Inevitably, someone codes a function that uses its parameters in the key name. In many cases, this is fine. However, when you need to deal with paginated or grouped data in different sizes, things can get messy. To that end, I lean on PHP’s range() function.

Setting up the input for range() and making the output usable is something I’ve ended up doing over and over again, so I’m finally taking an implementation sharing it to save everyone the labor of dealing with it (including myself). And thus, I submit inBuckets() for your perusal (hosted at GitHub – sadly wordpress.com won’t let us embed Gists). The syntax is in the doc block and there’s commented out sample code at the end to get you started. Enjoy.

Here’s an Apache one-liner I often find myself using. It will list all of the server names and alises that are contained in the active Apache config files on a machine. I’ll go into the parts of the command and how to modify it to suit your needs. This assumes a bash-like shell (with grep, sed, sort, tr and a for loop), root (or permission to run the httpd binary directly) and if you wish to modify the examples, a little command-fu.

Read More »

ProFont in action (hmmm... what language is that?) Tonight I started using ProFont and fell in love.
I’d been a fan of Proggy Clean for a few years, but needed characters it didn’t support well (such as ‡ and »).
Read More »

Adobe Edge Screenshot PortionInteresting. Adobe is making made a GUI for Webkit, (maybe) jQuery and HTML5. In one sense, it’s déjà vu (It’s "Flash-weaver"!) and in another it may be the future (a jQuery IDE?!). They don’t mention jQuery directly, but the method call in this screenshot sure looks familiar as did some of the easing animations. It would suck to end up with yet another $ conflict if they are not using jQuery.

Check it out Adobe’s video preview at tv.adobe.com.

A screenshot of GridMaker's menu location, dialog box and a 64x64 grid with a 3px gutterI am constantly laying out guides in Photoshop. It’s a major time suck when I’m making something like an icon map. I’ve tried everything I could think of to automate the process. I’ve made elaborate actions. I’ve tried using the View->New Guide… dialog over and over. I finally decided to try my hand at scripting the process. Well, Andrew Ingram beat me to it and did a fine job at that with GridMaker. It’ll create a new file placing the guides at any height and width interval you want with a gutter and stop at any total hight and width you specify. Perfect.

I stumbled across this page which has some classic engineer humor from "back in the day". Here’s an example:

Man and Woman in the engineer's point of view

A surgeon, a civil engineer, and a software engineer were arguing about whose was the oldest profession.

The surgeon remarked, "Well, in the Bible it says that God created Eve from a rib taken from Adam. This clearly required surgery so I can rightly claim that mine is the oldest of our professions."

The civil engineer interrupted and said &quotBut even earlier in the book of Genesis, it states that God created the order out of the heavens and the earth from out of the chaos. This was the first and certainly the most spectacular application of civil engineering. Therefore, you are wrong. Mine is the oldest profession."

The software engineer leaned back in his chair, smiled, and said confidently, "Ah, but who do you think created the chaos?"

You may have noticed the links at the bottom of every page here disguised as `scp` commands. I’ll explain what each is and what they will direct you to. Read More »

Subversion LogoLots of people use Subversion and WebDAV (i.e. “https://url.to.repo/trunk/”) to get to a Subversion server. It’s usually done so the checkout is portable to Windows machines running Tortoise. I used to be one of these people myself. Sadly, WebDAV is slow compared to checkouts using svn+ssh – especially if you’re over a VPN or overseas. Read More »

Facebook LikeI notice a lot of people falling for bad links out there on Facebook. I know it’s confusing and they all look alike. That’s why I’m going to share the geek tricks for not getting fooled. This is part one where we’ll look at the practical reasoning and red flags you should be aware of. In part two, we will explore the technical details of what’s going on. Read More »