From 24900071426ad1f3e835c7ec2de212dd4a304606 Mon Sep 17 00:00:00 2001
From: Jo-Philipp Wich <jow@openwrt.org>
Date: Thu, 18 Sep 2014 09:29:44 +0000
Subject: [PATCH] script/remote-gdb: enable and keep command history

Signed-off-by: Jo-Philipp Wich <jow@openwrt.org>

SVN-Revision: 42609
---
 scripts/remote-gdb | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/scripts/remote-gdb b/scripts/remote-gdb
index 380a22511b..98ec768f4b 100755
--- a/scripts/remote-gdb
+++ b/scripts/remote-gdb
@@ -65,6 +65,11 @@ if( opendir SD, "$Bin/../staging_dir" )
 		-f $ARGV[0] and $cmd = "core-file";
 		print $fh "$cmd $ARGV[0]\n";
 
+		# History settings
+		print $fh "set history filename $Bin/../tmp/.gdb_history\n";
+		print $fh "set history size 100000000\n";
+		print $fh "set history save on\n";
+
 		my $file = -f "$sysroot/$ARGV[1]" ? "$sysroot/$ARGV[1]" : $ARGV[1];
 		system($gdb, '-x', $fp, $file);
 
-- 
GitLab