Moved code run code to a separate file