Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I tried 2 types of links and it still I cant add it! I use the unregistered 64 version. On Ubuntu forums and external site

Why is it not coming in the dash board. What is wrong? I even restarted the system to check if it came after the restart after the .desktop file. While the solution listed on the ubuntu forum asks to enter "main menu", there is no match in mine.

share|improve this question
    
you are referring to dash, not launcher, right? –  Anwar Shah Oct 4 '12 at 15:16
    
the left side icons. –  footy Oct 4 '12 at 15:18
add comment

4 Answers

up vote 5 down vote accepted
  1. Open Terminal and write this command

    sudo sublime /usr/share/applications/sublime.desktop

    This will create a file name sublime.desktop in the user/share/applications/ folder and open it for you.

  2. Copy paste the following content in it and save the file

    [Desktop Entry]
    Version=1.0
    Name=Sublime Text 2
    *#Only KDE 4 seems to use GenericName, so we reuse the KDE strings.*
    *#From Ubuntu's language-pack-kde-XX-base packages, version 9.04-20090413.*
    GenericName=Text Editor 
    Exec=sublime
    Terminal=false
    Icon=/usr/lib/Sublime Text 2/Icon/48x48/sublime_text.png
    Type=Application
    Categories=TextEditor;IDE;Development
    X-Ayatana-Desktop-Shortcuts=NewWindow
    [NewWindow Shortcut Group]
    Name=New Window
    Exec=sublime -n
    TargetEnvironment=Unity
    
  3. You will see the Sublime-Text icon in the dash-board. right click the icon and click

    Lock in Launcher

share|improve this answer
    
This is exactly a copy-paste of the "external link" I have provided in the question! I have already said it doesnt work. –  footy Oct 24 '12 at 2:45
    
It worked for me. –  Aziz Ali Mar 5 '13 at 21:46
    
This does not work for a portable archive downloaded from sublimetext.com, replaced "sublime" command with a full path to "sublime_text" executable, but it doesn't work. I have it in the dashboard, but clicking the icon does not run the editor. Not sure if this works at all. Using Ubuntu 12.04 LTS 64-bit. –  Czarek Tomczak May 29 '13 at 10:36
    
UPDATE: it works but you need to rename the "Sublime Text 2" directory to "SublimeText2" so that it doesn't contain spaces. –  Czarek Tomczak May 29 '13 at 10:43
    
I also had to remove those * characters before the comment lines. –  Ajedi32 Jun 12 '13 at 15:06
show 1 more comment

I'll start by assuming your problem is that Sublime Text 2 does not appear when you search for it in the Dash.

After creating a launcher as specified in the second link you posted, search for the launcher using the Dash. You should then be able to pin the app to the launcher once it starts up.

You want to search for "sublime" not "main menu." Not sure how GNOME Shell works, but there is no main menu in Unity.

In the event that Sublime does show up when searching, and your problem is just the pinning, you should be able to pin to the launcher by simply dragging the .desktop file you created to the launcher.

share|improve this answer
add comment

This is the simplest way to add Sublime Text 2 to the Unity launcher. Open a terminal and type:

gnome-desktop-item-edit ~/.local/share/applications/ --create-new

Fill out the fields in the form and click OK. You can now find Sublime Text 2 in all the same locations as the other installed applications on your computer. When you launch Sublime Text 2, right click its icon and "Lock To Launcher".


Note: The application shortcut will only be visible for your current user. If this unacceptable, change ~/.local/share/applications/ to /usr/share/applications/ and add sudo to the start of the command.

share|improve this answer
add comment

I think you have just downloaded Sublime Text 2 and have not installed it. Please follow this guide to install Sublime Text 2 on Ubuntu appropriately.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.