Didn't how to name this thread, but i'm not sure of something (it's has been a long night, so my head ain't so clear
I have a script1.sh (see code below) which calls another script (which is a sort of template -> template.sh). But when i call template.sh i need to send an argument with it.
VAR=`./template.sh -d $dirpath`
if [ $# -lt 1 ]; then
while test -n "$1"; do
case "$1" in
echo "Unknown argument: $1"
statresult=`$find $dirpath -type f | $wc -l |$tail -1`
if [ $dirsize -gt 0 ]; then
VAR=`$find $dirpath -name "*.*" -type f -mmin +60 | $wc -l`
if [ $VAR -gt 0 ]; then
echo "$VAR files which are older than 1 hour in folder $dirpath"
I geuss the command should look like something like this
You don't have to look at the code of template.sh, thats not important. I just need to know how i get this to work
I don't think it's that hard, but i just can't see it ...
Can someone help me please?