Can I build an OS X Image with preinstalled software? (Or, please help me move back one OS X version.)
Migration Assistant (in Applications/Utilities/ ) can restore programs and personal file data from a time machine backup.  I don't know if it would handle xcode or not.  Pretty much anything else in the /Applications/ folder it will re-install, though.  There might be some version conflicts with software that doesn't run in 10.7, etc.