06-08-20121
This commit is contained in:
@@ -100,6 +100,16 @@ if [ -d directory ]; then
|
||||
if [ -d ~/.kde ]; then
|
||||
```
|
||||
|
||||
Si le répertoire *<u>directory</u>* existe ET n'est <u>pas vide</u>
|
||||
|
||||
```bash
|
||||
local_path=$HOME/Sites/
|
||||
|
||||
if find "$local_path/node_modules" -mindepth 1 -maxdepth 1 | read; then echo "dir not empty"; else echo "dir empty"; fi
|
||||
|
||||
if [ -d "$local_path/node_modules" ] && [ -n "$(ls -A "$local_path/node_modules")" ]; then echo "dir not empty"; else echo "dir empty"; fi
|
||||
```
|
||||
|
||||
Si le fichier *<u>regularfile</u> (ni un blockspecialfile, ni un characterspecialfile, ni un directory)* existe
|
||||
|
||||
```bash
|
||||
|
||||
Reference in New Issue
Block a user