From 14f29806879149fa4767ea1f7a0ddd694efe16ef Mon Sep 17 00:00:00 2001 From: Niel Nielsen Date: Tue, 25 Aug 2026 14:07:34 +0200 Subject: [PATCH] Add device name to prompt composition Include device name in prompt composition. Signed-off-by: Niel Nielsen --- client/src/proxmark3.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/client/src/proxmark3.c b/client/src/proxmark3.c index 0e9e33b7a..395f49db0 100644 --- a/client/src/proxmark3.c +++ b/client/src/proxmark3.c @@ -350,10 +350,11 @@ static void prompt_set(void) { } static void prompt_compose(char *buf, size_t buflen, const char *promptctx, const char *promptdev, const char *promptnet, bool no_newline) { + const char *dev_name = IfPm5() ? "pm5" : "pm3"; if (no_newline) { - snprintf(buf, buflen - 1, PROXPROMPT_COMPOSE, promptdev, promptnet, promptctx); + snprintf(buf, buflen - 1, PROXPROMPT_COMPOSE, promptdev, promptnet, promptctx, dev_name); } else { - snprintf(buf, buflen - 1, _CLR_LINE_ "\r" PROXPROMPT_COMPOSE, promptdev, promptnet, promptctx); + snprintf(buf, buflen - 1, _CLR_LINE_ "\r" PROXPROMPT_COMPOSE, promptdev, promptnet, promptctx, dev_name); } }