lib/tty/reader/history.rb
# Move the pointer to the previous line in the history
Move the pointer to the previous line in the history
Move the pointer to the previous line in the history
def previous
        return if size.zero?
        if @index.zero?
          @index = size - 1 if @cycle
        else
          @index -= 1
        end
      end
def previous return if size . zero? if @index . zero? @index = size - 1 if @cycle else @index -= 1 end end
Move the pointer to the previous line in the history
Move the pointer to the previous line in the history