Open thejpster opened 5 years ago
So, we treat the byte slice as a ring buffer. We put a special delimiter in in-between each command. This lets us wind backwards and find the previous command when a user presses up. Once the buffer is full, we delete whole commands at a time from the trail to make space.
Should implement history - as much as fits in the given buffer (including the current line, if anything has been entered).