Ubuntu – Make a desktop shortcut of Chrome Extensions

20.04chrome-extensiondesktopgoogle-chromeshortcuts

There is this particular chat app called Line but it does not provide Linux version. But thankfully the developer made a chrome extension. In the past, extensions were integrated with chrome://apps so it was very easy to add shortcut to desktop. Line also does not provide the web version like WhatsApp or Microsoft Teams so cannot add shortcut directly. Any help would be highly appreciated. Line extension (top right corner) does not show up on chrome app list:

Line extension (top right corner) does not show up on chrome app list

I'm running Chrome 87.0.4280.88 on Ubuntu 20.04.01 64 bit

Best Answer

All you really would have to do is get the Chrome Extension ID of the app and then add it to a .desktop file.

Goto chrome://extensions and that will bring them all up. Look for the app in question:

Details of a Chrome extension called LINE. Its ID is "ophjlpahpchlmihnnnihgmmeilfjmjjc".

Then add that ID with a /index.html at the end of it to the command that Google Chrome will launch. For example, a "Line Chat.desktop" with the following lines:

[Desktop Entry]
Version=1.0
Type=Application
Name=Line Chat
Comment=Line Chat
Exec=google-chrome --app="chrome-extension://ophjlpahpchlmihnnnihgmmeilfjmjjc/index.html"
Icon=
Path=
Terminal=false
StartupNotify=false

You can always find an icon you like and add it to the Icon= line.

The --app=<url> argument tells Chrome to launch in app mode, hiding UI elements. If you want the extension page to open in an ordinary tab, use something like

Exec=google-chrome "chrome-extension://ophjlpahpchlmihnnnihgmmeilfjmjjc/index.html" 

instead.

Hope this helps!