Skip to main content

55.1 Coding Standards

Contributed code should follow the GNU Coding Standards. This manual is available online at https://www.gnu.org/prep/standards/. It may also be available locally in Info on your system, see see GNU Coding Standards.

If it doesn't, we'll need to find someone to fix the code before we can use it.

Emacs has additional style and coding conventions:

  • the "Tips and Conventions" Appendix in the Emacs Lisp Reference https://www.gnu.org/software/emacs/manual/html_node/elisp/Tips.html.
  • Avoid using advice-add or with-eval-after-load for Lisp code to be included in Emacs.
  • Remove all trailing whitespace in all source and text files.
  • Use ?\s instead of ? in Lisp code for a space character.