Overblog
Editer l'article Suivre ce blog Administration + Créer mon blog
The French Press

Practical science and engineering projects

Multiple Skype account on Ubuntu

That post is a bit of a tip more than anything else but since the problem is a common one and it has a very nice solution on Ubuntu, I decided to share it before I forget.

So the initial problem is : How do I manage several Skype account on one machine ?

Quite surprisingly, Skype does not offer an easy answer to that relatively common problem. I have myself a private and a professional Skype account and I wanted to have them both active at the same time on my machine and that's without tedious account change and without losing any of the history.

Multiple instances with their own context

On Linux, there is a surprisingly simple way to have any number of Skype instances running concurrently with their own context. In order to be able to do that, you need to create their own account folder to store the context into and point the instance at it.

Practically, it is as simple as opening a command line terminal and typing the following :

cd ~
mkdir .SkypePro
skype --dbpath=~/.SkypePro

There I have created a hidden directory under my home directory and asked Skype to store its data there. On the first run, it will ask the login and password that you can ask to remember and any future instance pointed at that directory will find all its history and data there.

That's the technical aspect but it's still more geeky than one might wish and I'd really like to have that running from the Unity application launcher menu. So here is the trick to achieve that.

Unity application launcher

For typical applications, Unity's launcher uses a configuration file from /usr/share/applications which contains all the configuration for that application to be started (icon, options, menus, etc...). There is a launcher file for Skype in that directory and we will use it as a base to customize it to our needs.

The user specific launchers are placed in ~/.local/share/applications so let's copy our file there :

cp /usr/share/applications/skype.desktop ~/.local/share/applications

Once you have your own copy, you can edit it to add the possibility to run different instances. The skype.desktop file was looking like that on my machine :

[Desktop Entry]
Name=Skype
Comment=Skype Internet Telephony
Exec=env PULSE_LATENCY_MSEC=60 skype %U
Icon=skype.png
Terminal=false
Type=Application
Encoding=UTF-8
Categories=Network;Application;
MimeType=x-scheme-handler/skype;
X-KDE-Protocols=skype

I did not change any of the existing configuration (I might have broken something...) but what I did was to create two entries in the contextual menu (that's when you right click on the icon to get more options). So the file ended up looking like that :

[Desktop Entry]
Name=Skype
Comment=Skype Internet Telephony
Exec=env PULSE_LATENCY_MSEC=60 skype %U
Icon=skype.png
Terminal=false
Type=Application
Encoding=UTF-8
Categories=Network;Application;
MimeType=x-scheme-handler/skype;
X-KDE-Protocols=skype
Actions=Private;Pro;

[Desktop Action Private]
Name=Skype privé
Exec=skype

[Desktop Action Pro]
Name=Skype professionnel
Exec=skype --dbpath=~/.SkypePro

At that point, you can see that the 2 entries are launching Skype using either the default .Skype folder or the newly created .SkypePro folder.

Now you only have to restart Unity (or log out and in again) for the icon to appear in the launcher bar. Right click on that icon and you'll see the two entries for each account.

 

You can then launch one or the other or both at the same time without interference.

 

Partager cet article
Repost0
Pour être informé des derniers articles, inscrivez vous :
Commenter cet article