问题描述
我正在开发一个(Java)项目,其中有很多 jar 文件附加了一个源 jar 文件.
I am working on a (Java) project in which I have many jars which have a source-jar file attached.
有什么方法可以让 Eclipse 的文件搜索"搜索包含这些源 jar 中的一些字符串文字的 Java 文件(以及 txt、xml 等),而不仅仅是在项目文件夹中?
Is there any way to make the eclipse "File Search" search for Java files (and txt, xml etc. for that matter) containing some string literal inside these source jars, not just in the project folder?
或者有什么插件可以实现?
Or is there any plugin by which this can be achieved?
推荐答案
最近发现以下插件具有用于搜索链接源 jar 的测试版支持:https://github.com/ajermakovics/eclipse-instasearch
Recently discovered the following plugin has beta support for searching into linked source jars: https://github.com/ajermakovics/eclipse-instasearch
您必须在首选项中启用搜索源 jar,因为默认情况下它是关闭的.根据您拥有的源数量,索引过程非常缓慢,但搜索速度非常快.
You have to enable searching source jars in the preferences as it is turned off by default. Depending on how much source you have, the indexing process is very slow, but then search is very fast.
我有一个 Eclipse 工作区,其中包含企业版 Alfresco(探索、共享和 SOLR)和 Alfresco Workdesk(Vanilla、Office 和 Mobile).在我 2011 年初的 MacBook Pro 上编制索引大约需要 8 分钟.搜索几乎是瞬间的.
I have an Eclipse workspace with the enterprise versions of Alfresco (Explore, Share and SOLR) and Alfresco Workdesk (Vanilla, Office and Mobile). Indexing took about 8 minutes on my Early 2011 MacBook Pro. Search is almost instantanious.
这篇关于如何使eclipse“文件搜索"还要搜索包含一些文本的源 jars 吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!