From 27f49f64f2e9975ac39c9a48b9e2482a5eb96d14 Mon Sep 17 00:00:00 2001 From: Stefan Rueger Date: Tue, 13 Jun 2023 00:15:11 +0100 Subject: [PATCH] Document terminal subshell command ! --- src/avrdude.1 | 3 +++ src/doc/avrdude.texi | 5 +++++ src/term.c | 2 +- 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/src/avrdude.1 b/src/avrdude.1 index 9594a07e..33bf1c67 100644 --- a/src/avrdude.1 +++ b/src/avrdude.1 @@ -1162,6 +1162,9 @@ Leave terminal mode and thus .Nm avrdude . .It Ar q Can be used as an alias for quit. +.It Ar ! +Run the shell in a subshell, eg, !ls *.hex. Subshell commands are +always complete lines on their own. .El .Pp The terminal commands below may only be implemented on some specific programmers, and may therefore not be available in the help menu. diff --git a/src/doc/avrdude.texi b/src/doc/avrdude.texi index 091b5dfc..1a1e6855 100644 --- a/src/doc/avrdude.texi +++ b/src/doc/avrdude.texi @@ -2281,6 +2281,11 @@ Leave terminal mode and thus AVRDUDE. @item q Can be used as an alias for @code{quit}. +@item !@var{line} +Run the shell @var{line} in a subshell, eg, @code{!ls *.hex}. Subshell +commands are always complete lines on their own. + + @end table @noindent diff --git a/src/term.c b/src/term.c index 0feafc3c..170b1dfd 100644 --- a/src/term.c +++ b/src/term.c @@ -1675,7 +1675,7 @@ static int cmd_help(const PROGRAMMER *pgm, const AVRPART *p, int argc, char *arg term_out(cmd[i].desc, cmd[i].name); term_out("\n"); } - term_out(" ! : run the command in a subshell, eg, !ls\n\n" + term_out(" ! : run the shell in a subshell, eg, !ls *.hex\n\n" "For more details about a terminal command cmd type cmd -?\n\n" "Note that not all programmer derivatives support all commands. Flash and\n" "EEPROM type memories are normally read and written using a cache via paged\n"