I want to extract only a specific file type using unrar.
With unzip command I can extract all archives with a specific extension.
unzip "$FileName" *[.txt,.TXT]
How can I do the same with unrar? Do I need to iterate through every file?
unrar x "$FileName" \*.txt \*.TXT
In bash you can also use:
unrar x "$FileName" \*.{txt,TXT}
Bash transforms this to the former form.
unrar "$FileName" '*.txt'