public
Last active

Sync SoundCloud.app's playlists over Dropbox.

  • Download Gist
sc_sync.sh
Shell
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40
# Enable SoundCloud.app to sync its playlists over DropBox.
# You'll have to launch it on every computers you want to sync together.
 
# 1. Download the script.
# 2. Edit the SC_DROPBOX_PATH variable if your DropBox folder is not located inside your home folder.
# 3. Lauch Terminal.app.
# 4. Browse to the directory where the script is located: `cd /path/to/folder`
# 5. Make the script executable: `chmod +x sc_sync.sh`
# 6. Launch the script: `./sc_sync.sh`
 
# Edit the variable below if your DropBox folder isn't located inside your home folder.
# Don't forget to escape spaces and remove the trailing slash.
SC_DROPBOX_PATH=~/DropBox/SoundCloud
 
SC_ORIG_PATH=~/Library/Application\ Support/SoundCloud
 
echo "Enabling SoundCloud's playlists sync over DropBox"
echo ""
 
if [ ! -d "$SC_DROPBOX_PATH" ]
then
echo "Directory $SC_DROPBOX_PATH doesn't exists, moving the original directory..."
mv "$SC_ORIG_PATH" "$SC_DROPBOX_PATH"
else
echo "Directory $SC_DROPBOX_PATH already exists, backuping the original directory..."
if [ -d "$SC_ORIG_PATH.bak" ]
then
echo "Removing the old backup..."
rm -rf "$SC_ORIG_PATH.bak"
fi
mv "$SC_ORIG_PATH" "$SC_ORIG_PATH.bak"
fi
 
echo "Creating the symlink from $SC_ORIG_PATH to $SC_DROPBOX_PATH..."
ln -s "$SC_DROPBOX_PATH" "$SC_ORIG_PATH"
 
echo "Done."
echo ""

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.