Remove tmp file
Add *.swp to .gitignore
Refactor to a class