cleaned up the main script, redid the switch as function

added project groups file to make it easier to maintain.