Mercurial versus Git – For Now, I’ll Stick with Git

August 7th, 2009

Mercurial.gif

I was doing a little reading this morning and I came across another developer that was talking about how nice Mercurial was. He was mentioning a nice book he'd read on the subject and how much he liked the book. So I decided to take a little time this morning and give it a quick once over. Compare what I knew of Git to Mercurial and see how they stack up for my needs.

First, it's clear that each has a strong following. The linux kernel is in Git, and Google has adopted Mercurial. Both are strong statements to be considered. Certainly, if you're going to work on a project and it's in Subversion, or Git or Mercurial, then you have to do as the Romans do. But if you have a choice, and specifically, if I have a choice, what would I pick?

So what do I need? Well, I work on a laptop a lot of the time. Frankly, most of the time. I want something that's going to be significantly better than CVS - and I know CVS pretty darn well. Thankfully, both Git and Mercurial are winners here. There are Mac OS X GUI clients, and command line clients as well. Check.

Xcode support is important, but with the changes in Xcode to use ASCII files as opposed to binary files for nibs, I don't have to worry too much about this. Also, they have removed the 'bundle' concept for most things in Xcode, so I don't have to worry about directories appearing and disappearing on me. To be fair, Apple did all this work on it's own. That the SCM of choice doesn't have to worry about it is nice, but not leaning one way or the other.

I'll grant you that Mercurial is more like CVS, in that it's file-based and simple to understand. There's even a built-in web server to make it easy to act as a server for remote users to 'pull' a repository. Not bad. But Git has Gitosis, and now that I have it running, it's a server that I don't have to think about. It just runs. Period.

I could try to get Mercurial up on my Mac at home where I have CVS and Gitosis, but then I need to get Python 2.5 on that box, and it's an old Mac - suitable for the serving of these files, but it's not got the up to date Python that Leopard has. So that would be a pain. Not impossible, but a pain.

I guess it comes down to inertia.

I have Git, I have GitX, and they work. I have CVS for the old stuff, and it's never going away. Never. In the end, I might do some Mercurial work, but I'm guessing that it's even money that I'll stick with Git. It's just as nice and I have it all set up.

NetNewsWire 3.2b14 is Out

August 7th, 2009

NetNewsWire3.2.jpg

The changes are coming fast and furious now with NetNewsWire 3.2 - today we have 3.2b14 released with the Sparkle release notes:

  • Fixed a bug where & and similar would appear in title list instead of &.
  • Sending 30 mark-read/mark-unread items in one call rather than 10, for better efficiency.
  • Marking an item as unread is now communicated to Google Reader.
  • Doesn't send mark read or unread actions for items where Google has locked the read state (for efficiency).
  • Fixed a bug parsing and displaying enclosures.
  • Fixed a bug where moving a feed -- but keeping it inside its folder -- would make it jump out to the top level.
  • Possibly fixed a crashing bug in drawing titles in the vertical tabs table.
  • Report Bug/Feature window now sends NetNewsWire settings info (optionally) instead of system details -- because NetNewsWire info is way more useful in figuring things out. (Saves some time asking questions.)
  • Doesn't allow editing the feed URL for a Google-synced feed (since this isn't supported by the API).
  • Fixed a bug where showing/hiding read items would get confused.
  • Fixed a bug subscribed to a feed and saying it should not be synced -- those feeds were getting deleted right away after subscribing. (No longer.)
  • Fixed a bug where feeds set to not sync would still get sent to Reader when merging subscriptions (either at first-run or manually).
  • Fixed the query string that identifies NetNewsWire in the URL when downloading feeds. (A little thing Google needs.)
  • Easier-to-read formatting of Google feeds in the view-feed-source window.
  • Fixed a bug that could cause the description areas of the Combined View to be empty when a feed says that its home page is http://

So the public beta really is picking up a lot of little things, and Brent is turning them around into a new release almost daily. Pretty impressive.

Finally Getting my Alerts Working Properly

August 6th, 2009

