Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change cache storage location #464

Open
ghost opened this issue Mar 25, 2020 · 12 comments
Open

Change cache storage location #464

ghost opened this issue Mar 25, 2020 · 12 comments
Labels
enhancement New feature or request Rewrite: featurerequest A feature request that is still valid for the rewrite

Comments

@ghost
Copy link

ghost commented Mar 25, 2020

Is there an ability to change the cache storage location? It currently saves data to the AppData folder, but the hard drive for this is quite small and I would like to minimize unnecessary data storage on this drive.

@AE720
Copy link

AE720 commented Apr 4, 2020

A workaround for when and if they implement that option is to make a symbolic link if you're using windows. You can paste the path you want in quotes and change USERNAME to your actual username and then run it in CMD

mklink /d "Path to desired folder" "C:\Users\USERNAME\AppData\Roaming\FreeTube\Cache"

@Atrate
Copy link
Contributor

Atrate commented Apr 16, 2020

I would ask for the same to be possible to be done for Linux. ~/.cache is there for a reason.

@GilgusMaximus GilgusMaximus added the Rewrite: featurerequest A feature request that is still valid for the rewrite label Oct 1, 2020
@sundaran1122
Copy link

I think you can do the same thing as windows.

ln -sf ~/.cache/FreeTube ~/.config/FreeTube

@efb4f5ff-1298-471a-8973-3d47447115dc

Closing in favor of #6454

@Atrate
Copy link
Contributor

Atrate commented Dec 26, 2024

@efb4f5ff-1298-471a-8973-3d47447115dc #6454 was closed as wontfix, I don't think this issue should be closed. I don't see any reason why the default should not be stored properly, according to XDG standards.

@AE720
Copy link

AE720 commented Dec 26, 2024

Yeah, that's kind of lazy, especially considering how trivial it would be to implement. This is the only software I have to do anything hacky for. I've never seen a program that didn't let me change the cache, stremio, google drive, etc

@absidue
Copy link
Member

absidue commented Dec 26, 2024

@AE720 If you can figure out a way to get Chromium to write only it's own cache files to a different directory without having to patch and recompile Chromium, otherwise it is far from trivial.

@absidue absidue reopened this Dec 26, 2024
@github-project-automation github-project-automation bot moved this from Good For New Contributors to To assign in Feature Requests Dec 26, 2024
@absidue
Copy link
Member

absidue commented Dec 26, 2024

Reopening but will close as not feasible in 2 weeks time if someone doesn't provide an answer to the question above in that time.

@Atrate
Copy link
Contributor

Atrate commented Dec 26, 2024

I see that Electron devs are quite unresponsive about the issue, despite wide community support for that feature (electron/electron#8124). That sucks. Maybe FreeTube could implement a workaround given that it is a bit of a special case (hundreds of megabytes being written every hour or so, with videos being played).

@absidue
Copy link
Member

absidue commented Dec 26, 2024

@Atrate If the amount of writes are your concern, you can turn on the setting in the experimental settings section which disables Electron's network disk cache. It is still considered experimental as our custom image cache uses a lot more RAM and occasionally results in images not showing up, additionally as expected the lack of caching also means that it has to make more requests to YouTube and Invidious.

@Tharn
Copy link

Tharn commented Feb 4, 2025

There are the command line flags for Chromium, --disk-cache-dir. It's actually possible to disable the Cache in Chromium if you set this to A:\ or another nonexistant drive. This is how I used to disable Chromium Cache, as that browser is a notorious glutton with disk writes. There is also --disk-cache-size.

https://peter.sh/experiments/chromium-command-line-switches/

More hacks: It is possible to symlink to NUL

None of these options are clean. Chromium just isn't good for customization. If we could get some Cache controls, that would be awesome.

@absidue
Copy link
Member

absidue commented Feb 4, 2025

If we could get some Cache controls, that would be awesome.

@Tharn The only controls are the command line flags that you mentioned.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request Rewrite: featurerequest A feature request that is still valid for the rewrite
Projects
Status: To assign
Development

No branches or pull requests

7 participants