No, you can't. bash
and most other shells (except zsh
) don't allow nested substitution.
With zsh
, you can do nested substitution:
$ echo ${$(echo 123)/123/456} 456
No, you can't. bash
and most other shells (except zsh
) don't allow nested substitution.
With zsh
, you can do nested substitution:
$ echo ${$(echo 123)/123/456} 456