Emacs 23,OS X,multi-tty和emacsclient [英] Emacs 23, OS X, multi-tty and emacsclient

查看:97
本文介绍了Emacs 23,OS X,multi-tty和emacsclient的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我已经添加了(服务器启动) 到我的.emacs,并发现运行 /Applications/Emacs.app/Contents/MacOS/bin/emacsclient -n〜/ myfile.txt 将在我的emacs.app中打开它,但它并没有将emacs带到前端。



那么,如何才能让emacs.app来到前端当我运行emacsclient? (我已经考虑编写一个函数,将每个文件打开时将当前帧放在前面,或者也可能编写一个Applescript来执行类似的工作,同时可以调用emacsclient)



emacs.app中的emacsclient是最好使用的?我假设我会写一个别名,如果是这样,但似乎很奇怪的是使用它,而不是在/ usr / local / bin中的东西



有没有人有

解决方案

AppleScript将很简单:

 告诉应用程序Emacs激活


How can I get emacs 23 working nicely in multi-tty mode on OS X?

I've added (server-start) to my .emacs, and have discovered that running /Applications/Emacs.app/Contents/MacOS/bin/emacsclient -n ~/myfile.txt will open it in my emacs.app, but it doesn't bring emacs to the front.

So, how can I get emacs.app to come to the front when I run emacsclient? (I've considered writing a function that puts the current frame to the front every time a file is opened, or maybe writing an Applescript to do a similar job that could be called at the same time as emacsclient)

Is the emacsclient within emacs.app the best one to use? I assume I'll write an alias to it if so, but it seems weird to be using that rather than something in /usr/local/bin

Has anyone got any other tips or examples of getting this working?

解决方案

The AppleScript would be simple:

tell app "Emacs" to activate

这篇关于Emacs 23,OS X,multi-tty和emacsclient的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