23 lines
463 B
Markdown
23 lines
463 B
Markdown
|
# conditions.
|
||
|
## one after another.
|
||
|
```bash
|
||
|
foo; bar # bar will run after foo finishes.
|
||
|
```
|
||
|
|
||
|
## AND.
|
||
|
```bash
|
||
|
foo && bar # bar will only run if foo succeeded.
|
||
|
foo && { bar1; bar2; } # both will run in foo succeeded.
|
||
|
```
|
||
|
|
||
|
## OR.
|
||
|
```bash
|
||
|
foo || bar # bar will only run in foo failed.
|
||
|
foo || { bar1; bar2; } # both will run if foo failed.
|
||
|
```
|
||
|
|
||
|
## one at the same time with another.
|
||
|
```bash
|
||
|
foo & bar # they will both run at the same time.
|
||
|
```
|