Skip to content

Switching buffers and Google+

When you do so much of your work in one text editor the efficiency of switching between buffers becomes more important. For a long time I’ve had two bindings “C-x b” and “C-x C-b” which in days of yore I had bound to bs-show and a hacked up list-buffers that opened another window. These are broadly the “quick switch between working buffers” and “show me all the buffers”.

For some time I’ve relegated bs-show to the longer binding and now use Stephen Bach’s excellent Lusty Explorer which works really well when you know the name of the buffer and it’s fairly unique. However when you’ve been going a while it can get un-manageable with a large number of open buffers, especially if you’ve opened second copy of a file from another source tree. This is what I would use the old classic bs-show for.

A few days ago I discovered ibuffer-mode with it’s ibuffer-bs-show buffer navigator. Looking back through the Planet Emacsen history I can see it has been mentioned before and given it’s been in Emacs since version 22 I’m surprised I hadn’t cottoned on to it earlier.

One thing that might have put me off is the initial buffer list can be quite sparse. By default you only see buffers with files associated which misses out IRC, Edit with Emacs and *scratch* buffers. However hit “h” and you’ll see there are a plethora of quick keys for chaning the view. A quick “//” and all filters are removed and you can quickly filter by different criteria. To get the most out of the mode you’ll probably want to set up some custom filters (“/r<completing filter name”>) to make quickly switching to groups of buffers easy. I currently have “work”, “remote”, “irc” and “logs” as filters. You can filter by name as well as major-mode.

ibuffer-mode does have the concept of Filter Groups although I’m not sure what they add on top of having normal filters which as far as I can tell can be arbitrarily complex. It also has some quite handy sorting and selection modes e.g. “sv” – sort by last viewing time. Given the amount of space the wiki devotes to the topic I wish I’d re-examined my buffer switching habits sooner. The change is already paying dividends for my productivity.

Before I go I thought I’d put in a quick mention of Google+. There is growing community of fellow Emacs users starting to post on it. One thing that attracts me to Google+ over Facebook (too data-miney) and Twitter (too short) is the concept of “Circles”. It makes sharing geeky Emacs posts with people that might actually care easy while sparing them the flood of baby pictures I share with friends and family. If you’d like to follow me or my alter-ego please do mention Emacs in your profile or in a message so I can assign you to the correct circles.

Getting organised

What with becoming a parent and getting promoted I suddenly find myself needing to become a lot more organised. Although I’ve been using org-mode for a bit I need to get a lot more organised with it.

Previously I had two sets of org notes. My personal set where sitting on my server which I could access via the terminal. I generally accessed this at home on the odd occasion when I was doing things like the annual round of insurance quote gathering. The second set was a fairly simple time sheet type affair that I was using at work to keep a vague track of where all my time was spent. The big missing part of this is when I’m on the move.

I’ve just recently upgraded my phone to the latest Galaxy Nexus which is a fine Google enabled device. I make no apologies for using Google’s calendering and shared document services. They work very well and importantly allow me to share things with my wife who doesn’t quite share my desire to run everything from a text editor. However for my personal task lists on the move and remembering what’s coming up at work it doesn’t quite cut it. Besides I like org-mode and I’d heard about MobileOrg so I endeavoured to set it up.

MobileOrg has been around some time for the iPhone but the mechanisms it uses for integrating with org-mode are fairly well documented. As a result there is a couple of Android implementations for it. Matthew Jone’s mobileorg-android was the first version I tried.

The original sync method for MobileOrg was to use a service like Dropbox to sync files. Given the history of Dropbox’s security I wasn’t about to move my files into the proprietary cloud. The alternative is to enable WebDAV on my web-server and therefor enable two way communication via HTTP. It was a little concerning to see self-signed SSL wasn’t supported as this does open up a potential attack vector on my machine. I’ve mitigated it a little by using digest authentication instead of basic-auth but I’d still prefer to be conducting these read-write operations over something more secure.

Initial results were a little underwhelming. After some messing around with the format of org-links I eventually got a basic outline summary up. Unfortunately I can’t seem to sync notes created on my phone to the server. This seems to be a Apache problem which I shall have to dig into later.

After perusing the market some more I noticed there is a new project in town. Konstantin’s MobileOrgNG was forked some time ago from Matthew’s code and on installing I found it looked an awful lot better. I’ve still be unable to post any locally added notes (due to previously mentioned Apache config issues). However it’s presentation is a lot slicker and it shows a lot of potential for being a good MobileOrg client.

