App and gem generators.

Clean up the app generation code and also add a separate gem generator. Since the "motion" command is not part of this open source repository, it is unfortunately not possible for me to extend the "motion create" command to include support for the gem generator. Instead, you have to specify that as an environment variable for now, like this:

	TEMPLATE=gem motion create test-gem