Document spawn options to sh method

This commit is contained in:
Josh Holtrop 2022-02-27 16:07:35 -05:00
parent b2d47cd439
commit 3cfffed7ec

View File

@ -1508,6 +1508,18 @@ default do
end end
``` ```
Options that Ruby's `spawn` method accepts can also be passed in to the `sh`
method.
For example, to execute the given command with a different working directory,
the `:chdir` option can be specified:
```ruby
default do
# Execute 'ls' from within the 'src' directory:
sh "ls", chdir: "src"
end
```
##> Extending Rscons ##> Extending Rscons
### Adding New Languages ### Adding New Languages