So I'm trying to execute a command in a bash script multiple times with different but same number of arguments while redirecting the output to a text file. For example ...
./test arg1 arg2 arg3 >> output.txt
This works if I do it at the command line. In a script where I have...
command ./test 10 5 option1 >> output.txt command ./test 5 10 option2 >> output.txt
And run the script, I get
command not found. If I remove the redirect to ouput.txt, the script then works / prints to the terminal window
I tried searching online but I could not find examples where arguments were used which then redirected
Anyone able to help?