[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Documentation] Parameter expansion: missing colon in example
From: |
private |
Subject: |
[Documentation] Parameter expansion: missing colon in example |
Date: |
Fri, 21 Jul 2023 20:37:53 +0200 (CEST) |
Hello,
The example on parameter expansion[1] should perhaps read :
$ echo ${v:-unset}
instead of :
$ echo ${v-unset}
Yes ? More context:
---8<---
${parameter:-word}
If parameter is unset or null, the expansion of word is substituted. Otherwise,
the value of parameter is substituted.
$ v=123
$ echo ${v-unset}
123
--->8---
Thanks !
--
1.
https://www.gnu.org/software/bash/manual/html_node/Shell-Parameter-Expansion.html
- [Documentation] Parameter expansion: missing colon in example,
private <=