refactoring; adding new --limit option