Live data from Hacker News

Learn Emacs Lisp in 15 minutes

bzg.fr

41–50 of 71 posts

Re: Learn Emacs Lisp in 15 minutes

#41

Earlier quoted context omitted.

I'm not a professional programmer, but I spend all day in Emacs primarily because of org-mode. Two years ago I read about org-mode here on HN and was inspired to give Emacs a shot. Today Emacs is my main technical hobby. Extending Emacs with Elisp is a pleasure and a joy. My various init files total over 3,000 lines of code that I wrote my own little self. That said, while I remain incredibly impressed with the integ…

Allow me to suggest Coursera. They have nice courses about FP. Somehow in simple -> difficult order. Systematic Program Design by Gregor Kicsalez (I believe influenced by HtDP). Programming Languages by Dan Grossman. (50 50 HtDP SICP and Brown University material)* Functional Programming using Scala by Martin Odersky (influenced by SICP). In case you can already do the SICP exercises without issues then you won't nee…

I've never heard of these. Thanks much.

Re: Learn Emacs Lisp in 15 minutes

#42
post #4

That was actually quite helpful. I've had the toughest time "thinking in Lisp" as I'm told I have to do to get my head around it (also because I work with the C++/C#/PHP family and switching between them and Lisp doesn't help). I really appreciate the simple instructions in that regard.

I'm not a professional programmer, but I spend all day in Emacs primarily because of org-mode. Two years ago I read about org-mode here on HN and was inspired to give Emacs a shot. Today Emacs is my main technical hobby. Extending Emacs with Elisp is a pleasure and a joy. My various init files total over 3,000 lines of code that I wrote my own little self. That said, while I remain incredibly impressed with the integ…

Congratulations for figuring all this out and getting to enjoy the rewards. But I'm curious: what do you do all day in Emacs if not programming?

Re: Learn Emacs Lisp in 15 minutes

#43
post #34

If you don't know Emacs Lisp, there's no point of using Emacs. You'd probably be more productive in Vim or [insert favorite proprietary editor here]. Emacs Lisp is probably the most featureless language you can think of; it doesn't even do basic threading and the async stuff is a joke. All the major programming language modes are implemented as ad-hoc Elisp regexp parsers making bugs impossible to fix. Virtually _eve…

I always get a chuckle out of people complaining that Emacs is too slow. Maybe I've just "gotten used to it", but when I first started using it I was sharing a Sun 3 with ten or fifteen other people. I'd also argue that modes in other editors are ad hoc regexp parsers in some other form... regexps, in the hands of someone who knows what they're doing, work well. And yes, virtually everything is implemented in Emacs L…

Yep, Ben Franklin worked on one, iirc.

Re: Learn Emacs Lisp in 15 minutes

#44
post #35
post #22

Earlier quoted context omitted.

>A: Foot pedals. That's hilarious. I get that emacs has technical merit but the keybindings are horrendous. Even if they don't cause hand pain they're long-winded and distracting.

> [B]ut the keybindings are horrendous. Even if they don't cause hand pain they're long-winded and distracting. Ha, after 26 years using Emacs I find Vim's keybindings long-winded and distracting. To each their own. However, unlike many people I don't dismiss vi because of unfamiliarity, or use them as an excuse not to learn the editor. I try to use it all the time, but I can never seem to train myself to do non-triv…

I gave emacs a fair shot but aching hands is where I draw the line.

Re: Learn Emacs Lisp in 15 minutes

#45
post #40
post #35

Earlier quoted context omitted.

> [B]ut the keybindings are horrendous. Even if they don't cause hand pain they're long-winded and distracting. Ha, after 26 years using Emacs I find Vim's keybindings long-winded and distracting. To each their own. However, unlike many people I don't dismiss vi because of unfamiliarity, or use them as an excuse not to learn the editor. I try to use it all the time, but I can never seem to train myself to do non-triv…

With regards to multiple selections, have you seen: http://emacsrocks.com/e08.html http://emacsrocks.com/e13.html

That looks great! Earmarked to check out on a rainy day. Thank you for sharing.

Re: Learn Emacs Lisp in 15 minutes

#46

Emacs is a miracle, no doubts. It is self-descriptive and self-contained system, like Smalltalk (you could lookup any function, variable or even key-binding, without a fancy browser, but in a way that is good enough). There is nothing much to say, actually. Emacs is just a wonderful thing.

Indeed. The most value I got from from learning to customize Emacs wasn't the functionality I implemented but seeing how powerful a domain specific language can be. The ways that Emacs Lisp supports working with text, whether data or code or documents, showed me what I should be aspiring to when I create a DSL.

Imagine, then, what a wonderful thing Open Genera was.)

