Dup Ver Goto 📝

Open Sites Like Whatsapp As Chrome Apps

PT2/linux/xdg web chrome does not exist
To
20 lines, 94 words, 780 chars Page 'OpenWhatsappWeb' does not exist.

There is actually a nice general method:

google-chrome --app=https://web.whatsapp.com/

and this works for any website. So for example

google-chrome --app=https://pt2.allsup.co/linux/xdg/OpenWhatsappWeb

will open this page as an app. Note that such apps do not get a URL bar.

Then you can (thanks to gist linked below) use wmctrl to activate a Whatsapp window and only fail over to launching a new one if there isn't one:

wmctrl -xa web.whatsapp.com || /opt/google/chrome/google-chrome --app=https://web.whatsapp.com/
# or
bash -c "wmctrl -xa web.whatsapp.com || /opt/google/chrome/google-chrome --app=https://web.whatsapp.com/"

Linux .desktop file

From this gist