Live data from Hacker News

My Emacs Productivity Tricks/Hacks

mycpu.org

41–50 of 210 posts

Re: My Emacs Productivity Tricks/Hacks

#41
post #38

It seems a lot of people have used emacs for years and love it. I never saw the point of learning as it seemed cryptic. In 2020 is it worth putting the effort to learn now? I figure with vim and IDEs I dont really need it.

I switched to emacs in 2019 after using primarily vim for 12 years, and I think it's more than worth it. It's not an editor, it's not an IDE, it is kind of like an operating system where you can have a text editor, debugger, notes, mail, whatever you want. If you dig that, you'll love emacs. It's extensible in a way you've probably not experienced anywhere else, so if you like honing your tools so they fit the way you want to work, emacs is for you. I've actually come to long for an operating system that gives me the same "interactivity" as emacs does.

Of course, I edit text in emacs with evil: https://github.com/emacs-evil/evil

Re: My Emacs Productivity Tricks/Hacks

#42
post #38

It seems a lot of people have used emacs for years and love it. I never saw the point of learning as it seemed cryptic. In 2020 is it worth putting the effort to learn now? I figure with vim and IDEs I dont really need it.

My highlight of 2019 was learning emacs.

I see it as an investment, since it will probably outlive me and anything an IDE can do, _technically_, can be done in emacs.

I was previously a vim user and I wanted to extend my editor but I really hate vimscript. I took a look at Emacs's Elisp and I liked it. To my surprise, the ecosystem was updated with my current tech stack (TypeScript, with the Tide plugin). I was really used to vim so I decided to create my own 'distro' and I began recreating some vim editing functionality along with similar keys (Since I'm not using evil mode or anything, I just made a prefix with Ctrl).

At the end I realized I only liked vim because of its ubiquity and keymaps.

Re: My Emacs Productivity Tricks/Hacks

#43
post #17

I've used Emacs for decades and still feel like I'm barely scratching the surface. What would really help me with articles like this one is more narrative on _why_ these particular modes are so useful. For example, it took me a long time to learn org-mode because I just didn't know what to do with it! I feel like Helm is similar, I've tried it briefly, but I'm not sure if or how it would fit into my workflow.

I completely agree. I used vanilla Emacs for about a decade before finding list-packages. (I know, I know. I was really behind.) But stuff like org-mode never clicked for me. I had to sit down with the manual and read it to finally get a handle on what it is. I'm currently drafting an essay on what makes org-mode compelling, rather than how to use it. I think I'll do the same for other tools I use.

> I completely agree. I used vanilla Emacs for about a decade before finding list-packages

I think it helps to think of Emacs as just another platform - and a nice stable one. You may or may not use, or know about, all the "applications" available for it. New stuff comes along that you haven't heard about; you might occasionally want to review things; and it doesn't really matter if you don't.

I've been using it for the usual handful of decades and have gone through phases of using one exciting new thing or another, but I've dropped most of them - I no longer run builds from Emacs (I do recompilation in the background in a separate terminal), nor read mail or use version control software from within it. I don't use evil and my colour scheme is mostly black-on-white. My .emacs has ended up almost back where it was 25 years ago. (In fact it still has references to Epoch and Lucid Emacs in a couple of comments.)

The two additions in the past couple of decades that have made a big difference to me are Tramp (a nice upgrade from ange-ftp) and the ability to set non-integer line spacings.

Re: My Emacs Productivity Tricks/Hacks

#44
post #25

Earlier quoted context omitted.

What's the point of TRAMP when you can just use the FUSE sshfs module?

Can you compare and contrast the two? I really like tramp for seamlessly editing files on a number of remote VMs. You can even edit files inside Docker containers on remote systems via multi-hops. Tramp is a huge timesaver.

Well one major thing is that tramp is inside emacs so you can configure it with elisp, which is a major plus in my mind. The main problem with tramp is that Emacs is single threaded (and elisp threads run one at a time), so networking operations can be iffy. On most normal connections it works fine in my experience. Another reason to use sshfs is if you're switching between Emacs and a separate terminal, you don't need another connection. That goes away with vterm since now you don't need a separate terminal (it fixes a lot of the traditional problems with ansi-term, shell-mode, and eshell. Although there's a good argument to make for using eshell as your main shell).

Re: My Emacs Productivity Tricks/Hacks

#45
post #38

It seems a lot of people have used emacs for years and love it. I never saw the point of learning as it seemed cryptic. In 2020 is it worth putting the effort to learn now? I figure with vim and IDEs I dont really need it.

> Is it worth putting the effort to learn now?

As a big emacs guy, I say it's only worth putting in the effort if you really enjoy the process of crafting a tool that fits the shape of your mind and bending your mind to fit the shape a tool. I personally get a lot of pleasure out of improving my text editor, but I don't think most people will/do.

Depending on your choice of IDE and your proficiency with vim I think the efficiency gains you'd get from switching to emacs will be relatively slight.

Re: My Emacs Productivity Tricks/Hacks

#46
post #34

Another beautifully designed piece of Emacs software is magit, where the defaults are extremely sane. The package is self-documented and you can learn it all by typing ? anytime. Being able to git log the file you are in is also a huge plus.

Magit made me a better programmer. Learning `git` proper would probably be as good (and certainly get more street cred), but magit was more accessible and more fun to use since I was already emacs-proficient.

Re: My Emacs Productivity Tricks/Hacks

#47
What is the emacs equivalent of package.json?

(whenever I git clone my dotfiles on a new machine I usually have to comment out a bunch of stuff in my ~/.emacs because it's referencing packages which aren't installed, and I forgot where I installed them from, what version, etc...)

Re: My Emacs Productivity Tricks/Hacks

#48
post #38

It seems a lot of people have used emacs for years and love it. I never saw the point of learning as it seemed cryptic. In 2020 is it worth putting the effort to learn now? I figure with vim and IDEs I dont really need it.

If you already have a wife you love, then no, it does not necessarily make sense to try and marry somebody else's, even if you know he loves her.

Re: My Emacs Productivity Tricks/Hacks

#49
post #47

What is the emacs equivalent of package.json? (whenever I git clone my dotfiles on a new machine I usually have to comment out a bunch of stuff in my ~/.emacs because it's referencing packages which aren't installed, and I forgot where I installed them from, what version, etc...)

I think you're looking for https://github.com/jwiegley/use-package ?

Re: My Emacs Productivity Tricks/Hacks

#50

I'm ashamed to say I've been using Emacs since 1992 but I have never been able to impress into my brain anything other than the minimal set of keystrokes to do basic editing. I feel like I need to be trapped on an island where the only thing I could do was learn emacs for a bit. There's so much there to dig into.

This is why I regularly create hydras for every emacs mode that I use. That way I don't have to remember any extra keystrokes, as the hydras will remind me.

What's a hydra? (in this context)
Post reply on HN