Coverted to a rake task.