Little explanation necessary: why the hell does this doesn't work?
#!/bin/bash
ker=$1
if [ "$ker" != "iso" ] || [ "$ker" != "om" ] || [ "$ker" != "constbeta" ] ; then
printf " allowed kernels: iso, om, constbeta \n"
exit
fi
wait
echo 'anisotropy kernel: ', "$ker"
I have also tried
#!/bin/bash
ker="$1"
if [ $ker != "iso" ] || [ $ker != "om" ] || [ $ker != "constbeta" ] ; then
printf " allowed kernels: iso, om, constbeta \n"
exit
fi
wait
echo 'anisotropy kernel: ', "$ker"
I call it like this: $ ./script.sh iso
and I've even tried like this (though I think this doesn't make sense with the
scripts above): $ ./script.sh "iso"
I always get allowed kernels: iso, om, constbeta
Many thanks to those who can spot the error.