tool to build SmartOS changelog

Ugly as sin, but it even works in a Mountain Gorilla checkout where origin is in the cache directory and don't have the other branches visible...
If folks are working on topic branches or something and building images, probably the only safe thing to do is to require them to specify something manually as an argument, but make sure that if  you do nothing, it uses master and the last release branch.