3
rated 0 times
[
3]
[
0]
/ answers: 1 / hits: 32125
/ 2 Years ago, sat, september 24, 2022, 3:07:52
i need some help for a very siple script, i don't get were the fault is.
The script :
#!/bin/bash
declare -i s
declare -i m
declare -i h
if [ "$3" < 50 ]; then s=$3+10 m=$2 h=$1
else if ["$2" < 50 ];
then s=$3-50 m=$2+1 h=$1
else s=$1-50 m=$2-50 h=$1+1 fi
fi
echo "$h:$m:$s"
The script add 10sc to the time we've entered.
I get this error message : "sub_change_dirrect: line 14: syntax error: unexpected end of file"
More From » bash