cubeLifeView.gif

I'm finally pretty happy that the alerts in my web system are working as they should. The aggregated values are being calculated properly, the alerts are being triggered correctly, it's all working as it should. This is a "Big Deal" as it's one of the important things this guy was supposed to do - alert people via "push methods" (email and chat for now) of problems in the data. With these alerts in place, it's easier to let people not look at the data all day long, and have it alert them to problems. With a good set of alerts in place, it'll be easy to have the right people informed of the proper conditions.

Sure, it's geeky, but this is what it often comes down to - being able to finally bend this code into what I want it to be and seeing the results play out in front of me.

DrawIt 3.8.4 is Out

August 6th, 2009

DrawIt.jpg

This morning when I was updating to Mac OS X 10.5.8, I checked on DrawIt, and saw that they had released a new version: DrawIt 3.8.4. The list of changes is pretty small:

  • Fixes bugs with moving groups around
  • Fixes bugs related to the bevel filter
  • Minor UI fixes

but anytime someone is still working on code to improve it, I'm a happy guy. Snow Leopard is just around the corner, and I want to believe that all the apps I use are going to be safely ported to that platform.

Mac OS X 10.5.8 is on Software Updates

August 6th, 2009

Leopard.jpg

This morning I noticed that Mac OS X 10.5.8 is on Software Updates with a list of security and stability fixes. Makes sense. They are putting all the new work into Snow Leopard now - due out in about a month. This is a "clean up" release - getting security fixes into the libraries, etc. as they get ready to put this OS into maintenance mode.

Can't blame them, I'm excited about Snow Leopard too. Still, nice to know that I'm a little bit better protected against the script kiddies that live in their parent's basements and have nothing better to do than attach computers.

Getting Caught by Java’s References

August 5th, 2009

java-logo-thumb.png

I was working on a problem today with the alerts in my web system and I was having a really hard time getting a handle on the problem. Basically, I had an object that did n-point moving average calculations on a data stream and I wanted to use that to feed a data aggregator where all the data from the n-point smoothing would be summed up across the firm to get "totals" that could be used in the alert expressions.

I had built the n-point moving average class to expose a 'previous' and 'current' array of data so that it looked just like the incoming data - an Object[]. I did this by having two such Object[] instance variables - one for the 'previous' and the other for the 'current'. When a new value came in, I'd copy the contents of the 'current' to the 'previous', add in the new, subtract out the old, and save the new as the old for this contributor. It worked like a dream.

What I was seeing was that the data going into the firm aggregator was showing the same values in the 'previous' and 'current' data arrays! This simply could not be. In the aggregator, I was saving the data from the n-point smoother, by contributor, similarly to the n-point smoother itself, so that we can add in the new, remove the old, save the new as the old, and get a nice running aggregation.

But it wasn't working that way.

And it took me several hours to figure it out. But I did.

References. Java references are somewhat deceptive. In C++ I'd know what I was doing more clearly because I'd have to be more careful with the heap variables. Stack variables were easy as they went out of scope and were gone. Copies were cheap, relatively.

But in Java, everything is a reference. So when I was getting the 'previous' and 'current' data from the n-point smoother, I was really getting the reference to the arrays I was using as storage. When I then got new data into the n-point smoother, I updated that data, and naturally, the data in the aggregator would change as well. After all, it's the same reference.

Ah!

So what I had to do was to make copies of the data coming out of the n-point smoother and into the aggregator. These, then formed snapshots of the data coming out and were exactly what I needed in the data flow.

In general, there's a lot to like about Java. Garbage Collection is one of them. But there are times that the visual warning of pointers in C++ makes it much easier to see issues - or potential issues. I've been coding for a while, and this guy flew right past me for several hours. That's tough to find.

One Big “Woo Hoo” to Adium – Inspirational Software

August 5th, 2009

Adium.jpg

