{"id":517,"date":"2025-01-12T13:34:56","date_gmt":"2025-01-12T09:34:56","guid":{"rendered":"https:\/\/hostatto.com\/blog\/?p=517"},"modified":"2025-01-12T15:34:09","modified_gmt":"2025-01-12T11:34:09","slug":"make-sublime-text-4-the-default-text-editor-linux","status":"publish","type":"post","link":"https:\/\/hostatto.com\/blog\/make-sublime-text-4-the-default-text-editor-linux.html","title":{"rendered":"How do I make Sublime Text 4 the default text editor"},"content":{"rendered":"<p>After installing Sublime Text 4 , write in the terminal<\/p>\n<blockquote><p>whereis subl<\/p><\/blockquote>\n<p>My result<\/p>\n<blockquote><p>\/usr\/bin\/subl<\/p><\/blockquote>\n<p>Next<\/p>\n<blockquote><p>export EDITOR=\/usr\/bin\/subl<br \/>\nupdate-alternatives --install \/usr\/bin\/editor editor \/usr\/bin\/subl 5\n<\/p><\/blockquote>\n<p>Next<\/p>\n<blockquote><p>select-editor<\/p><\/blockquote>\n<p>Select the desired number and press enter.<\/p>\n<h2>Start Sublime Text4 from the launcher as root<\/h2>\n<p>Enter as a normal user in the terminal<\/p>\n<blockquote><p>sudo subl<\/p><\/blockquote>\n<p>Enter your password<br \/>\nIf you see an error<\/p>\n<blockquote><p>Username is not in the sudoers file. This incident will be reported<\/p><\/blockquote>\n<p>Next, open the file sudoers as root.<br \/>\nSince the sudoers file is read-only even for the root, it must be edited using the command <strong>visudo<\/strong><\/p>\n<blockquote><p>\nvisudo \/etc\/sudoers<\/p><\/blockquote>\n<p>And add this line to it<\/p>\n<blockquote><p>username ALL=(ALL)  ALL<\/p><\/blockquote>\n<p>Where username is your username<\/p>\n","protected":false},"excerpt":{"rendered":"<p>...<\/p>\n","protected":false},"author":1,"featured_media":506,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[25],"tags":[45,63,64],"class_list":["post-517","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-linux","tag-linux","tag-sublime4","tag-text-editor"],"_links":{"self":[{"href":"https:\/\/hostatto.com\/blog\/wp-json\/wp\/v2\/posts\/517","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/hostatto.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/hostatto.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/hostatto.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/hostatto.com\/blog\/wp-json\/wp\/v2\/comments?post=517"}],"version-history":[{"count":0,"href":"https:\/\/hostatto.com\/blog\/wp-json\/wp\/v2\/posts\/517\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/hostatto.com\/blog\/wp-json\/wp\/v2\/media\/506"}],"wp:attachment":[{"href":"https:\/\/hostatto.com\/blog\/wp-json\/wp\/v2\/media?parent=517"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/hostatto.com\/blog\/wp-json\/wp\/v2\/categories?post=517"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/hostatto.com\/blog\/wp-json\/wp\/v2\/tags?post=517"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}