emacs代码浏览+跳转

折腾半年多了,总算是找到个比较合适的方式。

我的选择是cedet+ecb+global

gnu-global是一个兼容tag工具,看名字就知道它打算怎么干活的了。gtags是emacs下与global交互的插件

首先一次去下载上面三个的源码,global是gtags,

cedet官网http://cedet.sourceforge.net/

ecb官网http://ecb.sourceforge.net/

然后ubuntu下不要使用sudo apt-get install 来的global,版本问题可能会和你下载gtags不兼容,有个参数不识别。

下载地址http://www.gnu.org/s/global/download.html

下载后解压,$./configure 

$make 

$sudo make install 

然后源码包里有个gtags.el这是我们的emacs插件

把cedet,ecb,gtags插件放到你保存插件的位置,我的都在~/emacs/下面,然后每个插件有自己单独的目录。



;;配置cedet
(add-to-list 'load-path "~/emacs/cedet-1.0pre7/common")
(add-to-list 'load-path "~/emacs/cedet-1.0pre7/contrib")
;;(load-file "~/emacs/cedet-1.0pre7/common/cedet.el")
(require 'cedet)
(require 'semantic-ia)
(global-ede-mode 1)                      ; Enable the Project management system
(semantic-load-enable-code-helpers)      ; Enable prototype help and smart completion 
(global-srecode-minor-mode 1)            ; Enable template insertion menu
(require 'semantic-tag-folding nil 'noerror)
(global-semantic-tag-folding-mode 1)
(global-set-key [f12] 'semantic-ia-fast-jump)
(global-set-key [S-f12]
                (lambda ()
                  (interactive)
                  (if (ring-empty-p (oref semantic-mru-bookmark-ring ring))
                      (error "Semantic Bookmark ring is currently empty"))
                  (let* ((ring (oref semantic-mru-bookmark-ring ring))
                         (alist (semantic-mrub-ring-to-assoc-list ring))
                         
  • 2
    点赞
  • 3
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
回答: 根据你提供的引用内容,我理解你在询问关于Centaur Emacs的问题。Centaur Emacs是一个基于Emacs的配置,旨在提供更好的用户体验和更高的生产力。它包含了许多常用的插件和配置,使得Emacs更加易用和功能强大。根据引用\[1\]和引用\[2\]的内容,配置Centaur Emacs的过程包括下载和解压Emacs,设置系统环境变量,以及根据个人的需求进行一些额外的配置。具体的步骤可以参考引用\[1\]和引用\[2\]中提供的详细说明。另外,引用\[3\]中提供了一个设置字体的示例代码,可以根据个人喜好进行配置。希望这些信息对你有帮助。 #### 引用[.reference_title] - *1* *2* [Win10+emacs配置](https://blog.csdn.net/gxiaop/article/details/51347350)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v91^insert_down1,239^v3^insert_chatgpt"}} ] [.reference_item] - *3* [window8.1+ emacs24.3配置python显示自动补全方法](https://blog.csdn.net/huangdecai2/article/details/40951607)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v91^insert_down1,239^v3^insert_chatgpt"}} ] [.reference_item] [ .reference_list ]

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值