question about tar -N
mail at tpesonen.net
Sat Aug 20 17:14:40 UTC 2011
On Sat, 2011-08-20 at 17:42 +0100, R Kimber wrote:
> I'm puzzled by how tar -N option works.
> I tried many date formats and eventually found one that tar seemed happy
> with, yet it didn't just archive the files that were newer than the
> given date but also included some older files. I've tried -N, --newer, and
> --after-date. The man page says that you can use a date or a
> filename, and I have tried both.
> I'm trying to set up a system for archiving *.flac and other music files.
> When I run tar with a date option or a filename it seems to ignore *.jpg and
> *.pdf files that are older than the given date (as expected) but it
> includes some flac files in the tarball even though they are older than the
> Is there another version of tar, other than that included with Ubuntu, that
> does work, or am I trying to use it incorrectly?
Someone else may be able to help you with the -N switch, but as to are
there other options, I started at some point using bsdtar in place of
tar as it automatically recognized the compression format used when
extracting. That was useful for me at the time. TAR may do that as well
nowadays. But I suggest you give bsdtar a go. The --newer and
--newer-mtime (and --newer-than file and --newer-mtime-than file)
switches should work as advertised based on my experience.
More information about the ubuntu-users