rust-bash 0.3.0

A sandboxed bash interpreter for AI Agents with a virtual filesystem
Documentation
# THIS FILE IS AUTOMATICALLY GENERATED BY CARGO
#
# When uploading crates to the registry Cargo will automatically
# "normalize" Cargo.toml files for maximal compatibility
# with all versions of Cargo and also rewrite `path` dependencies
# to registry (e.g., crates.io) dependencies.
#
# If you are reading this file be aware that the original Cargo.toml
# will likely look very different (and much more reasonable).
# See Cargo.toml.orig for the original contents.

[package]
edition = "2024"
name = "rust-bash"
version = "0.3.0"
build = false
exclude = [
    "packages/",
    "package-lock.json",
    ".github/",
    "docs/plans/",
    "cbindgen.toml",
    "include/",
    "scripts/",
    "AGENTS.md",
]
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "A sandboxed bash interpreter for AI Agents with a virtual filesystem"
homepage = "https://rustbash.dev"
documentation = "https://docs.rs/rust-bash"
readme = "README.md"
keywords = [
    "bash",
    "shell",
    "interpreter",
    "sandbox",
    "virtual-filesystem",
]
categories = [
    "command-line-utilities",
    "development-tools",
    "parser-implementations",
    "wasm",
    "emulators",
]
license = "MIT"
repository = "https://github.com/shantanugoel/rust-bash"

[features]
cli = [
    "dep:clap",
    "dep:rustyline",
]
default = [
    "cli",
    "network",
    "native-fs",
]
ffi = ["dep:serde"]
native-fs = []
network = [
    "dep:ureq",
    "dep:url",
]
wasm = [
    "dep:wasm-bindgen",
    "dep:js-sys",
    "dep:serde",
    "dep:serde-wasm-bindgen",
]

[lib]
name = "rust_bash"
crate-type = [
    "lib",
    "cdylib",
]
path = "src/lib.rs"

[[bin]]
name = "rust-bash"
path = "src/main.rs"
required-features = ["cli"]

[[example]]
name = "shell"
path = "examples/shell.rs"

[[test]]
name = "cli"
path = "tests/cli.rs"

[[test]]
name = "comparison"
path = "tests/comparison.rs"
harness = false

[[test]]
name = "ffi"
path = "tests/ffi.rs"

[[test]]
name = "filesystem_backends"
path = "tests/filesystem_backends.rs"

[[test]]
name = "help_flag"
path = "tests/help_flag.rs"

[[test]]
name = "integration"
path = "tests/integration.rs"

[[test]]
name = "oils_spec"
path = "tests/oils_spec.rs"
harness = false

[[test]]
name = "spec_tests"
path = "tests/spec_tests.rs"
harness = false

[dependencies.base64]
version = "0.22"

[dependencies.bitflags]
version = "2.11.0"

[dependencies.brush-parser]
version = "0.3.0"

[dependencies.chrono]
version = "0.4"

[dependencies.clap]
version = "4.6.0"
features = ["derive"]
optional = true

[dependencies.flate2]
version = "1"
features = ["rust_backend"]
default-features = false

[dependencies.jaq-core]
version = "3.0.0-gamma"

[dependencies.jaq-json]
version = "2.0.0-gamma"

[dependencies.jaq-std]
version = "3.0.0-gamma"

[dependencies.md-5]
version = "0.10"

[dependencies.parking_lot]
version = "0.12.5"

[dependencies.regex]
version = "1.12.3"

[dependencies.rustyline]
version = "17.0.2"
optional = true

[dependencies.serde]
version = "1.0.228"
features = ["derive"]
optional = true

[dependencies.serde_json]
version = "1"

[dependencies.sha1]
version = "0.10"

[dependencies.sha2]
version = "0.10"

[dependencies.similar]
version = "2.7.0"

[dependencies.tar]
version = "0.4"

[dev-dependencies.assert_cmd]
version = "2.2.0"

[dev-dependencies.datatest-stable]
version = "0.3.3"

[dev-dependencies.insta]
version = "1.46.3"

[dev-dependencies.predicates]
version = "3.1.4"

[dev-dependencies.rustyline]
version = "17.0.2"

[dev-dependencies.serde]
version = "1.0.228"
features = ["derive"]

[dev-dependencies.tempfile]
version = "3.27.0"

[dev-dependencies.toml]
version = "1.0.7"

[dev-dependencies.toml_edit]
version = "0.25.5"

[target.'cfg(not(target_arch = "wasm32"))'.dependencies.ureq]
version = "3"
optional = true

[target.'cfg(not(target_arch = "wasm32"))'.dependencies.url]
version = "2.5.8"
optional = true

[target.'cfg(target_arch = "wasm32")'.dependencies.chrono]
version = "0.4"
features = ["wasmbind"]

[target.'cfg(target_arch = "wasm32")'.dependencies.js-sys]
version = "0.3.91"
optional = true

[target.'cfg(target_arch = "wasm32")'.dependencies.serde-wasm-bindgen]
version = "0.6.5"
optional = true

[target.'cfg(target_arch = "wasm32")'.dependencies.wasm-bindgen]
version = "0.2.114"
optional = true

[target.'cfg(target_arch = "wasm32")'.dependencies.web-time]
version = "1.1.0"

[profile.release-wasm]
opt-level = "z"
lto = true
codegen-units = 1
panic = "abort"
inherits = "release"
strip = true