zachcurry / emacs-anywhere

Configurable automation + hooks called with application information
MIT License
1.08k stars 49 forks source link

Emacs anywhere fails when in OSX "Firefox Developer Edition" #54

Open rfinz opened 6 years ago

rfinz commented 6 years ago

Attempting to paste into "Firefox Developer Edition", emacs-anywhere would close the frame and paste its contents into whatever buffer was open in the main emacs instance. Renaming to "Firefox" fixed the issue for me.

Mac OSX High Sierra 10.13.4

zachcurry commented 6 years ago

Hi, @rfinz ! 👋

Thanks for taking the time to tell me about this. Let's run a test and find out what's going on, if that's cool with you?

Start by clearing your workspace to avoid problems with the random paste behavior. Next, invoke Emacs Anywhere with Firefox Developer Edition. Then, do a

M-: ea-app-name

I can confirm that Firefox Developer Edition reports it's name as "firefox" on my machine. Next, try the example above, but this time use Google Chrome; on my machine, it evaluates to "Google Chrome".

The way to workaround this issue with integrating developer editions would be to handle this special case by using the hook for Emacs Anywhere in your init/config files to do the right thing. You will find a list of all of the variables, hook, and examples of how to write custom configuration for Emacs Anywhere in the README.

If you have an idea that you think will help in these corner cases and is general enough to solve all, or most cases, let me know! I'm open to suggestions and pull requests 😄

rfinz commented 6 years ago

Thanks for responding! I've updated the name of this issue to reflect the more nuanced reality discovered through your more rigorous (mine was heinously casual) testing. Hopefully this ticket's presence helps someone fix the issue for themselves. I'll let you know if I think of a more general solution.