Implement the done command, refactor a lot of error checking
Only parse the argument if there is actually one
Refactor some common behavior and implement the rollback command