(self, argument, from_tty)
return True
Keep a record of all commands which come from the TTY.

        Returns:
            True if this command was executed by the user just hitting "enter".
Keep a record of all commands which come from the TTY.
Keep a record of all commands which come from the TTY .
def check_repeated(self, argument, from_tty):
        """Keep a record of all commands which come from the TTY.

        Returns:
            True if this command was executed by the user just hitting "enter".
        """
        # Don't care unless it's interactive use
        if not from_tty:
            return False

        lines = gdb.execute('show commands', from_tty=False, to_string=True)
        lines = lines.splitlines()

        # No history
        if not lines:
            return False

        last_line = lines[-1]
        number, command = last_line.split(None, 1)
        try:
            number = int(number)
        except ValueError:
            # Workaround for a GDB 8.2 bug when show commands return error value
            # See issue #523
            return False

        # A new command was entered by the user
        if number not in Command.history:
            Command.history[number] = command
            return False

        # Somehow the command is different than we got before?
        if not command.endswith(argument):
            return False

        return True
def check_repeated ( self , argument , from_tty ) : # Don't care unless it's interactive use if not from_tty : return False lines = gdb . execute ( 'show commands' , from_tty = False , to_string = True ) lines = lines . splitlines ( ) # No history if not lines : return False last_line = lines [ - 1 ] number , command = last_line . split ( None , 1 ) try : number = int ( number ) except ValueError : # Workaround for a GDB 8.2 bug when show commands return error value # See issue #523 return False # A new command was entered by the user if number not in Command . history : Command . history [ number ] = command return False # Somehow the command is different than we got before? if not command . endswith ( argument ) : return False return True