emacs-snap
emacs-snap copied to clipboard
emacsclient path not symlinked as part of installation
hi alex - many thanks for maintaining the emacs-snap :)
I did a clean-install of emacs / ubuntu 22.04 and had some trouble getting magit to use emacsclient. Based on https://github.com/magit/with-editor/issues/125 - I had to run this command:
sudo ln -s /snap/bin/emacsclient /usr/local/bin/emacsclient
would be helpful if this was added to the install workflow. unsure where it gets added or I'd have opened a PR
The snap should set up an automatic alias for emacsclient
- can you list the output of: snap aliases
? There should already be a symlink in /snap/bin/emacsclient
.
sreenivas@arceus:~$ snap aliases
Command Alias Notes
emacs.ebrowse ebrowse -
emacs.emacsclient emacsclient -
firefox.geckodriver geckodriver -
sreenivas@arceus:~$
Yep so the alias is there - and there should be a symlink in /snap/bin/emacsclient
as well then. So from what I can see, the emacs snap is doing all that it can to ensure an emacsclient
is in PATH
- snaps are not able to write to /usr/local/bin
so it is not feasible for the snap to add such a symlink. Do you know why with-editor
is expecting such a symlink to exist?
no sadly - just passing on what I found from the other issue, but looks like it may be a problem with with-editor
in this case
I think it may be more likely a problem with your system - have you by chance manually compiled and installed emacs previously? If so, I suspect there may be symlinks left over in /usr/local/bin
- can you please have a look?
ls -la /usr/local/bin/emacs*
no - this is all on a fresh install of ubuntu 22.04 - only installed via snap
sreenivas@arceus:~/.config$ ls -la /usr/local/bin/emacs*
lrwxrwxrwx 1 root root 21 Mar 24 18:27 /usr/local/bin/emacsclient -> /snap/bin/emacsclient
Hmm weird - so I use magit myself and have never had any issues with it and the emacs snap. On my machine I see with-editor-emacsclient-executable
has the value of /snap/emacs/2430/usr/bin/emacsclient
- and I have no specific customisations for the with-editor package.
So I can only presume this is an issue with your local configuration... I'll close this issue since there isn't a lot we can do on the snap side of things but am happy to help you try and diagnose what is happening if you need.