Hot answers tagged

198 votes

How to Restore File System Access in macOS Catalina actually launches using a ruby script. As a result, MacOS Catalina (or later, up to at least Ventura) uses the permissions set for ruby, not the permissions for Open General ...
Chris's user avatar
  • 1,996
45 votes

set-mark-command (C-SPC) not recognised/broken

System Preferences > Keyboard > Shortcuts > Input Sources > Select the previous input source and uncheck saltycraig's tip on C-h k C-SPC did nothing when I typed it. So, thanks to Kaushal Modi for ...
m__'s user avatar
  • 953
38 votes

Copy text from Emacs to OS X clipboard

Copy from Emacs to OS X clipboard: select region then M-| pbcopy RET Paste from OS X clipboard to Emacs: C-u M-| pbpaste RET (replaces current region if it exists) Explanation: M-| runs shell-...
Andrei Simionescu's user avatar
33 votes

How to start Emacs from the Terminal window as a GUI application (macOS)

According to Emacswiki "Homebrew has Emacs 26.1 as of January 2019" and "Homebrew now recommends to use the cask version". The message that Homebrew gives is "Please try the ...
ayckoster's user avatar
  • 439
26 votes

Using conda environments in emacs

I'd suggest using pyvenv library, it provides a neat interface to selecting a virtual env among several alternatives updating interpreter and library paths. You will need to alter WORKON_HOME variable ...
immerrr's user avatar
  • 564
20 votes

Failed to download 'gnu' archive

Add the following before package-initialize: (setq gnutls-algorithm-priority "NORMAL:-VERS-TLS1.3") This is apparently a bug in Emacs 26.2 for MacOS. I found this solution in this reddit thread.
gguy's user avatar
  • 301
17 votes

how install emacs 26 (or whatever latest ver) on mac

Have a look at brew emacs recipe options with brew info emacs. It has this option: --devel Install development version 26.0.90 To replace your current emacs, run: brew unlink emacs brew ...
Heikki's user avatar
  • 3,056
16 votes

OS X emacs: difference between X11 vs NS vs Cocoa?

There are a number of Emacs versions for macOS, including: The official Emacs on macOS is build using the "NS" port, also known as the "cocoa" port. As the name suggests, this port of Emacs ...
Lindydancer's user avatar
  • 6,115
16 votes

How to remove the icon in the titlebar?

In emacs 26 you can set ns-use-proxy-icon (setq ns-use-proxy-icon nil) I was able to get a completely "clean" transparent title bar: Download emacs 26 for mac, add the following config to your ....
Muir's user avatar
  • 321
15 votes

emacs on terminal does not recognise option as alt-key on mac

I solve the problem with answer of ohruunuruus. Maybe post a snapshot will be more easy to understand.
Jason Zhou's user avatar
14 votes

Install Pdf-Tools on Emacs MacOSX

For me, as of April 13, 2017, a reliable way to install pdf-tools on OS X (Mavericks/Sierra) is to use the following pdf-tools config and directions (in the comments): ;;; Install epdfinfo via 'brew ...
Joe's user avatar
  • 551
14 votes

Emacs 28.2 error in macOS Ventura: `image-type: Invalid image type ‘svg’`

This is an issue with the way Emacs initializes its image support on macOS Ventura. It's fixed on the current master branch, and will be in Emacs 29 when that is released. See
rpluim's user avatar
  • 5,160
13 votes

Why can't I list the contents of Desktop on macos using dired?

If you find the problem persists after granting Emacs full disk access: from here on the problem remains because Emacs on MacOS gets launched indirectly, from a Ruby script. Your Emacs binary has full ...
dns's user avatar
  • 131
12 votes

How to Restore File System Access in macOS Catalina

@Chris's answer also resolves a different problem for me (which had the same root cause): I'm recording it here to make this answer more findable. I was getting the error "Listing directory failed ...
Sboisen's user avatar
  • 151
12 votes

Finder of MacOS Catalina cannot open a file with Emacs

If your Emacs is downloaded from, launches a binary via a ruby script Modify ...
Akira Kitauchi's user avatar
11 votes

For MacOS: how to bind left and right option keys separately?

You're almost there. By default, the ns-XXXXX-modifier variables affect both the left and right versions of the key. However, you can change the right one with ns-right-XXXXX-modifier. So: to set ...
Dan's user avatar
  • 32.9k
11 votes

Emacs 28.2 error in macOS Ventura: `image-type: Invalid image type ‘svg’`

I tried a little workaround to see if it works - overriding image-type-available-p like this: ;; overriding image.el function image-type-available-p (defun image-type-available-p (type) "Return ...
Tariq Rauf's user avatar
10 votes

Cocoa Emacs 24.5 Font Issues (Inconsolata-dz)

Emacs doesn't allow fonts that have hyphens in them. I would rename the font to something that doesn't contain hyphens. You can do this using ttx. For example, assuming you have a font named ...
sid-kap's user avatar
  • 544
10 votes

how install emacs 26 (or whatever latest ver) on mac

A current (at time of this comment) way to install the GUI version of Emacs (26.2 at this time) on macOS Mojave is with brew cask install emacs This will install package in to /...
Michael Teter's user avatar
9 votes

How do I use Mac/OSX key bindings with Spacemacs?

Spacemacs has a "layer" called "osx" that should do everything you want. Just put osx in the dotspacemacs-configuration-layers ...
mclear's user avatar
  • 1,535
9 votes

Emacs 28.2 error in macOS Ventura: `image-type: Invalid image type ‘svg’`

This seems to only happen when you have an .emacs file. I too just installed Emacs with brew install --cask emacs and it was working fine until I added an .emacs file. (I compulsively disable tool-bar-...
tripleee's user avatar
  • 261
8 votes

How to set up elpy to use python3?

You can solve this by modifying the python shell configuration from python to python3 in elpy-config M-x elpy-config to enter the configuration page of elpy if you scroll down you will see groups ...
oksuzgonul's user avatar
8 votes

How can I retrieve an HTTPS URL on Mac OS X without warnings about an untrusted authority?

Add /private/etc/ssl/cert.pem to gnutls-trustfiles: M-x customize-variable Customize variable: gnutls-trustfiles Select the last [INS] Bundle filename: /private/etc/ssl/cert.pem Select [ Apply and ...
Daniel Le's user avatar
  • 181
8 votes

Using conda environments in emacs

I have recently incorporated Anaconda into my python development and was having similar problems setting up Emacs + flycheck + linters. This answer got me up and running, but I've modified it, since ...
Jim Parker's user avatar
8 votes

Emacs does not contain package "package"

OS-X comes with emacs 22, which is several years out of date. One easy way to get a current emacs is by downloading from This will give you package.
Jon Kåre Hellan's user avatar
8 votes

OSX: Switching to virtual desktop doesn't focus Emacs

The behavior you described is specific to Emacs Mac port and can be observed when the menu bar is globally disabled. Enabling it should make Emacs behave like other applications on OS X. I emailed ...
Emre Yolcu's user avatar
8 votes

How to sort directories first in dired?

As @lawlist mentioned, you need to install coreutils as the ls command which ships with mac does not have the option to sort directories first. If you have homebrew, you could just type brew install ...
Chakravarthy Raghunandan's user avatar
8 votes

How to sort directories first in dired?

Use standard Emacs library ls-lisp. (require 'ls-lisp) Customize these two user options (you can just use setq to set them in your init file, if you prefer): ls-lisp-dirs-first to t ls-lisp-use-...
Drew's user avatar
  • 77k

Only top scored, non community-wiki answers of a minimum length are eligible