Still stuck!
If I use this
Code:
tar -zcvf "$al".tar.gz "$al"
I get the correctly named tar.gz file in the correct location...but when untar'ed it contains the folders and absolute path to the file
If I use this
Code:
tar -zcvf "$al".tar.gz "$(basename "$al")"
I get "Cannot stat: No such file or directory"
I don't understand how to point to just the folder which is "$(basename "$al")" and still include the full path as in the variable $al