Implement truncate command.
Add documentation.