I’m now stuck with a classic open source fork dilemma. The code bases look to have diverged enough that these two projects are essential going their own way. Looking at the two impact graphs it looks like they diverged around August 2011 and since then MobileOrgNG looks pretty much like a solo effort albeit with an impressive commit rate of new features.

So the questions for my readers. Which code base should I jump on? Has anyone got experience with the two different code bases and the reason they split? Are there any other Android clients for org-mode I should be looking at?

Nexus of possibilities

Looking back the last few months I notice every post has been about family and parenthood. Time to redress the balance a little and add some geek friendly contents.

After Christmas I indulged myself with a new phone. When I got the HTC Hero I’d deliberately skipped the first generation of Android phones to give a chance for the hardware to mature. I also made the rash promise it would be my last phone for some time. As it happens I think 2.5 years is a fairly good innings for a piece of technology where the innovation cycle is measured in months. I still have the Hero but now it’s not my main phone I can afford to be a bit more experimental with the software I put on it.

There were a couple of changes to my approach to choosing a new phone this cycle. The first was I brought it outright off-contract. Although I suspect I could get it slightly cheaper overall through a phone contract there are some non-financial downsides to the contract approach. The first is the operator takes the view that the phone belongs to them so they can install (and prevent you removing) what they like. The recent Carrier IQ controversy should certainly act as a salient reminder that the mobile phone companies do not have your interests closest to their hearts. The second is lack of flexibility. Although thanks to Ofcom we have number portability most people are only able to take advantage of it at contract break points. The operators know this and off course do their very best to keep you tied in to their deals. Now I’m off contract I’m currently paying £10/month for unlimited data and all the calls/texts I use. They have to work doubly hard to keep me as a customer as I can jump ship at any point. That flexibility is more than worth the up-front cost of paying for the phone in full.

As far as choice there was only really one in the frame. Much as I like Android and it’s open-source nature it does suffer from a problem due to that openness. Although it’s heartening to see manufacturers are starting to relent and cease the practice of locking boot-loaders to prevent 3rd party firmware there are still problems in their support. They tend to stop updating the firmware shortly after they stop manufacturing the phone. Some manufacturers also have a hard time meeting their GPL obligations which makes open source support for the hardware a lot harder. As a result I decided to wait for the next in the Google Nexus series which ships with the latest release of Android, Ice Cream Sandwich.

Initial impressions of the new phone are good. The phone is a little bigger than the Hero but pretty much 100% screen with more than a few hints of Star Trek data pad ;-) . The Super AMOLED display looks very clear and crisp with both photos and video. The phone is very nippy thanks to the accelerated 3D hardware and duel core processor. The camera is certainly an improvement on the Hero and with the LED flash is close to achieving the quality I was used to on my old Sony K750. The A-GPS also acquires location a lot faster than the Hero. In fact a lot of things I thought were app problems have cleared up when presented with faster hardware. All in all I’m very happy with the Galaxy Nexus and think it easily stacks up against any iPhone you might want to compare it with.

5 years ago

I was reminded of a new years party 5 years ago when I rather drunkenly blurted out to Fliss my desire not to be separated from her by geography next time we welcomed in a new year. We hadn’t been together that long and she was visiting Oz for her brothers wedding. Happily I’ve celebrated every new year with her in person since.

This year was not exactly rock and roll as we now have Ursula with us. We ordered a large takeout and set about watching a few films (Source Code, pretty good actually) before heading up to bed before Big Ben struck. We watched the local fireworks from our bedroom window and pretty quickly went to sleep (a luxury these days to be taken when possible). When I think about the last 5 years I realise what a lucky and fortunate man I am to have such a wonderful wife and now a beautiful baby daughter.

Simple State Machines and Other Things I Have Learnt

We’ve just returned from 3 days at Fliss’ Mum’s house. Although we are still fairly sleep deprived things were made a lot easier by the presence of aunts and grandmothers who offered to take turns tending to the baby. This included one of those rarest of things, time for the two of us spend together without any other distractions. My life has now been reduced to a fairly simple state machine. There are predominantly 3 activities, for now ignoring the fourth: “At Work” which won’t kick in until the 10th.

1. Checking baby is happy

This involves running though a fairly simple set of checks. Is the baby too hot or cold? Is the baby clean? Is the baby hungry?

I have to confess I have quickly developed the parental habit of sniffing around the crotch area of the baby. It is so far the fastest and most effective way of telling if a change is required.

Ursula is starting show interest in things so occasionally the correct action is just to walk around a bit so she can look at new stuff. I have no idea how her brain is assimilating all the knowledge of corners and ceilings (being areas of contrast she can make out) but it could possibly point to a future career as a engineer ;-)

