Mint
This commit is contained in:
@@ -283,7 +283,11 @@ test=$(find $dir -name "$name" -mmin -5 -maxdepth 1)
|
||||
Si les chaines sont <u>*identiques*</u> [ STRING1 == STRING2 ]
|
||||
|
||||
```bash
|
||||
if [ “$1” == “moo” ]; then
|
||||
if [ “$1” = “moo” ]; then
|
||||
```
|
||||
|
||||
```bash
|
||||
if [[ “$1” == “moo” ]]; then
|
||||
```
|
||||
|
||||
Si les chaines sont <u>*différentes*</u> [ STRING1 != STRING2 ]
|
||||
@@ -292,6 +296,18 @@ Si les chaines sont <u>*différentes*</u> [ STRING1 != STRING2 ]
|
||||
if [ “$userinput” != “$password” ]; then
|
||||
```
|
||||
|
||||
Si la chaine 1 *<u>contient la sous-chaine</u>* chaine 2 [ STRING1 != STRING2 ]
|
||||
|
||||
```bash
|
||||
if [ “$userinput” == *“$password”* ]; then
|
||||
if [ “$userinput” == “$password”* ]; then
|
||||
if [ “$userinput” == *“$password” ]; then
|
||||
```
|
||||
|
||||
```bash
|
||||
if [ “$userinput” =~ .*$password.* ]; then
|
||||
```
|
||||
|
||||
Si la chaine 1 <u>*est triée après*</u> la chaine 2 [ STRING1 > STRING2 ]
|
||||
|
||||
```bash
|
||||
|
||||
Reference in New Issue
Block a user