Miscellaneous code from over the years.