Skip to content

Commit

Permalink
1. fix lint error
Browse files Browse the repository at this point in the history
2. add logMessage in README.
  • Loading branch information
HenryRiley0 authored and WebFreak001 committed May 30, 2024
1 parent 1695116 commit f204573
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -213,4 +213,10 @@ differently based on whether the remote system is a POSIX or a Windows system.
You may need to experiment to find the correct escaping necessary for the command to be
sent to the debugger as you intended.

### LogMessage

LogMessage will print a message in the debug console when breakpoint is hit. Expressions within {} are interpolated.

![LogMessage](images/logMessage.gif)

## [Issues](https://github.com/WebFreak001/code-debug)
Binary file added images/logMessage.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 1 addition & 3 deletions src/backend/mi2/mi2.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ class LogMessage {
}
}
}
return null
return undefined;
}
}

Expand Down Expand Up @@ -639,7 +639,6 @@ export class MI2 extends EventEmitter implements IBackend {
commands += `\"print ${m[1]}\" `;
}
}
commands += "\"continue\"";
return this.sendCommand("break-commands " + bkptNum + " " + commands);
}

Expand Down Expand Up @@ -696,7 +695,6 @@ export class MI2 extends EventEmitter implements IBackend {
breakpoint.id = newBrk.id;
this.breakpoints.set(newBrk, bkptNum);
this.logMessage.logMsgBrkList.push(breakpoint);

resolve([true, newBrk]);
} else {
resolve([false, undefined]);
Expand Down

0 comments on commit f204573

Please sign in to comment.