Search Results

Search: Posts Made By: Arpitmitm
3,167
Posted By Arpitmitm
validation against special char
Hi ,
Please try below

OPTARG=$1
echo $OPTARG
len="`echo ${#OPTARG}`"
echo $len
cnt=1
while [ $cnt -le $len ]
do
c=$(echo "$OPTARG"|cut -c$cnt-$cnt)
if [[ $c = "-" ]]
then...
Showing results 1 to 1 of 1

 
All times are GMT -4. The time now is 05:44 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy