Answers for "how to compare strings in zsh script"

0

how to compare strings in zsh script

#!/bin/sh

argn=$#
i=0

for arg do
   shift
   i=$(( i + 1 ))

   if [ "$i" -lt "$argn" ]; then
       set -- "$@" ssh -t "$arg"
   else
       set -- "$@" "/pathtofile/$arg/log.log"
   fi
done

command "$@"
Posted by: Guest on January-03-2021

Code answers related to "how to compare strings in zsh script"

Code answers related to "Shell/Bash"

Browse Popular Code Answers by Language