-a and -o are not valid in [[ .. ]]

James Morris
2023-11-13 11:00:42 -05:00
parent ad1322afb1
commit 6d24ed7d55

@@ -3,13 +3,13 @@
### Problematic code:
```sh
[[ -e ~/.bashrc -a \( -x /bin/dash -o -x /bin/ash \) ]]
[[ -e ~/.bashrc && \( -x /bin/dash || -x /bin/ash \) ]]
```
### Correct code:
```sh
[[ -e ~/.bashrc -a ( -x /bin/dash -o -x /bin/ash ) ]]
[[ -e ~/.bashrc && ( -x /bin/dash || -x /bin/ash ) ]]
```
### Rationale: