Small refactor and adding rake file