docs: def scroll_up(self):
          """
          Returns the previous command, if any.
          """
          self._index += 1
          nb_commands = len(self._history)
          if self._index >= nb_commands:
              self._index = nb_commands - 1
          try:
              return self._history[self._index]
          except IndexError:
              return ''