2. Checking Mummy is happy

Invariably the baby’s internal state eventually resolves to “Hungry” which requires it to be passed to Mum for feeding. Although we have been expressing and trying bottle feeds at the moment she gulps way to fast and invariably throws most of it up after the feed. So far we have found feeding “at source” is generally the most effective. However it does tend to immobilise Mum while she feeds so it falls to me to fetch and carry to ensure as many useful things are within reach when required.

3. Do everything else

The general order being cleaning, preparing food, household chores and finally if I’m lucky something else. Last night I did get a few hours to play through some of the latest CoD which Santa delivered over Christmas. I do harbour some hope of doing some recreational coding over the next few days although my start-up latency is so high that the state machine is often reset before I get into anything worthwhile.

The last few weeks have thrown up a few more interesting discoveries though. One of the more recent ones is that white noise is very restful for babies. We’ve managed to extend naps in the stroller/bassinet from around 5 minutes to up to 45 minutes by running a white noise app on the phone. My favourite Android app so far is Chromadoze which lovely little ope source app with a rather funky main display for setting the frequency balance of the noise. If I get a chance I may have a play at adding some features more aimed at soothing babies.

What big eyes you have

We’ve had Ursula at home for over a week now and are slowly getting into the swing of this parenting malarkey. So far we’ve nicknamed her “Trufflehog” after the manner she searches for the breasts when she’s hungry which seems to basically be when she’s awake. We are getting a growing amount of the “Quiet Attentive” awake state though. Her fascination is mainly with areas of contrast which to us mainly seems to be corners of the room. I’m not sure how much is down to baby face morphology but one comment that keeps coming up is how big her eyes are. Although I’m bound to be an overly proud Dad I’m fairly sure she’s already starting to track objects and points in space. You can play an interesting game carrying her around being guided by the position of her head. A head she seems to be able to keep upright most of the time by herself although she still hasn’t mastered the art of pushing up when on the play-mat.

As she is currently not self-propelling the day to day handling is fairly simple. However preparation is the key to success here:

I’m sure all too soon she will become self-propelling and then our lives will become a lot less sedentary. In the meantime we are feeling quite pleased having made it out of the house several times. We’ve managed a brief trip into town, a tea-morning and a couple of trips to the pub. Ursula certainly seems to be happy to drop off when ever she is put in the car seat and driven anywhere. This tendency also translates to the car seat being “fitted” to the shopping trolley.

One area we have struggled with is the pram cot which she doesn’t like at all – tending to kick and scream while at the same time divesting herself of the layers of warm blankets to shield her from the environment. While wheelies seem to briefly calm her down it’s not a long term practical solution. I wonder if she is developing Minbari sleeping habits?

As it has been almost impossible to get her to sleep in the mosses basket we’ve already taken our first major parenting decision to keep her in the bed with us. It has improved on the amount of sleep we actually get and it makes feeding her fairly non-distracting. We do worry about the advice against co-sleeping but feel the size of the bed makes it a little more practical and we’ve developed fairly light sleeping habits quite quickly. The feedback from others has been interesting though, ranging from warnings about making a rod for our own backs later to encouragements to go with what works for us. At some point we’ll have to encourage her to sleep on her own but it’s a bridge we’ll cross later on when she’s sleeping longer hours.

I’ve been back to work a few days and have the next two to look forward to until I break for Christmas. I’m already looking forward to what month 2 brings. I’m hoping just a little more sleep and a lot more activity from Ursula.

New Family Unit, Some Assembly Required.

I brought Fliss and Ursula home on Monday morning so we now have a complete family unit at home. We didn’t do much on Monday apart from appreciate being back in the house with all the attendant creature comforts. Tuesday didn’t involve much either but we had both sides of the family visit in the afternoon for a little celebratory drink. So far Wednesday’s most taxing task has been a trip to the doctors for a jab for Fliss. We are literally taking baby steps in building up our baby wrangling confidence.

To be fair to Ursula she’s not overly demanding as of yet. If she’s awake she is generally hungry (and/or in need of changing) otherwise she sleeps a lot. Today we got the first glimpses of a growing interest in the rest of the world, but mainly it’s the eating and sleeping that keeps us occupied. It’s a good design feature because they are fairly uncomplicated needs to fulfil when operating on a reduced sleep cycle. Still it felt like a small victory to have had a few hours of sleep each last night.

