Issue 159833 in chromium: shortcut to app created on desktop won't launch due to mal-formed .desktop file

71 views
Skip to first unread message

chro...@googlecode.com

unread,
Nov 7, 2012, 12:29:36 PM11/7/12
to chromi...@chromium.org
Status: Unconfirmed
Owner: ----
Labels: OS-Linux Area-Undefined Type-Bug Pri-2

New issue 159833 by inetf...@gmail.com: shortcut to app created on desktop
won't launch due to mal-formed .desktop file
http://code.google.com/p/chromium/issues/detail?id=159833

Chrome Version : 23.0.1271.64
Is this the most recent version: yes
OS + version: ubuntu 12.10
CPU architecture (32-bit / 64-bit): 64-bit
Window manager: kwin

What steps will reproduce the problem?
Create a shortcut to app on the "new tab page", by right clicking an
application icon -> create shortcut.


What is the expected result?
a working desktop shortcut to the web app should be generated


What happens instead?
xdg-open won't launch chrome by clicking on the desktop file created by
google chrome

By inspecting the content generated desktop file

There is a newline character missing , as the first line
of the desktop file reads:

#!/usr/bin/env xdg-open[Desktop Entry]

and the desktop file is repaired by supplying the missing character,
manually.

chro...@googlecode.com

unread,
Nov 16, 2012, 4:15:54 PM11/16/12
to chromi...@chromium.org

Comment #1 on issue 159833 by vcos...@gmail.com: shortcut to app created on
desktop won't launch due to mal-formed .desktop file
http://code.google.com/p/chromium/issues/detail?id=159833

Same thing, and strangely it works in Ubuntu 12.04 but not in Ubuntu 12.10

chro...@googlecode.com

unread,
Nov 29, 2012, 3:20:15 PM11/29/12
to chromi...@chromium.org

Comment #2 on issue 159833 by will...@crandell.ws: shortcut to app created
on desktop won't launch due to mal-formed .desktop file
http://code.google.com/p/chromium/issues/detail?id=159833

according to the community docs on unity the structure is not correct
separating the lines does not fix the problem. Though removing the first
part does, which can be done by dragging the broken file onto the system
text editor or by clicking "Open" inside the editor and selecting the
shortcut.

As in this broken desktop shortcut Example:
#!/usr/bin/env xdg-open [Desktop Entry]
Version=1.0
Name=Google Maps
Exec=/opt/google/chrome/google-chrome --app-id=biglongstringofcharacters
--profile-directory=Default
Terminal=false
Icon=chrome-biglongstringofcharacters-Default
Type=Application
Categories=Network;WebBrowser;
StartupWMClass=crx_biglongstringofcharacters

End of broken shortcut File and start of fixed version:
[Desktop Entry]
Version=1.0
Name=Google Maps
Exec=/opt/google/chrome/google-chrome --app-id=biglongstringofcharacters
--profile-directory=Default
Terminal=false
Icon=chrome-biglongstringofcharacters-Default
Type=Application
Categories=Network;WebBrowser;
StartupWMClass=crx_biglongstringofcharacters

referance url:
https://help.ubuntu.com/community/UnityLaunchersAndDesktopFiles

note: this is also how to fix created application shortcuts for the Unity
Launcher which is placed in your home directory under the hidden folder
called local:
/home/username/.local/share/applications/

press ctrl+h to reveal hidden directories

chro...@googlecode.com

unread,
Nov 29, 2012, 5:09:11 PM11/29/12
to chromi...@chromium.org

Comment #3 on issue 159833 by will...@crandell.ws: shortcut to app created
on desktop won't launch due to mal-formed .desktop file
http://code.google.com/p/chromium/issues/detail?id=159833

If you build chrome from source you might try to do this:
Change the following file
http://src.chromium.org/svn/trunk/src/chrome/browser/shell_integration_linux.cc
chromium/src/chrome/browser/shell_integration_linux.cc on line 621

you will find the following
output_buffer += data_dump;

For removing extra code as I stated previously simply comment out the line:
//output_buffer += data_dump;

For adding the new line character I would not do that as noted in the lines
prior to this it states
// Although not required by the spec, Nautilus on Ubuntu Karmic creates
its
// launchers with an xdg-open shebang. Follow that convention.

Well for forward compatibility I say don't "Follow that convention."




chro...@googlecode.com

unread,
Jan 28, 2013, 8:08:04 AM1/28/13
to chromi...@chromium.org

Comment #4 on issue 159833 by ipenov...@brighttalk.com: shortcut to app
created on desktop won't launch due to mal-formed .desktop file
http://code.google.com/p/chromium/issues/detail?id=159833

Confirmed on Ubuntu 12.10 using Chromium 23.0.1271.97 Ubuntu 12.10
(23.0.1271.97-0ubuntu0.12.10.1)

It puts "[Desktop Entry]" on the same line as the shebang "#!/usr/bin/env
xdg-open" when there should be a newline just before the [.

I'm running my system in a fallback session, so I still have the
Applications menu, which fails to pick up the created webapp due to the
malformed shebang. Only after inserting that newline does the shortcut
appear in the menu.


chro...@googlecode.com

unread,
Feb 25, 2013, 12:53:38 AM2/25/13
to chromi...@chromium.org

Comment #6 on issue 159833 by dragonf...@gmail.com: shortcut to app created
on desktop won't launch due to mal-formed .desktop file
http://code.google.com/p/chromium/issues/detail?id=159833

I expereince the exact same issue in chrome 24.0.1312.57

--
You received this message because this project is configured to send all
issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings

chro...@googlecode.com

unread,
Apr 14, 2013, 12:09:55 PM4/14/13
to chromi...@chromium.org

Comment #8 on issue 159833 by asvi...@chromium.org: shortcut to app
created on desktop won't launch due to mal-formed .desktop file
http://code.google.com/p/chromium/issues/detail?id=159833

Issue 181518 has been merged into this issue.

chro...@googlecode.com

unread,
Apr 14, 2013, 12:12:55 PM4/14/13
to chromi...@chromium.org
Updates:
Status: Duplicate
Mergedinto: 169660

Comment #9 on issue 159833 by asvi...@chromium.org: shortcut to app
created on desktop won't launch due to mal-formed .desktop file
http://code.google.com/p/chromium/issues/detail?id=159833

(No comment was entered for this change.)
Reply all
Reply to author
Forward
0 new messages