Added release script
Refactored compile script
Updated detect
Made variables upper case