All Projects → jtmoulia → Elisp Koans

jtmoulia / Elisp Koans

Licence: apache-2.0
Emacs Lisp Koans -- learn elisp through test-driven development.

Labels

Projects that are alternatives of or similar to Elisp Koans

Org Pandoc Import
Save yourself from non-org formats, thanks to pandoc
Stars: ✭ 111 (-9.76%)
Mutual labels:  emacs
Emacs Application Framework
A free/libre and open-source extensible framework that revolutionizes the graphical capabilities of Emacs, the key to ultimately Live in Emacs
Stars: ✭ 1,932 (+1470.73%)
Mutual labels:  emacs
Mg
Micro (GNU) Emacs-like text editor ❤️ public-domain
Stars: ✭ 117 (-4.88%)
Mutual labels:  emacs
Magit Delta
Use delta (https://github.com/dandavison/delta) when viewing diffs in Magit
Stars: ✭ 109 (-11.38%)
Mutual labels:  emacs
Dotfiles
If there is a shell, there is a way!
Stars: ✭ 112 (-8.94%)
Mutual labels:  emacs
Emacs Mini Frame
Show minibuffer in child frame on read-from-minibuffer
Stars: ✭ 115 (-6.5%)
Mutual labels:  emacs
Emacs Everywhere
System-wide popup Emacs windows for quick edits
Stars: ✭ 108 (-12.2%)
Mutual labels:  emacs
Novels.org
Novels.org - Your Novels in Plain Text (Emacs . org-mode)
Stars: ✭ 120 (-2.44%)
Mutual labels:  emacs
Fcitx.el
Better fcitx integration for Emacs.
Stars: ✭ 113 (-8.13%)
Mutual labels:  emacs
1pass
A caching wrapper for the 1Passworld CLI
Stars: ✭ 117 (-4.88%)
Mutual labels:  emacs
Emacs Doom Themes
A megapack of themes for GNU Emacs.
Stars: ✭ 1,706 (+1286.99%)
Mutual labels:  emacs
Burly.el
Save and restore frames and windows with their buffers in Emacs
Stars: ✭ 109 (-11.38%)
Mutual labels:  emacs
Cheatsheet
Pretty cheat sheets, or ``reference cards'', obtainable from Org files.
Stars: ✭ 116 (-5.69%)
Mutual labels:  emacs
Lsp Pyright
lsp-mode ❤️ pyright
Stars: ✭ 111 (-9.76%)
Mutual labels:  emacs
Emacs Gdb
GDB graphical interface for GNU Emacs
Stars: ✭ 119 (-3.25%)
Mutual labels:  emacs
Emacs Gtd
Get Things Done with Emacs
Stars: ✭ 111 (-9.76%)
Mutual labels:  emacs
Pocket Reader.el
Emacs client for Pocket reading list (getpocket.com)
Stars: ✭ 113 (-8.13%)
Mutual labels:  emacs
Emacs Solidity
The official solidity-mode for EMACS
Stars: ✭ 120 (-2.44%)
Mutual labels:  emacs
Walkman
Write HTTP requests in Org mode and replay them at will using cURL
Stars: ✭ 120 (-2.44%)
Mutual labels:  emacs
Doom Emacs
An Emacs framework for the stubborn martian hacker
Stars: ✭ 12,774 (+10285.37%)
Mutual labels:  emacs
  • elisp-koans

** What is elisp-koans?

=elisp-koans= helps you learn [[info:elisp:Introduction][Emacs Lisp]] (elisp) via test-driven development. You're provided with suites of tests describing the elisp syntax and environment. Fixing the tests leads you on a tutorial of elisp.

These koans are intended for those learning to code in Emacs Lisp and

  • customize Emacs. You should already be able to [[https://www.gnu.org/software/emacs/tour/][make your way around Emacs]] plus be able to [[https://www.gnu.org/software/emacs/manual/html_node/elisp/Interactive-Call.html][call interactive functions]], [[https://www.gnu.org/software/emacs/manual/html_node/emacs/Lisp-Eval.html][evaluate code in the buffer]], and [[https://www.gnu.org/software/emacs/manual/html_node/elisp/Help-Functions.html][look up documentation]].

** Usage

Create a clone of this repository:

#+BEGIN_SRC sh git clone https://github.com/jtmoulia/elisp-koans #+END_SRC

First load [[file:elisp-koans.el][elisp-koans.el]] by opening it in Emacs then running the interactive command =eval-buffer=.

Next open up [[file:koans/asserts.el::(elisp-koans/define-test][koans/asserts.el]] and navigate to the first test:

#+BEGIN_SRC emacs-lisp (elisp-koans/deftest elisp-koans/asserts-true () "t' is true. Replace the blank witht' to assert it is true" (should ___)) #+END_SRC

Fix the test by replacing the blank (=___=) with the appropriate value, in this case =t= as described in the docstring:

#+BEGIN_SRC emacs-lisp (should t) #+END_SRC

Once the test is fixed evaluate the test and then run it by calling =elisp-koans/run-test= and selecting the test: =elisp-koans/asserts-true=. ERT will run the test and report the result.

You're ready to move on to the remaining koans in =koans/asserts.el= and beyond. The variable =elisp-koans-groups= lists the remaining suites of koans which are ordered to provide a tour of Emacs Lisp. As you progress run all of the loaded koans by calling =elisp-koans/contemplate=, or a single test by calling =elisp-koans/run-test=.

** The Cheatsheet

You can check your answers against the cheatsheet, i.e. a branch called =cheatsheet= which has the koan solutions filled in. This branch is kept up to date by staying one commit ahead of =master=

** Credits

=elisp-koans= is adapted from Google's [[https://github.com/google/lisp-koans][Common Lisp Koans]], which was in turn inspired by the family of TDD Koans, e.g. [[http://rubykoans.com/][Ruby Koans]] and [[https://github.com/gregmalcolm/python_koans][Python Koans]].

** License

The Common Lisp Koan's were modified under the terms of the Apache License.

=elisp-koans= uses the [[file:LICENSE][Apache License]].

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].