Clean up Main and Chmod