Re: Cleaning of $XDG_CACHE_HOME and $XDG_CACHE_HOME/thumbnails

Benjamin Berg <[email protected]>
Newsgroups gmane.linux.xdg.devel
Message-ID <[email protected]>
On Wed, 2020-02-26 at 10:58 -0300, Soni L. wrote:
> On 2020-02-26 10:39 a.m., Benjamin Berg wrote:
> > [SNIP]
> > I don't think that $XDG_CACHE_HOME is designed to be used directly by
> > users. And if it is an application which generates those repositories,
> > then again, it can just drop-in the appropriate configuration to
> > prevent cleaning.
> > [SNIP]
> > Am I missing something obvious?
> 
> Oh sorry, I should've been more specific. I use it in the program I make 
> https://ganarchy.autistic.space/project/385e734a52e13949a7a5c71827f6de920dbfea43/
> 
> > > Besides, what if you nuke it *while* the thing is running? That
> > > doesn't sound like a good idea.
> > 
> > This seems like a rather unlikely corner case. In particular as the
> > atime is taken into account by tmpfiles.d. So there should be no need
> > to worry about files being deleted that have been used in the last 30
> > days or so.
> 
> I believe git won't necessarily touch old object files such as those 
> from really old commits, so that might still break stuff. Unless I'm 
> misunderstanding something here and it's meant to be all-or-nothing.

Right, but in your usecase, all you need to do is create a file (at
installation or startup when running from source) in:
  $XDG_CONFIG_DIR/tmpfiles.d/ganarchy.conf
or
  /us/share/user-tmpfiles.d/ganarchy.conf
with the single line
  x %C/ganarchy
or something very similar.

Really, all this does make it explicit that you do not want automatic
cache cleaning for the corresponding directory.

Benjamin

_______________________________________________
xdg mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/xdg
signature.asc (application/pgp-signature, 833 B)
-----BEGIN PGP SIGNATURE-----

iQIzBAABCAAdFiEED2NO4vMS33W8E4AFq6ZWhpmFY3AFAl5Wet4ACgkQq6ZWhpmF
Y3CiIhAAi73wj7K/5Q1aRlnRapt4nXIZggXtZ9ypms4n3Dttka8GQJuryyXYPt7N
guK/xulPtY0Bm/FdNDgybfbUoZ0DjiZayPTfVa23WQygI2+noHioeXeP9osh+RIw
4Ow40tpdDNX+NvGxg2SKPU3XCfjjqBjMPX8nKtMIgCQpEllXuRIKvERuY3hLY9pW
cc4vEPmh9NDBVMYybXJjH4v63pySf6epeTrFgAW8zA6kgUP3O0xk4Z3+U9sEfRMA
FzSejvRPiPZ/LNzt8yt9cR7ysmPFKDTk7bQPjCOaryMiVuIyG6ZG3v48PqsKP7st
Cym6QrfhvGj6dSNAgckWODw24q3Fl9jysnHqQEtQ3dJ85DyD5+tolNdUFbdCAhgK
7m1DXJJ5sOmr+BDemColMFAuYRt+bjmHyCVnlyQrOHXnHjyA3D9/7xRGasGYHkCI
arErRtHDvahviTWkYBFMKcWKuJdxGujHxgB0Il3iH57sJVWn7wNrWcYAGb+SVlW7
BbGD0btn1Fn0fmp26xCY47tob4jbugFbSCs6lASNFp6xOE7kIdmV73szZSlrvDxJ
ZhGrqyKXV2TrRucpPiO/Jp2HYojZ00MEssm/W5RPiynk5kuqbbVE1itKIesO1vTh
HFAVlAPeL7LtcBQSXpeO78oFqvv2Rwe1HPgHPh+xef/KjdeMXfw=
=vNU1
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.