Re: Learn Emacs Lisp in 15 minutes

#47

Earlier quoted context omitted.

After a decade of Emacs, I never had wrist problems, but I did end up developing pinky problems, due to remapping Ctrl to Caps Lock. I tried foot pedals (and still have them under my desk). They were better than nothing, but after I switched to the Kinesis Advantage keyboard I ended up not using them anymore. Hitting Ctrl+Alt with your thumbs is more convenient than hitting them with your feet, especially since I ten…

I use my thumbs for control and alt on a regular (scissor type) keyboard. I remap alt to control and super to alt and have had no problem since I switched, about 4 or 5 years ago.

That's a good idea.

Re: Learn Emacs Lisp in 15 minutes

#48
post #5

Basic Emacs lisp is well worth learning. It takes Emacs from being an editor to being your editor. With something like Eclipse, even adding a little bit of functionality is an undertaking. You have to create a project, write a bunch of boilerplate, load it and so on. With Emacs, it's basically effortless: a line or two of elisp can do wonders. Sometimes I add functionality by just executing elisp directly (with M-:),…

This is why I'm eagerly watching Light Table releases waiting for the "good enough" moment. It's going to have the advantages you mentioned, except in Clojure(script), which is, er, more broadly applicable. The GUI being bog-standard Webkit is another major plus. Emacs has had an astonishing run but is just slightly too opinionated for me to have taken the plunge. The promise of light table has kept me working in sub…

Clooj > Light Table, IMO. Catnip is good too.

Re: Learn Emacs Lisp in 15 minutes

#49

If you don't know Emacs Lisp, there's no point of using Emacs. You'd probably be more productive in Vim or [insert favorite proprietary editor here]. Emacs Lisp is probably the most featureless language you can think of; it doesn't even do basic threading and the async stuff is a joke. All the major programming language modes are implemented as ad-hoc Elisp regexp parsers making bugs impossible to fix. Virtually _eve…

Try textadept! It is structured in a way similar to Emacs: small core in C, most functionality written in Lua. In my opnion the only thing better about Elisp than Lua is that it has macros, everything else, from scoping to speed and coroutines is probably better in Lua. And the icing on the cake? The parsers use LPEG grammars and not regex!

Of course there is a downside: it has a tiny fraction of Emacs's functionality (even without considering non-default Emacs packages!), but it mostly has the fraction I use and is simpler enough than Emacs that I am more likely to extend it than Emacs.

(If you already knew about textadept but don't consider it a "programmable text editor", please let me know why.)

Re: Learn Emacs Lisp in 15 minutes

#50
post #34

If you don't know Emacs Lisp, there's no point of using Emacs. You'd probably be more productive in Vim or [insert favorite proprietary editor here]. Emacs Lisp is probably the most featureless language you can think of; it doesn't even do basic threading and the async stuff is a joke. All the major programming language modes are implemented as ad-hoc Elisp regexp parsers making bugs impossible to fix. Virtually _eve…

I always get a chuckle out of people complaining that Emacs is too slow. Maybe I've just "gotten used to it", but when I first started using it I was sharing a Sun 3 with ten or fifteen other people. I'd also argue that modes in other editors are ad hoc regexp parsers in some other form... regexps, in the hands of someone who knows what they're doing, work well. And yes, virtually everything is implemented in Emacs L…

There are definitely other programmable text editors available. I use Textadept, which is like Emacs with Lua and minimalism instead of Elisp and evrything-but-the-kitchen-sinkness. Of course it doesn't do nearly all that Emacs does but it feels as programmable to me.
Post reply on HN