Create Eclipse desktop shortcuts under Ubuntu

Source: Internet
Author: User

1. Terminal code:

Cd/home/xyh/desktop

sudo gedit eclipse.desktop

then type in the file that pops up:


[CPP]View Plaincopyprint?
    1. [Desktopentry]
    2. Encoding=utf-8
    3. Name=eclipse
    4. Comment=eclipse IDE
    5. Exec=/usr/local/eclipse/eclipse_sdk/eclipse
    6. icon=/usr/local/eclipse/eclipse_sdk/icon.xpm
    7. Terminal=false
    8. Startupnotify=true
    9. Type=application
    10. Categories=application;development;


exec=/usr/local/eclipse/eclipse_sdk/Eclipseicon=/usr/local/eclipse/eclipse_sdk/icon.xpm

This place is to be modified for your Eclipse installation directory.

PS: My eclipse is installed (or unzipped) in the/usr/local/eclipse directory

2. Then give the file the right to run the "chmod u+x eclipse.desktop" command.

This eclipse is the decompression installation, if it is installed with the Deb package, you can put/usr/share/applications/under the eclipse.desktop (I have not installed, do not know whether it is the name) files copied to the desktop directory.

3. Direct CP above the code of the friend notice, CP back to edit the note to remove the space behind each line.

There are also two commands, which are related to the desktop icon

desktop-file-install Install icon icon to application directory

desktop-file-validate Verifying the correctness of your desktop icon file

For example, my command can add an Eclipse icon that is already installed on my desktop to the Start menu.

desktop-file-install-- Add-category Development Eclipse.desktop

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.