 		loads = trimFiles([loads])[0]
 
 		processShim = ->
-			fileName = 'main.coffee'
-			template = getTemplate fileName
+			template = getTemplate mainFileName
 			trimmedRequire = getFileNameWithoutExtension req
 
 			config =

			compiled = grunt.template.process template
			dest = path.resolve cwd, req

			grunt.file.write dest, compiled

		createRequire()


		handleRemaining = ->
			files.forEach (file) ->
				console.log 'remaining', file
				loads.push(file) if file

			groups.push loads
