About Archive Tags RSS Feed

 

Entries posted in May 2007

If you despise that throwaway feeling

8 May 2007 21:50

After far far too long in the making I'm ready with a demo of my new site.

The demo is mostly complete, and 90% of the code is hooked up. There are some bits missing, and some gaps in functionality.

I'm working on this about 45-90 minutes a day at the moment, and that isn't likely to increase any time soon.

Probably not everybodies cup of tea, but after running Livejournal Valentine matching sites for a few years I've had the ambition of running an online dating site. And this is a nice small niche with only weak compitition…

Anyway I hope a few people sign up and play around whilst things are developed more.

| No comments

 

Will you lead me to your armchair

11 May 2007 21:50

Assume I'm using mutt for my mailclient and that I have all my mail stored beneath ~/Maildir.

Is there a simple way of limiting an index to only those folders containing New messages?

I know that I can use the index_format to display something like "N" next to folders containing new messages - but I cannot seem to limit the display to just those ones.

(At any given time I'll have something like 30+ mailboxes with unread messages, if not more.)

My current mutt looks something like this, which shows that I have 24 folders with unread messages - but it doesnt make it easy to tell which they are:

..
269       4096 May 11 22:49   ~/Maildir/.spam/
270       4096 May 11 23:36   ~/Maildir/.spam.bayes/
271       4096 May 11 22:49 N ~/Maildir/.spam.image/
272       4096 May 11 22:49   ~/Maildir/.spam.pyzor/
273       4096 May 11 22:49   ~/Maildir/.spam.razor/
274       4096 May 11 22:49   ~/Maildir/.spam.request/
275       4096 May 11 23:27   ~/Maildir/.spam.unsure/
276       4096 May 11 22:54   ~/Maildir/.steve_org_uk/
277       4096 May 11 22:49   ~/Maildir/.syswear_com/
..
-- Mutt: Mailboxes [24]

| No comments

 

Fed through the tube that sticks in me

12 May 2007 21:50

Thanks to everybody who told me that there wasn't a simple way to persuade Mutt to work with mailboxes containing unread messages.

I've now discovered the mutt-ng project, packaged in Debian's experimental branch. This contains the infamous mutt sidebar patch which caters to my needs fully:

  • I can toggle the display of the sidebar by pressing "b".
  • From there I can jump to the name of the next/previous mailbox with unread mail.
  • Once on a mailbox name I can open it easily.

Job done.

Expect a more involved writeup shortly ..

| No comments

 

A new and glorious moment

18 May 2007 21:50

Puppet the system-administration tool, similar to CFengine is very nice.

What is less-nice is the lack of decent examples. The wiki has lots of "recipes", however these give no real explaination of how to install them.

I know that I need manifests/site.pp which will control which nodes get which actions applied to them, but beyond that I'm a little lost!

I'm hoping to replicate my cfengine setup. Most of it is pretty simple "append line to file if missing", and copying files from the central server. (The latter I've got working nicely.)

Hopefully somebody will now point me at a good tutorial that doesn't stop once it is installed (like this one.)

| No comments

 

I have finally found my place in everything

20 May 2007 21:50

Sorry to everybody on Planet Debian who have been forced to see a lot of older posts of mine.

I switched from Typo to Mephisto - another Ruby on Rails blog.

The reason? Typo seems to suck memory like a .. big sucky thing.

Posting a new comment would take the system-load on my VM up to 2, which is not acceptible. I'm prepared to suffer a little with my decision to never install, host, or admin a PHP-based application, but not that much.

Mephisto seems nice, although the importing of old posts was a little fraught with peril. Thankfully the system, when used with Mongrel and an Apache proxy seems fast, stable and not too memory intensive.

The only thing that didn't happen properly was the closing of comments on all the older entries. Comments on new entries appeared to be correct in the sense that they should be automatically disabled after 7 days.

Here's how I fixed that:

skx@skx:~$ script/console production
1
2
3
Article.find(:all).each do |a|
 a.update_attribute :comment_age, -1
end

| No comments

 

Long journeys wear me out but

22 May 2007 21:50

I was suprised to see Michal Čihař suggesting that memcached wasn't helping his site enough.

I've been a huge fan of Danga's Memcached for the past year or two. I'm using it very heavily upon the Debian Administration website, and also upon my new dating site.

There are, of course, issues with making sure you flush the cache when things are updated, but I've got a good pair of test suites for that now :)

With a nice singleton accessor I can use the code as easily as:

1
2
3
4
5
6
7
8
9
10
11
sub recent_users
{
    my $cache   = Singleton::Memcache->instance();
    my $results = $cache->get( "recent_users" );
    return( $results ) if ( $results );

    # fetch from database
    
    $cache->set( "recent_users", $results );
    return( $results );
}

Obvious once you've done it a few times, but right now I can feel the difference if I disable the cache upon either of the sites. Page loadtime just drops.

I guess the effectiveness depends upon the site you're using, and how often things can be usefully cached. I know that for my uses I tend to have large items which would be expensive to fetch which occur on every page (such as "currently online users", or "recent weblogs".) That probably means I benefit more than others, still I've become so enamoured of the project I feel the need to pimp it a little!

| No comments

 

Another red letter day

28 May 2007 21:50

It has been a busy week. Mostly I've been working on new templates and functionality for the dating site but also I've setup a few new internal services for the home network:

  • A wiki for keeping track of shopping lists.
  • A simple calandar to keep track of upcoming films and events

On top of that I've been experimenting with IPv6, and getting the hang of doing interesting things with Ruby.

| No comments

 

Don't make me laugh .. bitterly

30 May 2007 21:50

Debconf is coming up soon in Edinburgh, so I figured I'd make a couple of posts for people who are coming.

Party because I've been busy, but mostly because I'm always busy on the Mondays when meetings happen I'm not involved in organization - I figure when we get closer to the time I'll volunteer to collect people, give directions, and staff the information/reception desk at Teviot for three-four days. (I've got two weeks off work; so I'll be around for 99% of the duration.)

Steve's Guide to Edinburgh: Expenses

Compared to many places, such as the USA, Edinburgh is expensive. Partly because it is expensive relative to the UK, but partly because of the exchange rate.

Common costs, which will vary a little locally, but are approximately correct for the kind of places you'll be near:

  • 20 cigarettes £5.50
    • Inside a pub ~£7.00 - but ignore them because a) They'll only have 16, and b) You can't smoke in pubs/clubs/indoors nowadays..
  • 1 pint of beer £3.00
  • 1 pint of milk £0.50
  • Bus fare £1.
    • Any single journey, regardless of duration or distance travelled will cost you a single adult ticket.
    • Make more than three journeys in a day and you could get a single-day ticket which costs £2.20
  • Taxi fare from Teviot to my house ~£5.00
    • Alfie, Jacob Applebaum, and other random people who want to watch films, drink beer, and catch up.

That's most of the common prices I think people could care about. If you have specific products / items you'd be curious about feel free to post a comment and I'll give you a figure.

| No comments