| 1 |
@since(version = 0.2.0) |
| 2 |
interface environment { |
| 3 |
/// Get the POSIX-style environment variables. |
| 4 |
/// |
| 5 |
/// Each environment variable is provided as a pair of string variable names |
| 6 |
/// and string value. |
| 7 |
/// |
| 8 |
/// Morally, these are a value import, but until value imports are available |
| 9 |
/// in the component model, this import function should return the same |
| 10 |
/// values each time it is called. |
| 11 |
@since(version = 0.2.0) |
| 12 |
get-environment: func() -> list<tuple<string, string>>; |
| 13 |
|
| 14 |
/// Get the POSIX-style arguments to the program. |
| 15 |
@since(version = 0.2.0) |
| 16 |
get-arguments: func() -> list<string>; |
| 17 |
|
| 18 |
/// Return a path that programs should use as their initial current working |
| 19 |
/// directory, interpreting `.` as shorthand for this. |
| 20 |
@since(version = 0.2.0) |
| 21 |
initial-cwd: func() -> option<string>; |
| 22 |
} |