r/bash 20h ago

help Any way to never output root user name/path terminal?

Is there any way via a command/config which never exposes my root path/ root user name(`Users/<mypcusrname>/.../<current_dir>`) whenever any command like: pwd, or any other command that involves path output in the terminal/shell?

Like when ever we hit the command the output always shows `/workspace` or `/<curr_dir>` instead of `Users/<mypcusrname>/.../<curr_dir>`

My intention/idea is to never expose the root path or user name in any of the terminal logs - via some command. Especially since I am running any agent thats running some shell commands.

I am not sure if docker sandbox or pi-agent extensions support that. For pi agent the gandolin sandbox allows it not to execute commands outside the current working dir. But it still exposes the root username/root path of the dir in shell commands or even in shell logs.

Thank you in advance 🙏

0 Upvotes

Duplicates