Using multiple files in a loop in bash shell
Greetings!
I have files with multiple extension in a folder like .txt, .update, .text. The file names are like out1.txt, out1.text, out1.update, out2.txt, out2.text, out2.update and so on....My command looks like this: Code:
./script.pl out1.txt out1.text out1.update Code:
for i in *.{txt,text,update} Thanks in advance! |
Quote:
Code:
for i in {txt,text,update} Is that what you wanted? |
Quote:
If you do separate out everything after the final dot in the file name using only in bash, ksh, or zsh: Code:
for i in *.txt; do |
Thank you for the help.
I did something like this and it worked: Quote:
|
All times are GMT -5. The time now is 09:02 PM. |