Skip to content

Open Spotify links in konqueror

December 28, 2009
tags: ,

Just a brief post to explain how you can open spotify links in konqueror. This is not my “invention”, but now I cannot find the source. Hence writing the howto here for me and potentially others that are interested in the info. I found the following recipe in Finnish, but I am quite sure I read an English one when I did this the first time.

First you need a short script. I call it “spotify_openurl.sh”. It should contain the following two lines:

#!/bin/bash
wine "$HOME/.wine/drive_c/Program Files/Spotify/spotify.exe" /uri "$1"

Give it executable (chmod +x ‘scriptname’) and put this somewhere in your $PATH, like e.g. /usr/bin/

Then you create the file ~/.kde/share/kde4/services/spotify.protocol with the following content:

[Protocol]
exec=/usr/bin/spotify_openurl.sh "%u"
protocol=spotify
input=none
output=none
helper=true
listing=false
reading=false
writing=false
makedir=false
deleting=false

After this, clicking on a spotify: link in a KDE program will open the link in spotify.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: