bash, dash, fish, ksh, rbash, sh, zsh: refresh (#5714)

This commit is contained in:
bl-ue
2021-04-14 10:07:21 -04:00
committed by GitHub
parent 7755ac87fb
commit 16e4ed5c89
9 changed files with 100 additions and 73 deletions

View File

@@ -1,20 +1,30 @@
# rbash
> Restricted Bash shell.
> Similar to the `bash` shell with some restrictions like changing directories with `cd`, setting/unsetting of PATH, ENV variables and others.
> Restricted Bash shell, equivalent to `bash --restricted`.
> Does not permit changing the working directory, redirecting command output, or modifying environment variables, among other things.
> See also `histexpand` for history expansion.
> More information: <https://www.gnu.org/software/bash/manual/html_node/The-Restricted-Shell>.
- Start rbash:
- Start an interactive shell session:
`rbash`
- Execute a command:
- Execute a command and then exit:
`rbash -c "{{command}}"`
- Run commands from a file:
- Execute a script:
`rbash {{file.sh}}`
`rbash {{path/to/script.sh}}`
- Print the version information of rbash:
- Execute a script, printing each command before executing it:
`rbash --version`
`rbash -x {{path/to/script.sh}}`
- Execute commands from a script, stopping at the first error:
`rbash -e {{path/to/script.sh}}`
- Read and execute commands from stdin:
`rbash -s`