-
-
Notifications
You must be signed in to change notification settings - Fork 171
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Permission issues with emacs-plus running as a service #304
Comments
I have the same problem when emacs-plus@27 is started with I should clarify that emacsclient is not able to access |
I have to confes. I never used Emacs in daemon mode, so I might be missing some crutial points to reproduce. Also, I am using
I just checked my privacy settings (System Preferences > Security & Privacy > Privacy) and see no Emacs mentioned in any of the areas (e.g. Full Disk Access, Files and Folders). What macOs version are you running on? |
I followed your steps exactly to try out Emacs-28 and it does not work here. I get |
@tom111 Ah, might be. I have disabled SIP completely (well, to the maximum extend):
Doing this because I use yabai as WM. Will check your links. |
For reference: My best workaround is to create a shell script somehwere that just runs |
I've played with this a bit (emacs-plus@27 on 10.15 Catalina) and noticed that for my iCloud Drive folders (Documents and Downloads):
This is after granting Full Disk Access to Emacs.app and all the bins (emacs, emacsclient as well as the Emacs in So the only issue I have is with the brew service version of the daemon - can't seem to grant full disk access to that but daemons started manually I'm able to get working by granting access to emacsclient etc. |
Yes, exactly. I tried to describe this in my original post. It seems to be the case that deamons started with |
I might have another workaround which changes the plist file used to launch the service like this:
Then I loaded this with After this I get those "Emacs.app would like to access files in your * folder" popup windows when opening them for the first time. Didn't have to give anything else full disk access. |
I also have a completely new workaround:
|
Hi,
I have trouble giving the emacs server the permissions to access files in the ~/Desktop and ~/Documents folders etc.
So the emacs binary (currently) is under
/usr/local/Cellar/emacs-plus@27/27.1/Emacs.app/Contents/MacOS/Emacs
. I can run this withexec
or straight and then emacs starts and everything is as expected: On the first attempt to open ~/Desktop there is a popup asking for permission and when the permission is granted it works.Now the service runs
/usr/local/Cellar/emacs-plus@27/27.1/Emacs.app/Contents/MacOS/Emacs --fg-daemon
and it does not work. That Emacs cannot access the Desktop or Documents or other restricted files and there is no popup and I see no way to grant that permission.Curiously, if I stop the service and run the same command line
/usr/local/Cellar/emacs-plus@27/27.1/Emacs.app/Contents/MacOS/Emacs --fg-daemon
from a terminal, it works and Emacs can access the files.So what does the
brew service
/launchctl
do differently so that it cannot access the files?The text was updated successfully, but these errors were encountered: