Finally cleaned up finding source code files, should be suitable for general purpose use