23 ms·
Absolute Beginner's Guide to Emacs (2012)
- honestoHeminway 8y agoIf your software frequently needs guides, it is unintuitive, meaning it has a interface beginners can not use without reading excessive documentary. Your software is non-exclusive for people who do not want to devote their live to this or that purpose, which is eltism, which makes your software bad and you should feel bad.
- oytis 8y ago> Absolute Beginner's Guide to Emacs Use vim.
- oblio 8y agoI tried Emacs several time. The concept is cool but the execution makes it so that for me, in practice, VS Code is better. I'd want either: * tabs with a good UX or * super powerful, easy to use, integrated command and fuzzy file search, also with a good UX. I'd also want a terminal at least as good as the VS Code one, on Windows, to use with Cygwin. With Emacs I'd have to learn a big bunch of terminology no other editor uses for a bit of flexibility while losing quite a bit of functionality. Sadly for Emacs, I think that most devs are closer to my train of thought than to that of existing Emacs users.
- vvillena 8y agoIt's true that tabs would be nice sometimes, but usually Emacs users have lots of files open all the time. The usual open-edit-close workflow doesn't really apply to Emacs sessions. An Emacs tab bar would resemble that of a browser with 100+ tabs, so the problem is that the people that would be capable of implementing that feature wouldn't use it in the end.
- pulisse 8y agoThere are very few respects in which Emacs is less functional than other editors (good integration with semantically aware refactoring tools is the primary one, imo), and it has excellent support for the only functionality you explicitly mention (command and fuzzy file search).
- oblio 8y agoI guessed you missed that part of my comment where I mention tabs and good terminal support on Windows...
- sn41 8y agoYou can consider these points: - Tabs are not present in Emacs, but C-x C-b will list all open buffers + Fuzzy file search : you can take a look at the popular Ido-mode + eshell is pretty powerful, if you think about it, you have all the emacs search functionality etc. available in a shell inside the editor itself. I am not trying to popularise emacs, but "inflexible" is not something that you associate with emacs. If anything, it is the bewildering array of choices that is one drawback. Plus, you should really try: + org mode : what is the standout feature now a days. You can even do literate programming in the org mode, so can be viewed as an alternative to Jupyter, for example. The real gripe for me about emacs is that it is single threaded. So a long grep launched off will freeze the entire editor.
- oblio 8y ago> - Tabs are not present in Emacs, but C-x C-b will list all open buffers I want a passive, not an active interface. I want to be able to visually scan the tabs. I want to be able to click them when I'm not in the mood for keyboarding. I want the tabs and the tab bar to not be ugly as sin :) Etc, etc. Heck, if Vim has them built-in (and Vim also has the same concept of buffers as Emacs), surely Emacs could (should?) have them. > Fuzzy file search : you can take a look at the popular Ido-mode I know there's modes for that, but open up a folder in VS Code. It's seamless, I don't need to configure it, it just works, they bundle ripgrep for me, etc. The UI/UX are also slick. > The real gripe for me about emacs is that it is single threaded. So a long grep launched off will freeze the entire editor. Yeah, Vim is kind of like that, even though it's recently gotten async.
- Yftgggfff 8y ago>I want a passive, not an active interface. I want to be able to visually scan the tabs. I want to be able to click them when I'm not in the mood for keyboarding Ibuffer is included in the gnu Emacs distro and does all of this.
- oblio 8y agoIt looks nothing like a CUA tabbed interface...
- gnuvince 8y ago> * super powerful, easy to use, integrated command and fuzzy file search, also with a good UX. Sounds like you should try ivy and its companions. Ivy offers fuzzy matching for all operations in Emacs (e.g., switching buffers, opening files, looking up documentation) and the counsel packages (e.g., counsel-rg) use that same interface to interact with external tools such as ripgrep or git grep. Ivy has completely taken over my Emacs experience, and it did not require a lot of configuration, just a few keybindings. As for a terminal, I don't have a Windows machine to test, but `M-x ansi-term` is pretty much exactly like a regular terminal: you can run any program in it, including htop or even vim.
- oblio 8y agoM-x ansi-term ask for [...]/emacs/libexec/emacs/26.1/x86_64-w64-mingw32/cmdproxy.exe and then throws "Spawning child process: Invalid argument". M-x term does the same. Those lead down this rabbit hole: https://stackoverflow.com/questions/4535432/terminal-in-emacs-in-windows-error-message-spawning-child-process-invalid-a https://stackoverflow.com/questions/4535432/terminal-in-emac... M-x shell seems kind of dumb. M-x eshell is not a usable shell. Anyway, everything feels and is very stitched together. (I also don't understand why declaring VS Code better than Emacs for my use case is downvoted, since it's the truth...).
- xte 8y agoEXWM/Fulltime Emacs user here... Well... No, ansi-term, sane-term etc are not like regular terminals, they can work for simple things but they are limited, limiting and buggy... When I start living in Emacs I reduce significantly the dependency of the shell (tramp and dired do most of the business) and start using eshell a bit, but I still use terminator when I need a real terminal...
- todd8 8y agoI've heard developers say this before, they want tab bars or good fuzzy search. The puzzling thing is, I feel almost exactly the opposite. I've used many other development environments (over the last 50 years), some for years at a time and others on off for many years: Intellij, Xcode, Adobe products, Textmate, Vim, etc. These other IDEs and editors certainly have their own strengths and are in some ways better than Emacs for some tasks, but for navigating between tasks, projects, and recently used files Emacs is the best tool I've ever used. To visit a file, whether for the very first time or to just get back to the previous one you were using, the find-file command is Ctrl-X Ctrl-F. This does exactly what I want about 90% of the time. I type a few letters and because of completion I get to what I want in an instant. This command is one of the first ones that beginners need to learn to open a file for editing. It's trivial to rebind the visit-file command to any key you like (Spacemacs uses Space-F-F). You might be thinking, "Oh yeah, but sometimes I want to open a file read-only", well there's a command for that too its find-file-read-only, bound to Ctrl-X Ctrl-R. Or maybe you're thinking, "What will I do when I want to insert the contents of a file at the cursor?" maybe Emacs won't work for me since I do that a lot. The good news is: there's a command for that. You might be thinking "Thats swell, but sometimes I need to see the file contents in hex!", well there are commands for that too. On my system there are almost 500 available Emacs functions containing the word file. I was able to find that out with the built-in documentation that gives me access to descriptions of all these functions and key bindings in just a couple of keystrokes (C-h starts the best built in help system I've ever used, period. You can even jump into the code that implements all of these functions.) I recommend sticking with the simple find-file command for a week or two before delving into the many fascinating options available for the Emacs hacker. If you want to actually see the files that you have already been editing, Ctrl-X Ctrl-B lists the buffers in use. This is a bit like looking through tabs, but Emacs manages hundreds of simultaneous buffers at once and some users like using the buffer list to see all of the current work across many tasks that have been going on over a period of weeks. You can navigate rapidly though the buffer list and pick a buffer to be displayed in your current window pane or other panes or windows. Jumping between buffers, windows, panes within windows is all done with a couple of keystrokes so its fast and easy. If you know the name of the file/buffer already you can use Ctrl-X B, the switch-buffer command to open it directly without browsing the buffer list. Maybe it's not a current file you want and maybe you don't remember the name but you do know where it is located. The amazing dired interface displays directories and makes it easy to list, rename, or edit (or copy or change permissions, etc.) the files within a directory or it's parent directories or children. Again the interface is right from the keyboard so it is very fast and easy. Dired opens automatically when you do find-file on a directory name. Sensible name completion and shell like navigation make it easy to get places in the file system or remote file systems though the magic of Emacs ability to treat file systems on remote machines like local files if the user has ssh access. Dired is great, there is nothing like it and its various extensions provided by the Emacs built in package system. These simple to use commands and a couple of commands for splitting windows into panes and jumping between them will get you a long ways and in no time you will discover that you don't miss tabs anymore. I really appreciate the extra screen real estate I have because I don't need tabs or tool-bars in Emacs. I can easily see three or four files at once since the navigation buffers for dired and buffer lists open only when needed. I know, you're maybe wondering if a form of Emacs Stockholm Syndrome has me under it's spell: windows, panes, buffers, files--it just sounds confusing. Yes, tabs are a simpler idea. Emacs has been around so long that its nomenclature is a bit archaic. What a normal developer would call a window is a "frame" in emacs. I usually like to have a single large frame while I'm using emacs, but you can open up a multiple Emacs Frames, say on different displays, and hop between them with a keystroke or two. Sometimes that's helpful. Inside a Emacs Frame you can have multiple re-sizable horizontal and/or vertical splits that give you a number of separate panes for editing in. I usually have two or three while I'm working. They work great and are easy to use with a few of the built in commands. The biggest problem is that Emacs documentation calls them "windows". So in Emacs terminology a Frame contains Windows (in modern terminology we would say the Emacs windows can be divided into panes or regions). A Buffer is just an editing session (usually, although documentation and system information is also held in buffers). The buffer has a cursor and some other features and is usually associated with some underlying file, but the buffer can be written to a different file (kind of like Save-As) and now it becomes associated with the new file name. Multiple buffers can be opened against the same file providing different views of the the file and they can have different cursor positions and different editing modes. Is a buffer also an Emacs Window or Emacs Frame? Buffers exist independently of the user interface to the buffer. When you open a file in a new buffer or switch to an existing buffer for a file, the buffer is presented for editing in one of the Emacs Windows in one of the Frames. The default is the current Frame in use. This makes switching to a buffer like clicking on a tab. But the architecture is more flexible. The commands I've mentioned work in default Emacs right out the box. More experienced users like some of the fancy searching and auto-completion packages like helm or ivy. There are also speedbars for those that like to mouse-click on a project directory outlines and sophisticated project management tools like projectile with fuzzy searching across the files withing the project. These add on packages are so easy to add that the real problem is having too many features available. I should mention that there are many fancy fuzzy search tools, but I really don't use them myself, I get by with the basic functions provided by Emacs for grep'ing and searching. And if you still want tab bars there's a package for that, tabbar mode. Related to project management and along with org-mode one of the most recommended Emacs packages, magit, a really great interface to git that is very well integrated with Emacs.
- LandR 8y agoI started using Emacs a few months ago and I love it. I think I'd struggle day to day now without Org Mode. I love how easily I can switch from something in Org Mode to something like a Clojure REPL, then to a Powershell window and to a text editor. If I can just get it doing C# editing / compiling I'd be very happy.
- kqr 8y agoI started working in a .NET shop a few months ago and have finally sorta-kinda gotten my Emacs configured the way I want to in terms of C#. If there are any specifics you need help with, shoot me an email or something!
- cpfohl 8y agoWould you post a gist of your config?
- kqr 8y agoThe entire thing is up on https://github.com/kqr/.emacs.d/blob/master/init.el https://github.com/kqr/.emacs.d/blob/master/init.el . One would think modularity is not a word in my dictionary, though...
- na85 8y agoHave you ever managed to get intellisense working for c#? I try every few months with junk like Roslyn but it never seems to work. It just silently fails to do anything at all.
- kqr 8y agoThat was tricky to get working well, and for a while I hobbled along with gtags... but I do have it working now. And it wasn't that complicated, I was just missing an embarrassing piece of the puzzle. But yes, basically (require 'csharp-mode) (require 'omnisharp) (setq omnisharp-expected-server-version "1.32.8") (add-hook 'csharp-mode-hook 'omnisharp-mode t) Then omnisharp should be able to install and start a Roslyn server on its own with the corresponding commands. The annoying issue that at first prevented this from working was that on OS X I also needed (require 'exec-path-from-shell) (exec-path-from-shell-initialize) But figuring this stuff out was only a matter of reading the omnisharp-log buffer and guessing what the errors may be caused by.
- noelwelsh 8y agoAt some point I realised maintaining my own Emacs setup was just too much work. I've used a few Emacs setups (Prelude and Spacemacs are the ones I used for the longest) and now I use Doom: https://github.com/hlissner/doom-emacs https://github.com/hlissner/doom-emacs It's very fast and has a lot of built-in in niceties, and I find it easier to understand than Spacemacs. If you use Doom make sure to use the develop branch.
- simias 8y agoOh man, your link led me to shackle[1] to make transient buffers behave and I have wanted that for... well for as long as I've been using Emacs really, and that's quite a long time now. I don't get how anybody is fine with Emacs' default "let's pop this buffer anywhere, possibly hiding a useful window". [1] https://github.com/wasamasa/shackle https://github.com/wasamasa/shackle
- pulisse 8y agoThat looks awesome. Emacs's default behavior in this respect is theoretically customizable, but the mechanism for doing so (display-buffer-alist) is (to me) incomprehensible. It seems like what Shackle does is provide a clean interface for specifying rules that get translated into display-buffer-alist rules.
- simias 8y agoYeah I've tried a few time to customize this behavior over the years and while I did manage to improve it somewhat it's still far from how I'd like it to be.
- catacombs 8y agoI agree. Doom takes the best of emacs and vim and mashes them together nicely. I've been using it for more than a year and haven't looked back. There is a challenge configuring your version of Doom, but the project's Discord channel is active, friendly and helpful.
- androidgirl 8y ago
- purple_ducks 8y agoI really feel VSCode is lining up to be the new goto IDE across multiple languages. Slightly less (directly) extensible than Emacs but still feels it can do pretty much everything that needs doing, plus way nicer & friendlier default UI.
- chimprich 8y agoVSCode is the first editor I've seen that has made me think maybe I'll move away from Emacs at some point. I think a fully tooled-up Emacs setup in the hands of an experienced user is still faster and more powerful but I do wonder if Emacs will be able to develop fast enough to keep up with the cutting edge.
- thecryusofiran 8y agoAs an Emacs user I'm mostly "afraid" of VSCode getting so popular that people will make cool tools targeting VSCode only. Like, it'll become the Chrome of text editors.
- simias 8y agoEmacs hasn't been really mainstream in quite a while and it's still actively maintained and improved upon. I'm not too worried. A small-ish skilled community is enough to keep the project going. What's VSCode's market share anyway? Is it really that big? I've never used it personally and I had no idea it was so popular.
- kryptiskt 8y agoIt has become really popular: https://insights.stackoverflow.com/survey/2018/#technology-most-popular-development-environments https://insights.stackoverflow.com/survey/2018/#technology-m...
- pulisse 8y ago> A small-ish skilled community is enough to keep the project going. The trends of the last few years are worrisome, though, particularly as regards the pool of developers who can work on Emacs core (the part written in C). Right now there's only one dev who's in a position to do non-trivial work on the display engine, and he also took on primary maintainer responsibilities a couple of years ago. When he burns out, the project is going to stall, hard. Stefan Monnier, who was maintainer for most of the past decade, perceived this trend very clearly and was vocal in trying to recruit new talent. He didn't get much cooperation from other core devs.
- ginko 8y agoWhy not just follow the built-in Emacs tutorial that can be started with C-h t(press CTRL+H together, then press T)?
- stilley2 8y agoI gave emacs another try earlier this year. First vanilla, but then I missed vim keybindings so I installed evil. Then I switched to spacemacs. Eventually I decided I was barely using any emacs-specific features and just went back to vim. Vim feels so much snappier. I do miss some of the more ide features (jump to definition, execute selected code) but it wasn't worth the overhead, imho.
- purple_ducks 8y agoIf there's one thing I will always be grateful to emacs for; it will be changing Caps Lock -> Ctrl Life changing.
- FPGAhacker 8y agoI completely agree, but I have the os do that. Except on my iPad where I am grateful for blink to have that capability. On windows I had a special mode for caps lock via autohotkeys. Press and release meant esc. Press followed by another key and release was ctrl-key. I really liked that, but I couldn’t do it on Mac or iPad so I just settled on ctrl. My old //e has control there naturally.
- purple_ducks 8y agosure, i changed it at OS level too. maybe i should have wrote "introduce me to Caps Lock -> Ctrl"
- thestephen 8y agoThe behaviour you have for Windows is available for Mac with Karabiner-Elements. It's tremendously helpful.
- FPGAhacker 8y agoI haven’t looked at karabiner-elements for a while. Last I looked it wasn’t able to do what I needed. I’ll go have a peek.
- 8y ago
- Wildgoose 8y agoI have yet to encounter anything that can match the sheer flexibility of Emacs. For example I am currently using Org mode to write some documentation complete with hyper-links, tables, foot notes and the option to export the results as LaTeX, HTML, Open-Office, and so on with just a few keypresses. It's not just an editor, or an IDE, or even a windowing system - it is a cross-platform computing environment that can be fashioned to exactly suit whatever purpose you require.
- dmitriid 8y agoEmacs is an OS that lacks a decent text editor (the joke is as old as Emacs).
- purerandomness 8y agoNot funny. Evil mode was released in 2013.
- someguy101010 8y agoThat's much more recent than I expected
- alpaca128 8y agoI tried Evil mode a few months ago and went back to Vim very quickly. It's one of the best Vim plugins out there, but it still misses a few features and it also behaves differently in a couple of situations. It never really feels like Vim, more like a minefield of unknown shortcuts with a layer of Vim bindings on top. But I get why some people like it, if you can't stand modal editing then Emacs is a great choice.
- jacobherrington 8y agoAbout four months ago I moved from VS Code to Spacemacs and it has been an extremely rewarding experience. Anyone who is afraid of Emacs or Vim should give it a try. I've heard good things about Doom and Prelude as well.
- brlewis 8y agoDid you have previous experience with emacs? I'm a long-time emacs user, but have been assuming it's better to introduce new people to VS Code since it's more mainstream.
- jacobherrington 8y agoI did not have any experience with emacs and only the most basic knowledge of Vim. I had some guidance from my company's CTO though.
- fbnlsr 8y agoCould you give us a few pointer on how you prefer working with Spacemacs rather than with VS Code? I've tried Vim a few times but got turned off by the slow process of learning the multiple keyboard shortcuts to do a simple task.
- Cyph0n 8y agoI'm relatively new to Vim (~4 months). I used the "learning by doing" approach by forcing myself to use Vim to write C and Python at work. I had two main reasons for learning Vim: (1) Vim is everywhere, so it must be worth it to learn the basics at least; and (2) modal editing felt easier on my wrists than the standard mouse + shortcuts approach I ended up using in other IDEs. Here is my advice: 1. Start with only a theme in your .vimrc, so no plugins or non-standard key bindings. 2. Use Vimtutor (or any other tutorial) to learn the basics: normal vs. insert mode, movement, manipulation, yank/paste (+ clipboard), splits, buffers, and searching. 3. As you write code, you will find yourself wanting to know how to do X. This is where Google and a simple "cheatsheet" file come in. Once you find out how to do X via Google, add an entry to your cheatsheet file (example in HTML form: [1]). 4. In many cases, you will find that a plugin will solve one of your issues. Install that plugin and add it to your .vimrc. I recommend vim-plug[2] for managing and installing plugins. 5. There are many useful plugins out there. Two I would strongly recommend: CtrlP[3] and NERDTree[4]. Once you have a good grasp of Vim, I would recommend exploring Emacs + Evil-mode if you want a more complete IDE experience. [1]: https://assil.me/2018/11/12/vim-cheatsheet.html https://assil.me/2018/11/12/vim-cheatsheet.html [2]: https://github.com/junegunn/vim-plug https://github.com/junegunn/vim-plug [3]: https://github.com/kien/ctrlp.vim https://github.com/kien/ctrlp.vim [4]: https://github.com/scrooloose/nerdtree https://github.com/scrooloose/nerdtree
- sn41 8y agoThere is a strange editing mode that I stumbled on by myself, which I can do in Emacs. Suppose I am editing a huge file, and need to make change in some other part without necessarily forgetting where I am. I just open a new buffer for the same file, edit the desired area, and close the new buffer. I have the old position restored automatically in the old buffer. Of course, this can be done to arbitrary number of levels. This is because Emacs separates the concept of buffer and the file it visits. This is a basic concept, but its use in the above manner is not something I have explicitly seen mentioned. Do other editors (vi, eclipse, sublime) have similar features?
- SPBS 8y ago:tabedit % will do that in vim. :tabclose to close the tab when you're done.
- dhimes 8y agoIn vim, I use vsplit to open the same file, make my edit, and close it. tbh, it's faster to mark my spot with m[az], make my edit, and return to my spot `[az] ([az] means any lower case letter).
- dedosk 8y agoMSVC IDE has menu Window -> New Window to mimic this iirc.
- ludwigvan 8y ago
- teddyh 8y agoOr take the Emacs Tour: https://www.gnu.org/software/emacs/tour/ https://www.gnu.org/software/emacs/tour/
- losthobbies 8y agoWatching Jonathan Blow flying around Emacs on his Twitch streams is always very impressive.
- gnuvince 8y agoI find Jon enraging, especially when he whines about Emacs: a number of the things he complains about are either fixed in newer versions of Emacs (he's still on Emacs 23) or packages offer a vastly improved user experience.
- losthobbies 8y agoI'd be worried about Jon if he wasnt complaining about something.
- brandonmenc 8y agoSo I just pulled up this video of him coding with emacs: https://www.twitch.tv/videos/343721241 https://www.twitch.tv/videos/343721241 Correct me if I'm wrong, but the first two minutes is him trying to find an instance of like, a variable or something, and he individually goes into a bunch of files one by one and does a text search, then eventually pulls up a third-party file search tool outside of emacs to do it. On Jetbrains IDEs I would just hit "shift-shift" and get a project-wide search dialog that searches across all of my files and even tells me what kind each instance of the text string is - variable, class, etc - as I'm typing.
- vvillena 8y agoDoes IntelliJ support the Jai language? In any case, "M-x helm-projectile-find-file" is the Emacs equivalent of IntelliJ's shift-shift. It's nicely bound to "SPC p f" if you use Spacemacs. You can also search tags (variables, symbols, classes, etc) with "SPC p g". Plus, going for a 3rd party search tool is personal preference, Emacs can also do that. I'm a heavy user of both Spacemacs and IntelliJ, and while the quick search interface of IntelliJ is awesome, Emacs also has this functionality. I assume Jonathan's problem in that video is due to poor language tooling, plus his personal workflow preferences.
- alan_wade 8y agoI have to share it here: http://emacsrocks.com/ http://emacsrocks.com/ This is an absolutely insane series of tutorials that will explode your mind and make you feel godlike. If you want to learn why people love emacs so much, watch this.
- noufalibrahim 8y agoI used to run http://emacsmovies.org/ http://emacsmovies.org/ and the first video of that was similar to the original article here. Terminology and basic keystrokes. The Emacs refcard whose source comes with Emacs is also quite useful and I usually provide printed copies to all my students.
- kgwxd 8y agoThe only thing I don't like about emacsrocks is that it's not text. Videos make for horrible reference material.
- stronglikedan 8y agoI have a vendor that actually tries to submit videos as "documentation" for the projects that they work on. I keep telling them that videos are good for tutorials and presentations, but they are not documentation. I catch it in the SOWs, but I missed it on the first few. They refused to provide written documentation saying it wasn't in scope, which was their right since it wasn't. I have never watched and critiqued videos for completeness before or since, but they would have been better off just providing the written docs, since they spent so much time adding and editing video content. They still try to sneak it in the SOW as if they learned nothing, and now it's just our little game we play.
- Assossa 8y agoI've been using vim for a couple years now. I mostly use it for programming in C/C++/Python. Is it worth it to learn emacs or should I just stick with vim?
- drewg123 8y agoEmacs is habit forming. I started using emacs as an undergrad in the late 80s, as it was the only way I knew of at the time to have multiple windows open on a standard DEC VT-220 terminal. ( I did not know about screen; it was quite new at the time ). I switched to using my UNIX account daily from VMS mainly to get access to this feature that I saw my friends and upperclassmen using. After I got access to an X11 based workstation in the early 90s, I was so used to emacs that I never looked around for alternatives. I can edit simple files in vi, but I don't use it for anything complex. The closest I ever got to using another IDE was in the early 2000s when I was tasked with writing drivers on MacOSX. I looked at using Xcode and quickly returned to emacs (mostly so that I could continue to use my X11 focus-follows-mouse environment, and not be forced to sit at a mac). To this day, I swap my caps-lock and control keys, because that original DEC keyboard had ctrl as the left-most key on the home row. As did the sparcstation keyboards..
- deleted 8y ago[deleted]
- macintux 8y agoApple too used to place the control key in the correct location. It was quite unfortunate when Sun and Apple gave up the good fight.
- Torwald 8y agoWhich was the last Apple model with the Ctrl-key at the correct location?
- macintux 8y agoFrom skimming the Wikipedia article, looks like an optional keyboard from the Mac II/SE days was the end of that era. https://en.wikipedia.org/wiki/Apple_Keyboard#Apple_Keyboard_(M0116) https://en.wikipedia.org/wiki/Apple_Keyboard#Apple_Keyboard_...
- 8y ago
- mr_overalls 8y agoIs Emacs worth learning well if you're not primarily a software developer? For a DBA or data engineer, for example (as I am)?
- mickeyp 8y agoYes, it is. You will benefit greatly from the tight integration between shells, remote file editing, database support (albeit fairly simple, compared to dedicated tools) and obviously an excellent editing environment in general.
- mercer 8y agoAbsolutely. While I've been trying to do more coding in emacs, I primarily use it for various interactive shell stuff, file management, project management, time tracking, todos, calendar, journalling/loggin, and the occasional remote file editing (Through the TRAMP package).
- Vekz 8y agoYes. you can use org-mode to create a living 'literate code' document of database connections and queries. You can then execute the queries directly from this document. something like https://truongtx.me/2014/08/23/setup-emacs-as-an-sql-database-client https://truongtx.me/2014/08/23/setup-emacs-as-an-sql-databas...
- mr_overalls 8y agoWow, this is fantastic!
- robto 8y agoBeware! I, too, started as a data analyst taking notes in org-mode and before I knew it I ended up a software developer.
- plg 8y agoemacs for email: what's the current best accepted practice? I'm using Fastmail for my email and I'm on MacOS
- catacombs 8y agoI, too, am interested about this.
- erk__ 8y agoI am using wanderlust, it is not recommended that often but it works for me. It has alright support for imap as well
- kqr 8y agoI have used notmuch for years now and see no reason to stop. Be warned, however, that it does require you to set up some tooling outside of emacs as well.
- tom4000 8y agoI'm very happy with mu4e in combination with isync.
- danilocesar 8y agoHonestly, I've opened that page expecting to see a "Don't!" or "Use Vim instead" message... The different between Emacs and Vim tutorials nowadays is that, while both of them have a section about how to open it, only vim has a section about how to exit it </joke> Ok, that's all I had... That said, I still think that both vim and emacs are going to lose the battle against those fancy-new-shinny-atom-sublime like editors eventually. Which is sad (I'm a vim user), but no one wants to memorize lots of short cuts anymore.
- Tistel 8y agoYou should check out tramp-mode too. Its a killer feature that lets you edit files remotely (AWS, Azure, even docker containers!) as if they are local. All the stuff work, so you can do diffs between a local file and an a AWS file and it all appears to be local. If you are editing a remote file and do a git action (through magit) it knows to work on the remote file. You can open up remote shells also. You just go: CTRL-X CTRL-F then => /ssh:username@example.com:~/somefile.txt and you get a local buffer with the contents of the remote file (via scp). All your editing is the same as if it is local. When you save it does a scp back to the remote machine. You can even edit in docker containers: /docker:root@03f5f926f1ca:/etc/environment as if they are local. Merges/diffs all just work its really great.
- Vekz 8y agoA common selling point for VIM is "its installed everywhere you just ssh in and it's available". To that, I usually bring up tramp and say, who cares you just ssh in from emacs.
- admax88q 8y ago> A common selling point for VIM is "its installed everywhere you just ssh in and it's available". I've never understood this argument unless you're coming at it from a sysadmin perspective. Sure if its available everywhere that helps when I'm sshing in to random systems to sysadmin stuff. But I don't do my development by logging in to random new systems all the time. I do my development in an environment that I have set up to be productive with.
- anyfoo 8y agoThat’s a very specific development story, though, common to e.g. web development. If you’re, for example, a developer working on an embedded platform which (even temporarily) has no ssh, and probably no emacs as well, tramp-mode won’t work. I’m a hard emacser, but it’s true that vi is usually much more ubiquitously available, so it’s good to know how to use it.
- pie_hacker 8y agoI think that one of the key insights of Emacs is that moving the mouse is a very slow process relative to using the keyboard.
- sn41 8y agoAnother subtle but important use of emacs : it is a good playground for (a flavor of) Lisp. Together with the source code galore in site-lisp/, it is a really good environment to learn how a full-blown system can be put together in Lisp. [Hooks, macros, advice - all the goodies to shoot yourself in the foot in that wonderful Lisp way!] Also relevant is the great article by Stallman on the exact C-vs-Lisp division of labor in emacs. This design philosophy of "bare metal" programming in a fast language + an interpreter for flexibility is also the philosophy behind GNU guile: https://www.gnu.org/gnu/rms-lisp.en.html https://www.gnu.org/gnu/rms-lisp.en.html https://www.gnu.org/software/guile/ https://www.gnu.org/software/guile/
- loosetypes 8y agoThanks for the first article. “Multics Emacs proved to be a great success — programming new editing commands was so convenient that even the secretaries in his office started learning how to use it.” This reminds me of a story I heard that early on at Amazon supposedly the company used applications built onto Emacs instead of building in-house web applications for internal use. I had a chance to talk with an early employee but unfortunately forgot to ask about it.
- NateEag 8y agoYou are likely thinking of this Steve Yegge essay: https://sites.google.com/site/steveyegge2/tour-de-babel https://sites.google.com/site/steveyegge2/tour-de-babel Search for "Then you know Mailman", and you'll find the bit I'm thinking of. It doesn't say they built multiple systems around Emacs, but it does say Mailman was built in Emacs Lisp, and that they had people writing Emacs extensions to further Mailman's functionality. (And that their non-technical customer service folks loved Mailman.) Edit: found more-canonical URL.
- Torwald 8y ago> [Hooks, macros, advice - all the goodies to shoot yourself in the foot in that wonderful Lisp way!] You use a very common technique to make the joke, a "turn" so to speak. This makes the joke recursive because it involves Lisp. It's fitting, I just had to laugh!
- del82 8y agoOK, question from a fellow Emacs user: If a student asked you which text editor / IDE they should learn _ab initio_, would you recommend Emacs without reservation? I'm not sure I would. I'll certainly never stop using it, because I've got 15+ years in it now and the key bindings and my config are as automatic as breathing. But I wonder if the investment is worth the cost for a new user, who could just use another excellent editor that's maybe a bit less full-featured but with a drastically shallower learning curve?
- mercer 8y agoI'd probably recommend VSCode.
- craigsmansion 8y agoCS student? Yes, without reservations. And any other student probably as well. Emacs is not a program just for coding. It can be used for anything that can be expressed in a text oriented way: writing a book, a thesis, an email, etc. And most editing commands work in exactly the same way in those contexts. > if the investment is worth the cost As you said: 15+ years. And that's not really any sort of exception in the emacs world. Of all the software in existence, I'd say emacs is one of the most likely not to stop development in my lifetime, or the lifetime of anyone alive today (and I'm not even talking about being able to maintain it yourself if push comes to shove). So for anyone serious about writing anything at all, emacs is never a bad recommendation.
- wry_discontent 8y agoI used to be a heavy emacs user, but I've mostly abandoned it because I'm lazy. It takes a fair amount of effort to keep up with new environments. If I change jobs (which isn't infrequent), I'll need to reconfigure a lot of the setup to work how I like. Packages upgrade and break. For me, I just found the amount of effort it required to keep the environment set up nicer than, say intellij, just wasn't worth it. Nowadays, I mostly use VS Code for a text editor, and intellij for larger codebases. I still drop down into emacs if I need to do serious text manipulation or weird git stuff, but that's about it for me.
- j0e1 8y agoEven though this is a beginner's guide, I feel it should introduce the reader to the Emacs way of navigating using the C-`b f p n` keys at least, let alone their M-[] alternatives. These would significantly improve the users ability to move around the buffer without having to keep shifting hand position to the arrow keys.
- ben509 8y agoOne point any beginner's guide should mention is that the basic Emacs navigation and kill-ring keys are also used in common utilities. The info command is derived from emacs, but they're also used in Bash and less, and support is fairly common in text editors and IDEs. As a beginner, you'll get used to them much faster if you use them in more places than just your editor. And Mac users should know that Mac OS X has had basic support for Emacs style editing in native controls, inheriting it from NextStep.
- philipyoo 8y agoIs there something similar but for vim?
- dctoedt 8y agoI was just reading the New Yorker article about the partnership between Jeffrey Dean and Sanjay Ghemawat at Google [0]. I noticed this about Ghemawat's setup: "There were four windows open: on the left, a Web browser and a terminal, for running analysis tools; on the right, two documents in the text editor Emacs, one a combination to-do list and notebook, the other filled with colorful code." (Emphasis added.) I'm guessing the "combination to-do list and notebook" might have been org-mode? [0] https://news.ycombinator.com/item?id=18588697 https://news.ycombinator.com/item?id=18588697
- icodemuch 8y agoI've been using Sublime since I started and have no complaints. That being said I always hear about emacs referred to as the OG. I know there's positives and negatives to both, but is there any pressing reason to switch from one to the other?
- renlo 8y agoWith emacs/vim (etc) you can edit text from within a terminal, which becomes quite helpful when you SSH in somewhere. Also, with a terminal multiplexor like tmux or screen you can also easily jump from shell to shell, which has personally improved my productivity substantially from when I was using GUI based text editors like Sublime or Notepadd++.
- marrone12 8y agoEmacs has terminal multiplexing and easy remote editing over ssh built in as well.
- TeMPOraL 8y ago> With emacs/vim (etc) you can edit text from within a terminal, which becomes quite helpful when you SSH in somewhere. A very underappreciated functionality. Over the past few months, a good 30% of my work was done this way - by SSHing from my el cheapo Windows 2-in-1 to my much more powerful Linux desktop, and using Emacs in terminal mode. With terminal set to xterm-256, it looks almost as if it was GUI Emacs, and has almost all the same functionalities available. I'm a remote worker now, but this workflow adds an extra order of magnitude more flexibility to my work day, as I can leave my environment running when I go on an errand, and pick the work up in a long queue, or on a bus. It's one small thing, but the power of Emacs is really in how all those small little things compose together into a powerful environment you can use from almost everywhere, and on almost everything.
- satran 8y agoI have heard people say Emacs is an OS, just needs a decent editor. To me it is a textual interface, or a text based toolkit very much similar to Gtk/Cocoa/Qt. It provides you with an environment on which you can build upon with Lisp.
- jammygit 8y agoWhich is better for preventing RSI - emacs or vim?