Jump to content

Hi. Doing the linux101 course on the linux foundation website (recently switched from Win10 to Nobara) and they brought up proficiency with a text editor, particularly vi and emacs. I would like to learn both (at least as much as I might be able to handle) but don't know which to start with. I've seen a lot of praise for vi, though, and apparently it's got a lot more users. Anyways, just asking for a recommendation on which to check out first and try to learn. Thanks!

Link to comment
https://linustechtips.com/topic/1592240-vi-vs-emacs/
Share on other sites

Link to post
Share on other sites

Do you often work in an environment where you have no graphical interface (e.g. to manage a server over SSH)? Because if not, then just use a modern GUI based text editor, like VS code. Even if you work in a server environment, for any non-trivial changes it's usually easier to pull the file over sftp, edit it locally, then push it back.

 

Otherwise, nano is likely the simplest option for a console only text editor, though personally I'm more used to vi (or rather vim). Haven't used emacs.

 

// note: https://en.wikipedia.org/wiki/Editor_war

Remember to either quote or @mention others, so they are notified of your reply

Link to comment
https://linustechtips.com/topic/1592240-vi-vs-emacs/#findComment-16596112
Share on other sites

Link to post
Share on other sites

8 minutes ago, Eigenvektor said:

Do you often work in an environment where you have no graphical interface (e.g. to manage a server over SSH)? Because if not, then just use a modern GUI based text editor, like VS code. Even if you work in a server environment, for any non-trivial changes it's usually easier to pull the file over sftp, edit it locally, then push it back.

 

Otherwise, nano is likely the simplest option for a console only text editor, though personally I'm more used to vi (or rather vim). Haven't used emacs.

 

// note: https://en.wikipedia.org/wiki/Editor_war

This is really a lot more of just kind of a hobby so I could probably just use VScode (I use Sublime Text rn) but I do think it would be nice to at least learn the basics. + they do look kinda nice.

Link to comment
https://linustechtips.com/topic/1592240-vi-vs-emacs/#findComment-16596115
Share on other sites

Link to post
Share on other sites

They're both awful. Vim is an antique monstrosity that requires you to remember how the keyboard on a 1970s dumb terminal was laid out. Emacs is what happens when a text editor follows its grandiose dreams of being an operating system when it grows up.

 

If I'm editing text without a GUI, and it's not a DOS curiosity, it's probably just a couple changes to a config file. That's what nano is for: get in, change a couple lines, save, and get out. If there's no nano for some reason, I'll FTP the file to my local machine and do the edit in a tool that's younger than I am. Easy peasy.

I sold my soul for ProSupport.

Link to comment
https://linustechtips.com/topic/1592240-vi-vs-emacs/#findComment-16596119
Share on other sites

Link to post
Share on other sites

2 minutes ago, Needfuldoer said:

Vim is an antique monstrosity that requires you to remember how the keyboard on a 1970s dumb terminal was laid out.

I think you mean vi. vim allows the use of arrow keys, so it's more convenient than vi in that regard.

 

It probably doesn't hurt to learn the basics of vi or vim (at the very least how to close it 😉), because it might be the only thing available in some environments.

 

Emacs might be more powerful/customizable, but I've never enountered it in the wild. Unless you need that kind of customization, I don't see the need to mess with it.

Remember to either quote or @mention others, so they are notified of your reply

Link to comment
https://linustechtips.com/topic/1592240-vi-vs-emacs/#findComment-16596123
Share on other sites

Link to post
Share on other sites

Personally, I suggest learning Vi basics, even if just for the experience. Basics are easy to learn with the build-in tutor. The unique editing philosophy will not necessarily make you edit super fast, but you will definitely feel like you do.

 

You should try Vim (an "improved" Vi) - it is preinstalled on many (or most) big Linux distros and macOS, along the regular Vi, and provides more functionality than Vi. Also, Vi control scheme (bindings) is available in other software, including Emacs, VSCode, XCode etc (natively or with plugins).

 

Emacs is its own world that you never leave, not just a text editor - check it out if you have plenty of time:) During my limited interaction, it felt like "you either in or out, no in-between", if it makes any sense - basically a commitment to its ecosystem.

Link to comment
https://linustechtips.com/topic/1592240-vi-vs-emacs/#findComment-16596241
Share on other sites

Link to post
Share on other sites

14 hours ago, Eigenvektor said:

Do you often work in an environment where you have no graphical interface (e.g. to manage a server over SSH)? Because if not, then just use a modern GUI based text editor, like VS code.

Well, there are advantages to using something like vim for text editing even if you have access to a gui. VScode has plugins to emulate vim editing but it's not a very seamless experience.

 

@okkee I don't have much experience with emacs so I can't tell you much about it, however having used vim quite a bit I think it's worth at least trying for a little while. Even if you don't end up using it often it can give you a wider perspective on what text editing can look like - and you might end up missing some of its features when using other editors. It's designed to be used without ever lifting your hands from the typing position and even without any plugins it offers some features that can save you a lot of repetitive typing, or menuing, or clicks.

Don't ask to ask, just ask... please 🤨

sudo chmod -R 000 /*

Link to comment
https://linustechtips.com/topic/1592240-vi-vs-emacs/#findComment-16596409
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×