I communicate on IM all the time. I use it to keep in touch with my friends, help co-workers, and in general, it's the "one line email" that I simply can't imagine functioning without. It's what keeps me in touch with people I want/need to be in touch with. And on the Mac, there's one IM client that had such an incredible user-experience, that I feel I have to say something special about it.

Adium is one of the very best examples of software "done right" that I can think of. It "just works". It gets out of the way so easily that you wonder if it's really doing anything. It's quiet and unobtrusive when it's idle, and when it's necessary - it's as in-your-face as you want it to be. It's clean code. It doesn't crash. It just works.

It's a toaster.

To me, that's one of the greatest compliments you can pay to a piece of software. No need to wonder how to use it - it's obvious. No need to worry about breaking it - it's sturdy. It's a toaster.

Yet some of the neatest things are in the details. For example, it could do a lot less than it does and still be wonderful. But it allows you to really control your IM experience - groups, aliases, all work seamlessly and beautifully. It allows you to make the IM experience what you want - not what the developer wanted for you. It's really quite amazing.

Certainly, there are probably thousands of man-hours in this code, and it's been beaten on and tested to the limits. But still... it's Open Source. That's saying a lot. When a piece of free software is the best of it's class, it's more than just impressive... it's almost... magical.

It makes you think all programs can do this - be this. And for me at least, it makes me want to make my code this good. It's inspirational.

Developing for the Mac or the iPhone

August 5th, 2009

xcode.jpg

I have to say, I do really enjoy my iPhone. It's the best phone I've ever had, and a wonderful mobile computing platform to boot. But when I think about developing for it, I have to look at the stories of App Store Rejection, and wonder if it's worth it. Sure, more apps are accepted than rejected, but is that because they are little productivity apps and games? They can't really push the envelope, or they'll get rejected. Simple things like dictionaries, game emulators, and such are all being rejected by Apple on grounds that seem, at least to many, to be nearly arbitrary.

Coding is a lot of fun, and you have to be passionate about it to do a great job. This "maybe I will, maybe I won't" situation could have you invest a good chunk of time into an app, and then find that it's not allowed to be presented to potential users. Free or not, the same rules seem to apply.

I'm just not convinced that I could go through that cycle. Writing for the Mac, however, has no such limitations. This represents a clear choice to me.

Pushing Through a Pretty Tough Time

August 4th, 2009

There are times when everything seems to be clicking. When you're on top of the world, things are going your way, and it seems that time flies.

And then there are the other times.

Times when time itself drags.

You wonder if you're up to finishing the next hour, let alone the day. When it seems that there is nothing that's going to get you moving through the day. Really bad times.

Well... the last few days have been like that. Things with the kids are troubling - hey, they're teenagers, and if I"m not worried, then there's something really wrong with them - or me. But still... there's worry, and then there's the grief only those that love you can fling your way.

So I'm trying to work through it. Trying to keep busy and let time travel by, and in doing so, give the kids and me a little break from one another. That's all it takes - really. A little change of view. Get started back at school and things will change. With that change, maybe we can reach each other again.

I know it's just a simple matter of a few years. After college, they'll be great people again. But I'd hate to think that the last days they are here in the house are going to be miserable. That's not a lot of fun for me - or them.

Well... there's not a lot I can do about it other than what I am doing. I just hope it all works out.

Upgraded to WordPress 2.8.3 at HostMonster

August 4th, 2009

wordpress.gif

This morning I noticed that there were additional bugs found in the WordPress 2.8.2 security upgrade, so out comes 2.8.3. The release notes from the WordPress Blog are simple:

Unfortunately, I missed some places when fixing the privilege escalation issues for 2.8.1. Luckily, the entire WordPress community has our backs. Several folks in the community dug deeper and discovered areas that were overlooked. With their help, the remaining issues are fixed in 2.8.3. Since this is a security release, upgrading is highly recommended. Download 2.8.3, or upgrade automatically from your admin.

Given that upgrading is so simple at HostMonster with SimpleScripts, it's a no-brainer. If there's a security update, I want to get it. I've got a lot stored in this guy, and keeping it safe is a key concern for me.