add '-version' option that outputs version string and exits