Modified Bash Cheatsheet
This commit is contained in:
parent
a0c689bd32
commit
b05c0a470e
|
@ -128,16 +128,18 @@ else
|
||||||
fi
|
fi
|
||||||
```
|
```
|
||||||
# Conditions
|
# Conditions
|
||||||
| Operator | Description |
|
| Operator | Description |
|
||||||
|----------|----------------------|
|
|----------|--------------------------|
|
||||||
| -eq | Equal |
|
| -eq | Equal |
|
||||||
| -lt | Less than |
|
| -lt | Less than |
|
||||||
| -ge | Greater than |
|
| -le | Less than or equal to |
|
||||||
| == | 2 Strings equal |
|
| -gt | Greater than |
|
||||||
| != | 2 Strings not equal |
|
| -ge | Greater than or equal to |
|
||||||
| ! | Statement is false |
|
| == | 2 Strings equal |
|
||||||
| -d | Directory is present |
|
| != | 2 Strings not equal |
|
||||||
| -e | File is present |
|
| ! | Statement is false |
|
||||||
|
| -d | Directory is present |
|
||||||
|
| -e | File is present |
|
||||||
|
|
||||||
## Condition Usage Examples
|
## Condition Usage Examples
|
||||||
``` bash
|
``` bash
|
||||||
|
|
Loading…
Reference in New Issue