From 191a24110a6e680fbadb312ce5e18956fdb98af6 Mon Sep 17 00:00:00 2001 From: Bananymous Date: Sun, 18 Jun 2023 23:35:51 +0300 Subject: [PATCH] Userspace: Shell now sets SHELL environment variable --- userspace/Shell/main.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/userspace/Shell/main.cpp b/userspace/Shell/main.cpp index 087ca82f19..0dd4c5afb2 100644 --- a/userspace/Shell/main.cpp +++ b/userspace/Shell/main.cpp @@ -217,6 +217,9 @@ void print_prompt() int main(int argc, char** argv) { + if (argc >= 1) + setenv("SHELL", argv[0], true); + tcgetattr(0, &old_termios); new_termios = old_termios;