System/Core/Shell: Show full working directory in PS1

This commit is contained in:
Alec Murphy
2025-09-20 14:03:56 -04:00
parent 5ecae8fc20
commit b78af4911d

View File

@@ -219,8 +219,6 @@ U0 @shell_update_prompts(@shell* sh)
StrPrint(buf2, "/home/%s", &sh->session->user.name);
if (!StrCmp(&buf, &buf2))
StrCpy(&buf, "~");
else
StrCpy(&buf, StrLastOcc(&buf, "/") + 1);
StrPrint(&sh->PS1, "\x1b[0;32m[%s@%s %s]\x1b[1;37m\d ", &sh->session->user.name,
&sh->session->hostname, &buf);
}
@@ -234,8 +232,6 @@ U0 @shell_set_window_title(@shell* sh)
StrPrint(buf2, "/home/%s", &sh->session->user.name);
if (!StrCmp(&buf, &buf2))
StrCpy(&buf, "~");
else
StrCpy(&buf, StrLastOcc(&buf, "/") + 1);
StrPrint(buf3, "[%s@%s %s]", &sh->session->user.name,
&sh->session->hostname, &buf);
Stdio.WriteLine(sh, "\x1b]0;");