Tomorrow we may tackle the immense task of visiting town to obtain some heavily engineered mammary holders. Before that I need to work out exactly what the minimum functional travelling baby bag is.

Light at the end of the tunnel

Ursula is quite possibly the healthiest baby that has ever graced the Special Care Baby Unit at our local hospital. The sequence of events that led us there were more than a little concerning. As we were about to be discharged the midwife observed a leg twitch that didn’t look like the standard myoclonic twitch you expect with sleeping babies. This led to a summoning of the paediatric registrar followed by the consultant and her crash bag. At the time we wondered if it was just the hospital stalling our discharge as we were getting impatient to go home having been told the final blood test result was one hour away for several hours in a row.

There are a number of possible causes for these twitches, mostly neurological in nature with various infections including meningitis potentially acquired during the birth. After an examination the registrar assured us the most likely cause would be “just one of those things your baby does”. However they obviously wanted to rule out any of the other potential causes. Ursula was whisked up to the neo-natal intensive care unit and plugged up to various monitors and a cannula for monitoring and a series of tests. The experience was a little unsettling but the staff were very re-assuring and professional and obviously used to the shock that affects parents as their newborns get whisked into a room full of hospital beeps and alarms.

So far all the tests Ursula has been subjected to have come back negative. The only remaining possibility is meningitis for which the test involves a delicate lumbar puncture procedure. After 3 failed attempts (wriggly babies are very rarely compliant) they abandoned the notion. As a result the working assumption is it was caused by meningitis and Ursula needs to complete the anti-biotic course she has been on since she moved to the ICU. She has since been moved into the rather more sedate Special Care Baby Unit (less beeping, more space) where she continues to be a hungry, alert and otherwise very healthy baby.

Fliss was discharged on Wednesday and has been going through a bit of a hormonal roller-coaster as she comes home after spending the day feeding and reading to Ursula. However the end is in site and we hope to be bringing Ursula home on Monday evening (or possibly Tuesday morning) once she has finished her course of antibiotics.

The experience has been a little unsettling. It seems I’ve collected the “Parental Worry” trophy a bit earlier than I was planning. However I remain grateful to the professional NHS staff who have been taking care of our precious daughter where her health and not the cost of her care has been their top priority. Meanwhile I’ve been back to work for a few days so as not to burn all my paternity before the family is fully assembled at home.

Reaching escape velocity

The last few days have been frustrating. Every time we get ready to pack up and come home something comes up. First it was a bout of jaundice which needed seeing to. Now the pediatricians are being abundantly cautious about a twitch she has while she’s asleep. This has extended the sentence by at least another 48 hours which is really aggravating. Having a quite day or two to myself to potter and get the house ready is one thing, but at this rate I’ll have burnt all my paternity leave before my child gets home.

I feel bad for abandoning Fliss who keeps patiently sending me home to get another good nights sleep. I know it will be all right in the end but it’s definitely making me aggravated. I would like my family at home please!

Do the stars shine brighter tonight?

This was my thought as I unpacked the car tonight. It may have been the cold weather and clear skies though, it’s hard to be sure. I’m currently pottering around the house tidying up and preparing to welcome Ursula to the home tomorrow. I suspect my perspective may have altered in the last few days.

Lets start with the birth. As it approached it felt much like a late night after party when everything was getting a bit hazy. You know the sort, you’re sure someone said something profound but it’s been a very long night.

For a variety of totally mundane reasons it had taken us 28 hours to reach the dénouement of this particular hospital visit. I’ll spare the tedious details although I’ll happily give you the story as I remember it over a beer if you ask me in person. 28 hours is a long time to be awake and the sensation of transforming from the theoretical future parent to an actual real one is much akin to being launched off on a roller-coaster of unknown length and duration. I have now joined that biggest of shared clubs – hello my fellow breeders, I can talk about my child now ;-)

Picture of a newborn baby looking hungry

When I was ordered to bed the first night I excitedly blurted the news across the social media. I was worried I would bore my followers with parental ramblings before being reminded there are a lot of parents out there happy to share their experiences. I’ll be paying closer attention to what they say in the future on my journey to responsible adulthood.

I’ve ticked off a few things on my journey so far.

* My baby certainly didn’t look like Winston Churchill. I don’t know all those other parents cope ;-)
* Nappies aren’t really an issue, parental pragmatism kicks in pretty quickly.
* Nuzzling post-feed babies are indeed cute, even to a manly bloke like myself

I’m sure I am quickly acquiring the list of stereotypical parental behaviours. I get the sense it’s going to be a wild ride catching them all!