I got a script that asks 1000 times for input of 1-5, it looks like this:
insert1:
insert2:
insert3:
insert4:
insert5: //and again 1-5
insert 1: ...in total it will get 1000 inputs
I want to write a one line script that will run the script I just described, it will insert the input that needed each time. this is what I tried:
#!/bin/bash
./my_script.exe -l | for i in {1..200}; do for j in {1..5}; do j; done; done
jjust runs the commandj, it doesn't have anything to do with the contents of the variable expanded with$j).