i trying to write a bash script to get output 'pkg vim, size small, size medium, size large' which will be passed as argument to another command.
arr_size=(small medium large)
arr_pkg=(vim)
for j in "${arr_pkg[@]}"
do
echo -n pkg "$j"
done
for i in "${arr_size[@]}"
do
echo -n , size $i
done
executing the script gives output as pkg vim, size small, size medium, size large
i need some suggestion on how to pass this output to another command or variable so i can be used as argument for another command.
final command will be as shown below.
grun --file 123.txt --tt='pkg vim, size small, size medium, size large'
Any other suggestion will also be helpful