Spotify updates itself fairly regularly, so you may need to reapply this fix from time to time.
#!/usr/bin/python
target = "/Applications/Spotify.app/Contents/MacOS/Spotify"
with open(target) as infile:
bytes = infile.read()
with open("./Spotify", "wb") as backup:
backup.write(bytes)
fixed = bytes.replace("VACUUM;", "xxxxxx;")
with open (target, "wb") as outfile:
outfile.write(fixed)Thanks logicallee! I definitely need to be more judicious about time management, so I appreciated your comment!
Just because something could be fun to do if you didn't have anythign else to do and were bored out of your mind, doesn't mean it's worth doing, ever.
That's how I took it.
Also, since you are on a Mac, I would use launchd jobs and make it less brute-force by scheduling the job changing the file on writes to the Applications/Spotify.app/Contents/MacOS/ directory.
$ cat /usr/local/bin/spotify-turn-off-vacuum
#!/usr/bin/env python2
target = "/usr/bin/spotify"
with open(target) as infile:
bytes = infile.read()
with open(target+".bak", "wb") as backup:
backup.write(bytes)
fixed = bytes.replace("VACUUM;", "xxxxxx;")
with open (target, "wb") as outfile:
outfile.write(fixed)
$ cat /etc/apt/apt.conf.d/99spotify-turn-off-vacuum
DPkg::Post-Invoke {"/usr/local/bin/spotify-turn-off-vacuum";};