Why don't *.zip patterns work in tar :tar cfjv backup.tar.bz2 --exclude mydir/files/*.zip mydirIs there another syntax?
tar exclude files *.zip
shell;quoting;wildcards;tar
You will need to quote the exclusion pattern, mydir/files/*.zip, otherwise the shell will expand it (globbing), possibly/probably matching a number of files, and the meaning of you command line will be very different from what you intended.This means changing you original tar command line into$ tar cfjv backup.tar.bz2 --exclude mydir/files/*.zip mydirI initially thought there was something up with the cfjv switches. These are ancient command line switches and tar handles them very differently from more modern command line switches (prefixed by -). That's why you do not get an archive called jv even though that's what's following the f switch.The manual for tar on Mac OS X mentions this under the COMPATIBILITY section:The bundled-arguments format is supported for compatibility with historic implementations.  It consists of an initial word (with no leading - character) in which each character indicates an option.  Arguments follow as separate words.  The order of the arguments must match       the order of the corresponding characters in the bundled command word.       For example,      tar tbf 32 file.tarspecifies three flags t, b, and f.  The b and f flags both require       arguments, so there must be two additional items on the command line.       The 32 is the argument to the b flag, and file.tar is the argument to       the f flag.