I have some commands in txt file and I need to execute all them line by line. How could I do it?
Just do bash file:
bash file
$ cat file date echo '12*12' | bc $ bash file Mon Nov 26 15:34:00 GMT 2012 144
In case of aliases just run bash -i file
bash -i file
No need to worry about file extensions or execution rights.
2.1m questions
2.1m answers
60 comments
57.0k users