What's new

Tutorial How do i make sublime text 3 the default text editor on ubuntu 14.04

Status
Not open for further replies.

Draft

Administrator
Administrator
Joined
Jan 23, 2011
Posts
16,287
Solutions
104
Reaction
64,689
Points
10,618
download.png


First, make sure that /usr/share/applications/sublime_text.desktop exists:
ls /usr/share/applications/sublime_text.desktop

Then, open /usr/share/applications/defaults.list with Sublime:
Code:
sudo subl /usr/share/applications/defaults.list

Search for all instances of gedit and replace them with sublime_text.
Save the file, log out and back in, and you should be all set.

If for some reason /usr/share/applications/sublime_text.desktop doesn't exist, create it:
sudo touch /usr/share/applications/sublime_text.desktop

Open it in Sublime:
sudo subl /usr/share/applications/sublime_text.desktop
and paste the following into it:
Code:
[Desktop Entry]
Version=1.0
Type=Application
Name=Sublime Text
GenericName=Text Editor
Comment=Sophisticated text editor for code, markup and prose
Exec=/opt/sublime_text/sublime_text %F
Terminal=false
MimeType=text/plain;
Icon=sublime-text
Categories=TextEditor;Development;
StartupNotify=true
Actions=Window;Document;

[Desktop Action Window]
Name=New Window
Exec=/opt/sublime_text/sublime_text -n
OnlyShowIn=Unity;

[Desktop Action Document]
Name=New File
Exec=/opt/sublime_text/sublime_text --command new_file
OnlyShowIn=Unity;

However, if you installed Sublime Text using the .deb file downloaded from sublimetext.com, the file should already exist.
 

Attachments

Baka naman old version nagamit mung Ubuntu?
14.04 Unity po ang latest default ng Ubuntu ngayun.
Next Month may 14.10 nadin :)
 
Di naman kaylangan ang programming background sa pag gamit ng Ubuntu ;)
 
Hehe, basta marunong lang magbasa ay magagamit muna mabuti ang Ubuntu :)
 
Normal lang na di talaga gagana lahat ng apps sa Windows, I mean para sa windows ay pang Windows lang talaga.
But usually may equivalent application naman para sa Ubuntu.
 
View attachment 20473

First, make sure that /usr/share/applications/sublime_text.desktop exists:


Then, open /usr/share/applications/defaults.list with Sublime:
Code:
sudo subl /usr/share/applications/defaults.list

Search for all instances of gedit and replace them with sublime_text.
Save the file, log out and back in, and you should be all set.

If for some reason /usr/share/applications/sublime_text.desktop doesn't exist, create it:


Open it in Sublime:

and paste the following into it:
Code:
[Desktop Entry]
Version=1.0
Type=Application
Name=Sublime Text
GenericName=Text Editor
Comment=Sophisticated text editor for code, markup and prose
Exec=/opt/sublime_text/sublime_text %F
Terminal=false
MimeType=text/plain;
Icon=sublime-text
Categories=TextEditor;Development;
StartupNotify=true
Actions=Window;Document;

[Desktop Action Window]
Name=New Window
Exec=/opt/sublime_text/sublime_text -n
OnlyShowIn=Unity;

[Desktop Action Document]
Name=New File
Exec=/opt/sublime_text/sublime_text --command new_file
OnlyShowIn=Unity;

However, if you installed Sublime Text using the .deb file dôwnlôaded from sublimetext.com, the file should already exist.
good pm po sir kay nyu po ang modem ng unidentified network? pag change mac ko kasi ngbrown out s amin dpa ntapos pagchange, plug in type lng kasi laptop ko e./ sana po matulongan nyu ako. salamat po!
 
Status
Not open for further replies.

Similar threads

Back
Top