如何设置Cscope->数据库->数据库 设置初始化目录

发布于 2024-07-26 03:28:28 字数 271 浏览 7 评论 0原文

我正在使用 xcode 和 emacs。 但每次启动 emacs 时,我都需要 转到菜单“CScope”-> Cscope->数据库-> 设置初始化目录 它选择我的源的根目录。

然后我单击“CScope”-> Cscope->数据库-> set init Directory->创建列表和索引'

无论如何,我可以在 .emacs 中配置它,这样我就不需要每次启动 emacs 时都这样做吗?

谢谢。

I am using xcode with emacs. But everytime I start emacs, I need to
go to menu 'CScope' -> Cscope->database -> set init Directory
and it pick the root directory of my source.

And then I click 'CScope' -> Cscope->database -> set init Directory->create list and index'

Is there anyway I can configure that in .emacs so that I don't need to do that every time i start emacs?

Thank you.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

很糊涂小朋友 2024-08-02 03:28:28

如果您使用此 cscope 模式看起来您可以执行Mx custom-variable RET cscope-last-directory RET,将变量设置为您最喜欢的目录,然后保存该值。 如果没有,您必须更具体地了解如何将 cscope 与 Emacs 一起使用。

If you're using this cscope mode it looks like you could do M-x customize-variable RET cscope-last-directory RET, set the variable to your favorite directory, and save the value. If not, you'll have to be more specific about how you are using cscope with Emacs.

醉态萌生 2024-08-02 03:28:28

参考《在大型项目中使用Cscope(例如:Linux内核)》

  1. 使用find命令构建cscope.files

    find /path/to/project -name ".h" -or -name ".c" > /path/to/cscope/initdir

  2. 编辑 .emacs

    (setq cscope-in​​itial-directory "/path/to/cscope/initdir")

PS: 我使用xcscope.el

refer to "Using Cscope on large projects(example: the Linux kernel)"

  1. use find command build cscope.files

    find /path/to/project -name ".h" -or -name ".c" > /path/to/cscope/initdir

  2. edit .emacs

    (setq cscope-initial-directory "/path/to/cscope/initdir")

PS: I use xcscope.el

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文