I am using argparse to pass arguments on the command line, while executing the program. There is one argument that I need to change every time I run the program. I was thinking of storing all the instances of that particular argument in a list and write a program that executes my python program,say test.py
taking one instance of that list every time it runs.
python test.py --arg1 a1 --arg2 a2
List of instances of arg2 : [a2_1,a2_2,a2_3].
I want to automate the process, such that the following gets executed:
python test.py --arg1 a1 --arg2 a2_1
followed by
python test.py --arg1 a1 --arg2 a2_2
then
python test.py --arg1 a1 --arg2 a2_3
automatically and I dont have to pass the next arguments manually every time one gets executed.
Thanks a lot