Skip to content

Commit 13df4b1

Browse files
committed
Save the dashboard instance as a global variable
This allows custom commands to make use of the dashboard instance, see: https://github.com/cyrus-and/gdb-dashboard/wiki/Develop-custom-commands This should ease the adoption of custom dashboard Python commands like the one suggested in #257.
1 parent 6c22257 commit 13df4b1

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

.gdbinit

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -574,6 +574,8 @@ class Dashboard(gdb.Command):
574574

575575
@staticmethod
576576
def start():
577+
# save the instance for customization convenience
578+
global dashboard
577579
# initialize the dashboard
578580
dashboard = Dashboard()
579581
Dashboard.set_custom_prompt(dashboard)

0 commit comments

Comments
 (0)