I'm on Ubuntu server 18.04.
My main goal is to run a script from a parent directory which unrars all the files inside all sub directories of the parent directory.
I have also installed apt install unrar
and it is located at "/usr/bin/unrar".
This is what I have come up with till now. But it does not seem to work:
for dir in 'pwd/*/'
do
dir=${dir%*/}
cd dir
for file in dir/*/
do
"/usr/bin/unrar" x dir/*.r* dir/
done
I've found a working script for Windows which uses 7zip here