i want to make a bash script that can be executed by many people simultaneously. do you have any idea to make it?
there will be many dependent-variables(which is input from people) in the scripts.
i am thinking about a random temporary file that created by the bash script each time someone executed it(the bash script), so when 8 people executing the bash script there will be 8 different temporary files.
i just don't know where to start...
You don't need to use temporary files - just store the values in variables inside the script and process them accordingly. Each different person running the script will be executing a seperate instance of the script so the variables only have scope within that instance.
If you want to use temporary files and need unique filenames for each script invocation, use $$ when you create the file, e.g.
Wouldnt it better off using $USER instead of $$. I have had an instance where $$ was being used. And no matter how rare it could be, $$ did overlap once.