mirror of
https://github.com/onceupon/Bash-Oneliner.git
synced 2024-11-25 22:07:01 +00:00
add if loop
This commit is contained in:
parent
934f793da8
commit
89c34e4347
@ -899,6 +899,10 @@ else
|
|||||||
echo >&2 "Fatal error. This script requires mydir."
|
echo >&2 "Fatal error. This script requires mydir."
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# if variable is null
|
||||||
|
if [ ! -s "myvariable" ]
|
||||||
|
#True of the length if "STRING" is zero.
|
||||||
|
|
||||||
# Test if file exist
|
# Test if file exist
|
||||||
if [ -e 'filename' ]
|
if [ -e 'filename' ]
|
||||||
then
|
then
|
||||||
|
Loading…
Reference in New Issue
Block a user