Pick default device for Pulseaudio for Telegram’s desktop client.

Currently (April 2018) the Telegram Desktop Client only seems to use the default sound device. Perhaps a bug.

Anyway, I had no default device but Telegram picked the wrong one nevertheless, and I could not change that in pavucontrol, nor could I set a default device there (the relevant button seems to be stuck on Set as fallback no option for default).

What worked for me:

  1. find the device to make the default (you can use other filters in the second grep of course):

    pactl list | grep alsa_output | grep -i head

  2. use your own device with the following command:

    echo "set-default-sink alsa_output.Headset" | pacmd

  3. end with:

    pulseaudio --kill ; pulseaudio --start

Most of it from this page.

Edit: the above is not permanent. How to do that is perhaps somewhere in the following text: