mount an atproto PDS repository as a FUSE filesystem oppi.li/posts/mounting_the_atmosphere/
103
fork

Configure Feed

Select the types of activity you want to include in your feed.

Use the XDG basedir cache directory for the cache instead of the data directory #1

merged opened by nel.pet targeting main

Currently pdsfs stores its cache in the XDG basedir data directory. However as per spec (https://specifications.freedesktop.org/basedir-spec/latest/) this directory is for essential user specific data. ie. not for caching purposes. XDG basedir defines a seperate cache directory intended for caches that should be used instead.

Labels

None yet.

Participants 2
AT URI
at://did:plc:h5wsnqetncv6lu2weom35lg2/sh.tangled.repo.pull/3lvoqadbjlp22
+1 -1
Diff #0
+1 -1
src/main.rs
··· 113 113 114 114 let dirs = BaseDirectories::new(); 115 115 116 - let dir = dirs.get_data_home().expect("$HOME is absent").join("pdsfs"); 116 + let dir = dirs.get_cache_home().expect("$HOME is absent").join("pdsfs"); 117 117 tokio::fs::create_dir_all(&dir).await?; 118 118 119 119 let file = dir.join(&id.did);

History

1 round 1 comment
sign up or login to add to the discussion
nel.pet submitted #0
1 commit
expand
3e10776b
use cache dir instead of data dir
expand 1 comment

nice thanks!

pull request successfully merged