* Learn Emacs Lisp in 15 minutes
@ 2013-07-25 12:36 Bastien
2013-07-25 13:53 ` Thorsten Jolitz
2013-07-25 15:19 ` Kevin Montuori
0 siblings, 2 replies; 10+ messages in thread
From: Bastien @ 2013-07-25 12:36 UTC (permalink / raw
To: help-gnu-emacs
Mandatory reading:
http://norvig.com/21-days.html
Now here is my attempt at playing the "15 minutes" game:
http://bzg.fr/learn-emacs-lisp-in-15-minutes.html
Hope this will make its way to:
http://learnxinyminutes.com/
Comments and feedback welcome, enjoy,
--
Bastien
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Learn Emacs Lisp in 15 minutes
[not found] <mailman.1755.1374756308.12400.help-gnu-emacs@gnu.org>
@ 2013-07-25 13:41 ` Rustom Mody
2013-07-25 14:38 ` Bastien
2013-07-25 15:48 ` notbob
1 sibling, 1 reply; 10+ messages in thread
From: Rustom Mody @ 2013-07-25 13:41 UTC (permalink / raw
To: help-gnu-emacs
On Thursday, July 25, 2013 6:06:01 PM UTC+5:30, Bastien wrote:
> Now here is my attempt at playing the "15 minutes" game:
> http://bzg.fr/learn-emacs-lisp-in-15-minutes.html
Neat! I learnt something -- C-j (always used M-C-x so far)
Now learn elisp in 15 minutes is really too ambitious for me to tackle leave aside improve upon. However Ive one general comment:
Elisp is 2 things:
1. A scripting framework for the emacs editor
2. A full-scale (turing complete) programming language
Your intro emphasises 1 more than 2.
How to balance more and yet stay within the 15 minutes constraint...
Well dunno... :-)
If I think of something I'll tell
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Learn Emacs Lisp in 15 minutes
2013-07-25 12:36 Learn Emacs Lisp in 15 minutes Bastien
@ 2013-07-25 13:53 ` Thorsten Jolitz
2013-07-25 15:19 ` Kevin Montuori
1 sibling, 0 replies; 10+ messages in thread
From: Thorsten Jolitz @ 2013-07-25 13:53 UTC (permalink / raw
To: help-gnu-emacs
Bastien <bzg@altern.org> writes:
> Now here is my attempt at playing the "15 minutes" game:
> http://bzg.fr/learn-emacs-lisp-in-15-minutes.html
Nice job. How easy it is to achieve many things in interpreted (Emacs)
Lisp compared to (e.g.) Java.
--
cheers,
Thorsten
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Learn Emacs Lisp in 15 minutes
2013-07-25 13:41 ` Rustom Mody
@ 2013-07-25 14:38 ` Bastien
0 siblings, 0 replies; 10+ messages in thread
From: Bastien @ 2013-07-25 14:38 UTC (permalink / raw
To: Rustom Mody; +Cc: help-gnu-emacs
Hi Rustom,
Rustom Mody <rustompmody@gmail.com> writes:
> Elisp is 2 things:
> 1. A scripting framework for the emacs editor
> 2. A full-scale (turing complete) programming language
>
> Your intro emphasises 1 more than 2.
Agreed -- the tutorial targets new potential users, and even
non-computer folks. (I wrote it first for a friend who wants
to learn programming, but does not know where to start.)
I'm not sure a non-computer guy/girl can really make sense of
the difference you point, although I acknowledge i's important.
Dunno.
> How to balance more and yet stay within the 15 minutes constraint...
> Well dunno... :-)
> If I think of something I'll tell
Thanks so far!
--
Bastien
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Learn Emacs Lisp in 15 minutes
2013-07-25 12:36 Learn Emacs Lisp in 15 minutes Bastien
2013-07-25 13:53 ` Thorsten Jolitz
@ 2013-07-25 15:19 ` Kevin Montuori
2013-07-25 20:25 ` Bastien
1 sibling, 1 reply; 10+ messages in thread
From: Kevin Montuori @ 2013-07-25 15:19 UTC (permalink / raw
To: help-gnu-emacs
>>>>> "B" == Bastien <bzg@altern.org> writes:
B> Comments and feedback welcome, enjoy,
Nicely done, I'm sure more than a few people will find it helpful.
A few comments:
- A link to "An Introduction to Programming in Emacs Lisp" might prove
handy for continuing on: http://tinyurl.com/lanbfyv
- The paragraph beginning with "This set of command is loaded on
top..." is confusing. I'd be tempted to make it way simpler:
Emacs has a built-in set of functions (or commands); you use these
built-in functions as building blocks for custom functions.
- I'd point out that every sexp returns a value and some sexps produce
side effects -- and explain the difference between a value and side
effect.
Stupid as it sounds, I'd mention to your friend that you can't break a
computer by mis-programming it (and that most programmers spend their
time fixing code that's broken to some degree, not writing perfect code
out of the gate). This is less obvious to non-programmers than I would
have suspected.
k.
--
Kevin Montuori
montuori@gmail.com
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Learn Emacs Lisp in 15 minutes
[not found] <mailman.1755.1374756308.12400.help-gnu-emacs@gnu.org>
2013-07-25 13:41 ` Rustom Mody
@ 2013-07-25 15:48 ` notbob
2013-07-25 20:23 ` Bastien
1 sibling, 1 reply; 10+ messages in thread
From: notbob @ 2013-07-25 15:48 UTC (permalink / raw
To: help-gnu-emacs
On 2013-07-25, Bastien <bzg@altern.org> wrote:
>
> Now here is my attempt at playing the "15 minutes" game:
> http://bzg.fr/learn-emacs-lisp-in-15-minutes.html
> Comments and feedback welcome, enjoy,
I'm at 15 mins and still only half way! ('course I'm dumb as a stump)
";; Use the mouse to go back to the window where you code."
Doesn't work for me. Using emacs 23.3, but C-x o does the trick.
OK, I'm at 30 mins and have found another mistake. You instruct:
"
;; Now if you don't mind, I'll stop asking you to hit `C-xC-e': do it
;; for every sexp that follows.
;; It's often useful to erase the buffer:
"
But, you forgot to instruct to return to scratch buffer. So,
entering code in test buffer turn scratch buffer into test buffer, of
which I now have two test buffers which do the same thing.
This is not a gotchya, jes a example of every programming howto I've
ever read. Somewhere, the author always makes a mistake and then I'm
left confused and lost. Sorry, but the syntax must be perfect and
explained in detail and typically, it is not. Otherwise, I like your
little tutorial. In yer favor, I learned more in 30 mins than all
previous LISP lessons, including emacs' own. I'll finish it and
bookmark it. Also, I hate coding. I'll never be a programmer and
have no desire to be, but love linux and know I must learn some code.
I also love emacs and try to learn something new every day. In that,
you have succeeded brilliantly. Thank you. ;)
BTW. emacs 23.3 does not open to scratch buffer.
nb
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Learn Emacs Lisp in 15 minutes
2013-07-25 15:48 ` notbob
@ 2013-07-25 20:23 ` Bastien
2013-07-26 13:38 ` Stefan Monnier
0 siblings, 1 reply; 10+ messages in thread
From: Bastien @ 2013-07-25 20:23 UTC (permalink / raw
To: notbob; +Cc: help-gnu-emacs
notbob <notbob@nothome.com> writes:
> On 2013-07-25, Bastien <bzg@altern.org> wrote:
>>
>> Now here is my attempt at playing the "15 minutes" game:
>> http://bzg.fr/learn-emacs-lisp-in-15-minutes.html
>
>> Comments and feedback welcome, enjoy,
>
> I'm at 15 mins and still only half way! ('course I'm dumb as a
> stump)
Well, my bad I guess :/
> ";; Use the mouse to go back to the window where you code."
>
> Doesn't work for me. Using emacs 23.3, but C-x o does the trick.
I fixed this by mentioning C-xo and _clicking_ on the window (not only
hovering over it.)
> OK, I'm at 30 mins and have found another mistake. You instruct:
>
> "
> ;; Now if you don't mind, I'll stop asking you to hit `C-xC-e': do it
> ;; for every sexp that follows.
>
> ;; It's often useful to erase the buffer:
> "
>
> But, you forgot to instruct to return to scratch buffer. So,
> entering code in test buffer turn scratch buffer into test buffer, of
> which I now have two test buffers which do the same thing.
Good catch! Fixed.
> This is not a gotchya, jes a example of every programming howto I've
> ever read. Somewhere, the author always makes a mistake and then I'm
> left confused and lost.
Been there too.
> Sorry, but the syntax must be perfect and
> explained in detail and typically, it is not.
It's hard to find the right trade-off: I cannot go into too much
details about variables, dynamic variables, etc.
> Otherwise, I like your
> little tutorial. In yer favor, I learned more in 30 mins than all
> previous LISP lessons, including emacs' own. I'll finish it and
> bookmark it. Also, I hate coding. I'll never be a programmer and
> have no desire to be, but love linux and know I must learn some code.
> I also love emacs and try to learn something new every day. In that,
> you have succeeded brilliantly. Thank you. ;)
Glad this was useful, even in some (yet?) unpredictable ways!
> BTW. emacs 23.3 does not open to scratch buffer.
Oh, you're right too here, fixed by suggesting to hit `q' to escape
the first welcome window.
Thanks for the comments!
--
Bastien
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Learn Emacs Lisp in 15 minutes
2013-07-25 15:19 ` Kevin Montuori
@ 2013-07-25 20:25 ` Bastien
0 siblings, 0 replies; 10+ messages in thread
From: Bastien @ 2013-07-25 20:25 UTC (permalink / raw
To: Kevin Montuori; +Cc: help-gnu-emacs
Hi Kevin,
"Kevin Montuori" <montuori@gmail.com> writes:
> A few comments:
>
> - A link to "An Introduction to Programming in Emacs Lisp" might prove
> handy for continuing on: http://tinyurl.com/lanbfyv
Indeed, add at the end.
> - The paragraph beginning with "This set of command is loaded on
> top..." is confusing. I'd be tempted to make it way simpler:
>
> Emacs has a built-in set of functions (or commands); you use these
> built-in functions as building blocks for custom functions.
I rewrote it but slightly differently. Thanks for putting me on this
track anyway, let me know if it sounds clearer now.
> - I'd point out that every sexp returns a value and some sexps produce
> side effects -- and explain the difference between a value and side
> effect.
Mhhh... I added one little sentence, but I don't want to go too far
down that road. For example, I don't want to say that no-side-effect
functions are more "functional" than others -- because it sounds
jargonish for newcomers, and it does not really add to the
understanding of this little tutorial I think.
> Stupid as it sounds, I'd mention to your friend that you can't break a
> computer by mis-programming it (and that most programmers spend their
> time fixing code that's broken to some degree, not writing perfect code
> out of the gate). This is less obvious to non-programmers than I would
> have suspected.
How true. I added a notice, and a "thanks" section at the end!
Thanks,
--
Bastien
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Learn Emacs Lisp in 15 minutes
2013-07-25 20:23 ` Bastien
@ 2013-07-26 13:38 ` Stefan Monnier
2013-07-26 17:35 ` Bastien
0 siblings, 1 reply; 10+ messages in thread
From: Stefan Monnier @ 2013-07-26 13:38 UTC (permalink / raw
To: help-gnu-emacs
> It's hard to find the right trade-off: I cannot go into too much
> details about variables, dynamic variables, etc.
Indeed. One thing that might be worth squeezing in is some example of
C-h f <foo> and then click to get to the source.
Stefan
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Learn Emacs Lisp in 15 minutes
2013-07-26 13:38 ` Stefan Monnier
@ 2013-07-26 17:35 ` Bastien
0 siblings, 0 replies; 10+ messages in thread
From: Bastien @ 2013-07-26 17:35 UTC (permalink / raw
To: Stefan Monnier; +Cc: help-gnu-emacs
Stefan Monnier <monnier@iro.umontreal.ca> writes:
>> It's hard to find the right trade-off: I cannot go into too much
>> details about variables, dynamic variables, etc.
>
> Indeed. One thing that might be worth squeezing in is some example of
> C-h f <foo> and then click to get to the source.
Yes. The latest version contains this postamble:
;; If you want to know more about a variable or a function:
;;
;; C-h v a-variable RET
;; C-h f a-function RET
;;
;; To read the Emacs Lisp manual with Emacs:
;;
;; C-h i m elisp RET
;;
;; To read an online introduction to Emacs Lisp:
;;
;; https://www.gnu.org/software/emacs/manual/html_node/eintr/index.html
I guess it's already a lot.
(Several people said that such a hands on tutorial for writing a mode
would be handy. On my TODO list for the next two months.)
--
Bastien
^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2013-07-26 17:35 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-07-25 12:36 Learn Emacs Lisp in 15 minutes Bastien
2013-07-25 13:53 ` Thorsten Jolitz
2013-07-25 15:19 ` Kevin Montuori
2013-07-25 20:25 ` Bastien
[not found] <mailman.1755.1374756308.12400.help-gnu-emacs@gnu.org>
2013-07-25 13:41 ` Rustom Mody
2013-07-25 14:38 ` Bastien
2013-07-25 15:48 ` notbob
2013-07-25 20:23 ` Bastien
2013-07-26 13:38 ` Stefan Monnier
2013-07-26 17:35 ` Bastien
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.