0

I am aware that Spotify downloads songs and keeps them on my hard disk rather than keep re-streaming them. However, my Spotify cache is now up to 11gb and I’d like to use crontab to delete it.

I found this post here from 2018: Why is the Spotify cache so large? and used the commands within in crontab to schedule it to delete but it no longer works.

Has something changed since this original post meaning I need to use a different command in macOS Catalina?

Giacomo1968
  • 58,727

1 Answers1

0

On MmacOS Catalina the com.spotify.client cache folder lives in ~/Library/Caches:

$ ls -lah ~/Library/Caches | grep com.spotify
drwx------    8 sl  staff   256B Jul 17 17:04 com.spotify.client
drwxr-xr-x    5 sl  staff   160B Mar 23 09:50 com.spotify.client.helper
drwxr-xr-x    5 sl  staff   160B Mar  6 19:24 com.spotify.installer

As you already saw, the com.spotify.client folder has read, write and execute permissions for the owner of the file (in this case sl). Users in the group (in this case staff) and other users have no permissions.

As you are (most likely) the owner of that folder you should be able to delete it.

To delete that folder once you would write in terminal:

rm -r ~/Library/Caches/com.spotify.client 

The -r flag recurses through the directory and is needed to delete folders.

If you want to run this command periodically you can refer to earlier questions on that subject.

Giacomo1968
  • 58,727