public inbox for gentoo-user@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-user] tar exclude files question
@ 2023-09-05 15:28 Walter Dnes
  2023-09-05 18:36 ` Alan McKinnon
  2023-09-05 18:38 ` Michael
  0 siblings, 2 replies; 9+ messages in thread
From: Walter Dnes @ 2023-09-05 15:28 UTC (permalink / raw
  To: Gentoo Users List

  Every so often I tar up my home directory on my main machine, and push
it over to my "hot backup" machine, and then do a tap-dance with the
.ssh directory.  I notice oodles of cache files being tarred.  Do I
understand the man page correctly about the CACHEDIR.TAG "magic file"?
Assume I have a .cache directory like so...

[x8940][waltdnes][~] ll .cache
total 64
drwx------  12 waltdnes users  4096 Sep  5 10:50  .
drwxr-xr-x 141 waltdnes users 20480 Sep  5 10:58  ..
-rw-r--r--   1 waltdnes users     0 Sep  5 10:50  CACHEDIR.TAG
drwx------   2 waltdnes users  4096 Aug 29 15:34  babl
drwxr-xr-x   2 waltdnes users  4096 Sep  5 08:52  fontconfig
drwxr-xr-x   3 waltdnes users  4096 Jun 11  2021  geeqie
drwx------   3 waltdnes users  4096 May 29  2021  gegl-0.4
drwxr-xr-x   3 waltdnes users  4096 May 29  2021  gimp
drwx------   3 waltdnes users  4096 May 27  2021  google-chrome
drwx------   2 waltdnes users  4096 Sep  5 10:23  mc
drwxr-xr-x 258 waltdnes users  4096 Mar 24  2022  mesa_shader_cache
drwx------   3 waltdnes users  4096 May 25  2021 'moonchild productions'
drwx------   3 waltdnes users  4096 Nov 16  2021  thumbnails

  Would a script in /home like...

#!/bin/bash
tar --exclude-caches-under cvzf wdexport.tgz waltdnes

...skip files in that directory?  I don't mind a few empty directories.

-- 
I've seen things, you people wouldn't believe; Gopher, Netscape with
frames, the first Browser Wars.  Searching for pages with AltaVista,
pop-up windows self-replicating, trying to uninstall RealPlayer.  All
those moments, will be lost in time like tears in rain... time to die.


^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2023-09-06 15:44 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-09-05 15:28 [gentoo-user] tar exclude files question Walter Dnes
2023-09-05 18:36 ` Alan McKinnon
2023-09-05 23:10   ` Walter Dnes
2023-09-06  9:57     ` Michael
2023-09-05 18:38 ` Michael
2023-09-05 20:28   ` Dale
2023-09-05 22:32   ` Walter Dnes
2023-09-06  9:48     ` Michael
2023-09-06 15:44       ` Walter Dnes

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox