Skip to content

Commit 6aad623

Browse files
authored
Merge pull request #8 from capsulerun/mavdol-patch-1
Edit descriptions for clarity and conciseness
2 parents 1ba29f6 + 7154f17 commit 6aad623

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

content/blog/reimagining-bash-for-untrusted-contexts.mdx

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
---
22
title: "Reimagining Bash for untrusted contexts"
33
date: "2026-04-28"
4-
description: "Bash is designed for humans and it should stay that way. When I talk about untrusted contexts, I mean automated processes and AI agents. Both scenarios come to the same conclusion: they are trying to act like humans, but in reality, they don't have the same constraints."
4+
description: "Bash is designed for humans and it should stay that way. When I talk about untrusted contexts, I mean automated processes and AI agents. Both scenarios come to the same conclusion: they are trying to act like humans, but in reality, don't have the same constraints."
55
---
66

77
Bash is designed for humans and it should stay that way. When I talk about untrusted contexts, I mean automated processes and AI agents. Both scenarios come to the same conclusion: they are trying to act like humans, but in reality, they don't have the same constraints.
88

9-
As humans, we don't constantly need textual feedback to reach our goals. We have other concerns like efficiency, developer experience (including visual comfort and ergonomics), concerns that agents don't share.
9+
As humans, we don't constantly need textual feedback to reach our goals. We have other concerns like efficiency, developer experience (including visual comfort and ergonomics). Concerns that agents don't share.
1010

1111
Bash delivers this experience perfectly for us, but not for untrusted processes.
1212

@@ -16,7 +16,7 @@ Since agents are trained on human data, they know how to use Bash by default. Ho
1616

1717
Commands fall into three categories: Observation (ls, grep, cat), Mutation (rm, mv, mkdir), and State (cd, export) which alter the context.
1818

19-
The question arises mainly for mutation and state commands. Humans consider the silence of these as a success; it's the convenient behavior. Having plenty of messages confirming it succeeded would bring a lot of noise into our shell, and we usually don't want that.
19+
The question arises mainly for mutation and state commands. Humans consider their silence as a success; it's the convenient behavior. Having plenty of messages confirming it succeeded would bring a lot of noise into our shell, and we usually don't want that.
2020

2121
For agents, on the other hand, I believe each command should report clear details on state, filesystem changes, and environment configuration to provide the observability and determinism they need.
2222

@@ -30,17 +30,17 @@ This approach also enriches the context, giving more landmarks to work with.
3030

3131
Sandboxing is the first word that comes to mind when we talk about untrusted processes. If we want to reimagine a Bash adapted for this, it would be a missed opportunity not to have a native sandbox system.
3232

33-
In fact, mutation commands could be handwritten, so we might think sandboxing is less important. But for cases like python3 command, where an agent executes arbitrary code, it becomes essential. That's why we absolutely want to natively sandbox every logic execution.
33+
In fact, mutation commands could be handwritten, so we might think sandboxing is less important. But for cases like python3 command, where an agent executes arbitrary code, it becomes essential. We absolutely want to natively sandbox every logic execution.
3434

3535
<SandboxAnimation />
3636

37-
It's interesting to maintain this philosophy and additionally provide its own workspace to not pollute the user's file system.
37+
It's essential to maintain a similar philosophy and additionally provide its own workspace to isolate it from the user's file system.
3838

3939
## Reimagining it
4040

4141
In theory, the solution is quite simple: add more information to the output. In practice, we can't natively structure the commands' output within the existing Bash paradigm.
4242

43-
To me, the only way is to rebuild Bash commands. The good news is, we don't necessarily need to rebuild everything, only the important ones for untrusted processes. Some open-source alternatives already explore different philosophies, but none quite fit the need yet.
43+
To me, the only way is to rebuild Bash commands. The good news is, we don't necessarily need to rewrite everything, only the important ones for untrusted processes. Some open-source alternatives already explore different philosophies.
4444

4545
I also created a light proof of concept in TypeScript. It's a long-term project, so it will depend on you and other people wanting to collaborate on this. Feel free to check it out 👉 [GitHub](https://github.com/capsulerun/bash)
4646

0 commit comments

Comments
 (0)