tldr/pages/common/zsh.md

38 lines
825 B
Markdown
Raw Normal View History

2016-02-19 16:53:19 +00:00
# zsh
> Z SHell, a Bash-compatible command-line interpreter.
> See also: `bash`, `histexpand`.
> More information: <https://www.zsh.org>.
2016-02-19 16:53:19 +00:00
- Start an interactive shell session:
2016-02-19 16:53:19 +00:00
`zsh`
- Execute specific [c]ommands:
2016-02-19 16:53:19 +00:00
`zsh -c "{{echo Hello world}}"`
2016-02-19 16:53:19 +00:00
- Execute a specific script:
2016-02-19 16:53:19 +00:00
`zsh {{path/to/script.zsh}}`
2016-02-19 16:53:19 +00:00
- Check a specific script for syntax errors without executing it:
`zsh --no-exec {{path/to/script.zsh}}`
- Execute specific commands from `stdin`:
`{{echo Hello world}} | zsh`
- Execute a specific script, printing each command in the script before executing it:
2016-02-19 16:53:19 +00:00
`zsh --xtrace {{path/to/script.zsh}}`
- Start an interactive shell session in verbose mode, printing each command before executing it:
`zsh --verbose`
- Execute a specific command inside `zsh` with disabled glob patterns:
`noglob {{command}}`