Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ExecContext ¶
type ExecContext struct {
Stdin io.Reader
Stdout, Stderr io.Writer
Dir string
Environ expand.Environ
FS billy.Filesystem
// Runner is the active shell runner. Commands that need to dispatch a
// child command (for example, `time CMD`) should call Runner.Subshell()
// and re-enter the shell so the call goes through the same exec handler
// chain instead of poking at the registry directly. May be nil in
// embedders or tests that have not wired up a runner.
Runner *interp.Runner
}
func (*ExecContext) GuestPWD ¶
func (ec *ExecContext) GuestPWD() string
GuestPWD maps the fsys-relative Dir into the absolute path a WASI guest sees, given the billy filesystem is mounted at "/". Returns "/" when Dir is unset or ".". Used to seed the guest's PWD env var so a guest that honors it (see command/uutils/pwd-hack.patch) resolves relative paths against the shell's current directory rather than the filesystem root.
Directories
¶
| Path | Synopsis |
|---|---|
|
internal
|
|
|
env
Package env implements the env(1) coreutil: run a program in a modified environment, or print the current environment when no command is given.
|
Package env implements the env(1) coreutil: run a program in a modified environment, or print the current environment when no command is given. |
|
Package wasmcommand adapts a WASI WebAssembly program to a Kefka command.
|
Package wasmcommand adapts a WASI WebAssembly program to a Kefka command. |
Click to show internal directories.
Click to hide internal directories.