Baike.dev
All toolsOnline toolsAI codingTrendingOpen sourceNewsSubmit
Log in
< Back to tools
H

homebrew-emacs-head

> 数据库
Open source

GNU Emacs formula for the Homebrew package manager

305 stars0 likes3 views
WebsiteGitHub

About

GNU Emacs formula for the Homebrew package manager

#+begin_html

Emacs Head

#+end_html

Emacs Head is an Homebrew Formula based on the original Homebrew Emacs [[https://github.com/Homebrew/homebrew-core/blob/master/Formula/emacs.rb][one]].

This formula currently supports:

  • GNU Emacs 26.3
  • GNU Emacs 27.2 (or emacs-27 branch)
  • GNU Emacs 28.2 (or emacs-28 branch)
  • GNU Emacs 29.4 (or emacs-29 branch)
  • GNU Emacs 30.2 (or emacs-30 branch)
  • GNU Emacs 31.1 (or emacs-31 branch)
  • GNU Emacs HEAD (currently 32.0.50)

** Installation You can install this formula using:

*** GNU Emacs 26 #+begin_src bash brew tap daviderestivo/emacs-head brew install emacs-head@26 --with-cocoa #+end_src

If you wish to install the latest commit of the emacs-26 branch then:

#+begin_src bash brew tap daviderestivo/emacs-head brew install --HEAD emacs-head@26 --with-cocoa #+end_src

*** GNU Emacs 27 #+begin_src bash brew tap daviderestivo/emacs-head brew install emacs-head@27 --with-cocoa #+end_src

If you wish to install the latest commit of the emacs-27 branch then:

#+begin_src bash brew tap daviderestivo/emacs-head brew install --HEAD emacs-head@27 --with-cocoa #+end_src

*** GNU Emacs 28 #+begin_src bash brew tap daviderestivo/emacs-head brew install emacs-head@28 --with-cocoa #+end_src

If you wish to install the latest commit of the emacs-28 branch then:

#+begin_src bash brew tap daviderestivo/emacs-head brew install --HEAD emacs-head@28 --with-cocoa #+end_src

*** GNU Emacs 29 #+begin_src bash brew tap daviderestivo/emacs-head brew install emacs-head@29 --with-cocoa #+end_src

If you wish to install the latest commit of the emacs-29 branch then:

#+begin_src bash brew tap daviderestivo/emacs-head brew install --HEAD emacs-head@29 --with-cocoa #+end_src

*** GNU Emacs 30 #+begin_src bash brew tap daviderestivo/emacs-head brew install emacs-head@30 --with-cocoa #+end_src

If you wish to install the latest commit of the emacs-30 branch then:

#+begin_src bash brew tap daviderestivo/emacs-head brew install --HEAD emacs-head --with-cocoa #+end_src

*** GNU Emacs 31 (default) #+begin_src bash brew tap daviderestivo/emacs-head brew install emacs-head --with-cocoa #+end_src

*** GNU Emacs 32 #+begin_src bash brew tap daviderestivo/emacs-head brew install emacs-head@32 --with-cocoa #+end_src

** Screenshots *** GNU Emacs running in terminal mode (28.x) [[/images/emacs-head-terminal.png]]

*** GNU Emacs running in GUI mode (28.x) GUI Theme: [[https://github.com/jonathanchu/atom-one-dark-theme][atom-one-dark-theme]]

Modeline Theme: [[https://github.com/daviderestivo/smart-mode-line-atom-one-dark-theme][smart-mode-line-atom-one-dark-theme]]

[[/images/emacs-head-cocoa.png]]

** Compilation options The following compilation options are available:

| Option | Description | |-------------------------+---------------------------------------------------------------------------------------------------------------| | --with-crash-debug | Append -g3 to CFLAGS to enable crash debugging | | --with-cocoa | Build a cocoa version of GNU Emacs | | --with-ctags | Don't remove the ctags executable that GNU Emacs provides (not available on emcas-head >=31) | | --with-dbus | Build with dbus support | | --without-gnutls | Disable gnutls support | | --with-imagemagick | Build with imagemagick support | | --without-librsvg | Disable librsvg support | | --with-mailutils | Build with mailutils support | | --with-multicolor-fonts | Enable multicolor fonts support on macOS (only on emacs-head@26) | | --without-modules | Disable dynamic modules support | | --with-no-frame-refocus | Disables frame re-focus (ie. closing one frame does not refocus another one). Not required in emacs-head >=30 | | --without-libxml2 | Disable libxml2 support | | --with-pdumper | Enable pdumper support (not available on emacs-head@26) | | --with-xwidgets | Enable xwidgets support (not available on emacs-head@26) | | --with-native-comp | Enable elisp native compilation support (not available on emacs-head@26 and emacs-head@27) | | --with-native-full-aot | Enable elisp ahead-of-time native compilation support (not available on emacs-head@26 and emacs-head@27) | | --with-tree-sitter | Enable Tree-sitter support (only on emacs-head >=29) | | --with-mps | Use the Memory Pool System garbage collection library (only on emacs-head@32) |

For the terminal version only of GNU Emacs please omit --with-cocoa.

By default:

  • gnutls
  • librsvg
  • libxml2
  • dynamic modules

are enabled. If you want to disable them please use the above --without-* options.

** System appearance change support This patch is enabled by default and can’t be disabled. It adds a hook, ns-system-appearance-change-functions, that is called once the [[https://support.apple.com/en-gb/guide/mac-help/mchl52e1c2d2/mac][system appearance]] is changed. Functions added to this hook will be called with one argument, a symbol that is either light or dark. This mainly allows loading a different theme to better match the system appearance.

#+begin_src elisp (defun my/apply-theme (appearance) "Load theme, taking current system APPEARANCE into consideration." (mapc #'disable-theme custom-enabled-themes) (pcase appearance ('light (load-theme 'tango t)) ('dark (load-theme 'tango-dark t))))

(add-hook 'ns-system-appearance-change-functions #'my/apply-theme) #+end_src

Note that this hook is also run once when Emacs is initialized, so simply adding the above to your init.el will allow matching the system appearance upon startup. You can also determine what the current system appearance is by inspecting the value of the ns-system-appearance variable.

The hook is NOT run in TTY Emacs sessions.

** Pdumper support Note: portable dumper is not supported on emacs-head@26, and won't work with native-comp support.

To enable this feature please use --with-pdumper.

For a pdumper configuration example, you could take inspiration from [[https://github.com/daviderestivo/galactic-emacs][Galactic Emacs]]: [[https://github.com/daviderestivo/galactic-emacs/blob/master/conf/pdumper-init.el][pdumper-init.el]] and [[https://github.com/daviderestivo/galactic-emacs/blob/master/conf/pdumper-config.el][pdumper-config.el]] configuration files.

** Xwidgets support Note: xwidgets feature is not supported on emacs-head@26.

This formula supports native macOS X Cocoa Xwidgets via embedding a native webkit window. To enable this feature please use --with-xwidgets.

** Native-comp support Note: native-comp feature is not supported on emacs-head@26 and emacs-head@27.

This formula supports native Elisp code compilation. In order to enable it please follow the below instructions:

#+begin_src bash brew install emacs-head@28 --with-cocoa --with-native-comp #+end_src

NATIVE_FULL_AOT is disabled by default to improve build time. Only few lisp source files will be compiled during the build, all of the remaining ones will be dynamically compiled in the background once the Emacs application is launched for the first time. If you wish to enable native full AoT, please use --with-native-full-aot option together with --with-native-comp.

More details about native Elisp code compilation can be found in the below links:

  • [[https://european-lisp-symposium.org/static/2020/corallo-nassi-manca-slides.pdf][Bringing GNU Emacs to Native Code (Slides)]]
  • [[https://www.youtube.com/watch?v=zKHYZOAc_bQ&app=desktop][Bringing GNU Emacs to Native Code (YouTube Video)]]
  • [[http://akrl.sdf.org/gccemacs.html][gccemacs]]

Additional useful links:

  • [[https://gist.github.com/AllenDang/f019593e65572a8e0aefc96058a2d23e][Use pre-built gccemacs]]
  • [[https://github.com/jimeh/build-emacs-for-macos][build-emacs-for-macos]]
  • [[https://github.com/shshkn/emacs.d/blob/master/docs/nativecomp.md][gccemacs]]
  • [[https://gist.github.com/mikroskeem/0a5c909c1880408adf732ceba6d3f9ab][gccemacs on OS X]]

** MPS garbage collector Note: MPS is only supported on emacs-head@32

This formula supports the MPS garbage collector which theoretically can improve performance. It is a stable system that has been in use for years. However, in emacs this is an experimental feature.

More details about MPS can be found in the below links:

  • [[https://www.ravenbrook.com/project/mps/][Memory Pool System]]
  • [[https://github.com/Ravenbrook/mps][MPS on GitHub]]
  • [[https://memory-pool-system.readthedocs.io/en/latest/index.html][MPS docs]]

** Available icons | Option | Description | Image | macOS 26+ Ready (*) | URL | |----------------------------------------------------+----------------------------------------------------------+-----------------------------------------------------------------+---------------------+------| | --with-modern-icon | Use a modern style icon by Unknown | [[/icons/previews/modern-icon.png]] | No | - | | --with-modern-icon-sjrmanning | Use a modern style icon by [[https://github.com/sjrmanning][Sjrmannings]] | [[/icons/previews/modern-icon-sjrmanning.png]] | No | [[https://github.com/sjrmanning/emacs-icon][Link]] | | --with-modern-icon-asingh4242 | Use a modern style icon by [[https://imgur.com/user/asingh4242][Asingh4242]] | [[/icons/previews/modern-icon-asingh4242.png]] | No | [[https://imgur.com/YGxjLZw][Link]] | | --with-modern-icon-paper-icons | Use a modern style icon by [[https://github.com/snwh][Sam Hewitt]] | [[/icons/previews/modern-icon-paper-icons.png]] | No | [[https://github.com/snwh/paper-icon-theme/blob/master/Paper/512x512/apps/emacs.png][Link]] | | --with-modern-icon-azhilin | Use a modern style icon by Andrew Zhilin | [[/icons/previews/modern-icon-azhilin.png]] | No | [[https://commons.wikimedia.org/wiki/File:Emacs-icon-48x48.png][Link]] | | --with-modern-icon-mzaplotnik | Use a modern style icon by [[https://commons.wikimedia.org/wiki/User:MZaplotnik][Matjaz Zaplotnik]] | [[/icons/previews/modern-icon-mzaplotnik.png]] | No | [[https://commons.wikimedia.org/wiki/File:Emacs-icon-48x48.svg][Link]] | | --with-modern-icon-bananxan | Use a modern style icon by [[https://www.deviantart.com/bananxan]

Issues· 1 open

View all issuesOpen on GitHub

No open issues yet, or sync has not completed.

> Tags

Rubyemacshomebrewhomebrew-formulahomebrew-tap

No comments yet. Be the first to share.

> Details

PublishedAug 1, 2026
UpdatedSep 18, 2026
Category数据库
PricingOpen source

> Related tools

P
PostgreSQL
功能强大的开源关系型数据库
R
Redis
内存数据结构存储,常用作缓存与队列
M
MySQL
广泛使用的开源关系型数据库