reddit / emacs
Learning eLisp
EnoughUnit5 · 2022-02-18 14:40
Hello! I'm finally starting to consider learning eLisp in a more structured way than I've done before (which was copying & pasting snippets from the web, then guesstimating the syntax from there to get done what I'm looking for).
I tried Udemy, but there doesn't seem to be anything useful on there.
I am rather limited in terms of free time, having young children and a busy career.
Can someone on here please recommend a way for me to make progress with learning eLisp from nearly scratch?
I have a few years of Java experience, so am well familiar with basic concepts.
rman666 · 2022-02-18 14:59
There are many Lisp tutorials, articles, and books. Much of that content should be applicable for starters.
BobKoss · 2022-02-18 15:33
There’s a free ebook for beginner lisp. If you can’t find it let me know and I’ll dig for the link.
I think it might be available as Info from within emacs. But the pdf let’s you put it in your phone and read when time allows.
averageLinuxJoe · 2022-02-18 16:20
Obviously I‘m not the OP, but I would also be interested in this, if it‘s not too much work for you to find it again?
BobKoss · 2022-02-18 16:28
https://www.gnu.org/software/emacs/manual/pdf/eintr.pdf
BobKoss · 2022-02-18 16:29
https://www.gnu.org/software/emacs/manual/pdf/eintr.pdf
averageLinuxJoe · 2022-02-18 16:29
Thank you!
00-11 · 2022-02-18 17:38
Emacs Wiki resources page for [Learning Elisp](https://www.emacswiki.org/emacs/LearnEmacsLisp).
Know that Elisp is Lisp. As others have said, there are lots of introductions to Lisp.
For Elisp in particular, ***ask Emacs***: `C-h i m intro TAB RET`.
ftrx · 2022-02-18 18:03
I'm not really an elisper (nor a lisper) and I also struggling a bit to find good docs... For lisp (and so ALSO valid for elisp) I find Practical Common Lisp by Peter Seibel a very good intro that start soft and go a bit more then the mere basics, for elisp specifically IMVHO the issue is a bit like learning Java BUT not it's ecosystem.
If you do know the language but not the big load of packages ending up re-implementing anything or looking around for "a damn already-made function do do that", well... That's not much nice. With a good lisp introductory book, even if CL focused you learn enough of the language, quickly IME, but you will be still a bit unable to do anything because you do not know the environment/"standard library"/"framework"/ecosystem/"the nexus/the vault of parnassus/the C*AN". For that the sole nice book I found, unfortunately ebook only, is Mastering Emacs by Mickey Petersen. It does not focus much on programming but give enough information to knowing where to look for, and the rest arrive practicing a problem to be solved at a time.
Unfortunately while Emacs do have an *excellent* doc access system it's documented content for new users, available books etc are IMO really lacking...
arthurno1 · 2022-02-18 18:54
It is included with your Emacs too! Press C-h i and from the contents choose "Emacs Lisp Intro". Hmm, is that a coincidence its acronym, ELI, form a maintainers name, /u/eli-zaretskii :-) ?
brotzeitmacher · 2022-02-18 22:49
What's your goal ? Do you want to write a package or just understand what you are copy and pasting ?
dzecniv · 2022-02-18 23:21
> Udemy
Glad you mention it, [I'm creating a course for Common Lisp](https://www.udemy.com/course/common-lisp-programming/?couponCode=6926D599AA-LISP4ALL). You'll learn a bunch (well hopefully!) but, unfortunately, it doesn't translate entirely to Elisp. You can transpose easily: syntax and evaluation model (introduction), closures, conditionals, and the rest won't transpose perfectly. Of course CL is great and is a "real world lisp", so it can't harm to know it. Of course it doesn't teach Emacs internals.
*ps: students: send me an email for a free link*
*pps: I consider the course half done. I'm happy with what's here and I'll welcome any feedback!*
Qwarctick · 2022-02-18 23:28
I highly recommand https://emacsdocs.org/. It's the emacs doc but with a better interaction
[deleted] · 2022-02-19 00:07
[deleted]
verticaleyes · 2022-02-19 02:57
Exercism helped me a lot. Maybe give it
a spot
AuroraDraco · 2022-02-19 10:02
Eintr is 100% the book to look at. C-h i to go to info and search for Emacs Lisp Intro and you will find it. Probably the best resource out there to get you started
EnoughUnit5 · 2022-02-19 10:21
Writing a package is too ambitious for me. I want to be able to understand enough to be able to create those small snippets that do useful, custom things - that I can add into my emacs config (e.g. to get org capture to stick a link into the resulting TODO under some circumstances, but not others. Emacs makes me faster and more productive - being able to add small tweaks can grease the gears nicely.
EnoughUnit5 · 2022-02-19 10:33
Weird, I don't seem able to find it in there. Got the PDF though, that will do the trick for me.
[deleted] · 2022-02-19 11:08
+1
behaghel · 2022-02-19 11:30
I found it useful: https://exercism.org/tracks/elisp/exercises
EnoughUnit5 · 2022-02-19 19:47
Looks great! Thank you, I'll definitely check this out in more detail
EnoughUnit5 · 2022-02-19 19:49
Yikes! Wish I had found this a long time ago. This looks brilliant, thanks.
brotzeitmacher · 2022-02-20 17:20
You should use commands like apropos to find documentation and xref-find-references to see how functions are used in other places. At least that's what still helps me a lot. I can also recommend to keep your config as org-mode file which helps you with documenting and organizing your snippets.