eclipse 在Eclipse中,如何打开当前编辑文件所在目录的文件浏览器

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/2419954/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-10 19:15:30  来源:igfitidea点击:

In Eclipse, how to open a file browser in the directory of the currently edited file

eclipsefile-browser

提问by levesque

I know it's possible in eclipse to open file browsers from your project's resource browser, but is it possible for files that aren't part of your project ? Typically external includes are not found in your resource browser...

我知道在 eclipse 中可以从您项目的资源浏览器打开文件浏览器,但是对于不属于您的项目的文件是否可能?通常在您的资源浏览器中找不到外部包含...

If there is the equivalent of $(resource_loc) for the editor, it would work.. But I wasn't able to find it. Can anyone help me on this ?

如果编辑器有相当于 $(resource_loc) 的东西,它会起作用..但我找不到它。谁可以帮我这个事 ?

Thanks!

谢谢!

EDIT : I Found StartExplorer, but it doesn't work for me. It is hardcoded to use WINDOWS exploreror cmd.exe. Also, it still requires you to use the resource browser. Other than that it can open paths selected in the editor, but they must be full paths.

编辑:我找到了StartExplorer,但它对我不起作用。使用WINDOWS explorercmd.exe是硬编码的。此外,它仍然需要您使用资源浏览器。除此之外,它可以打开在编辑器中选择的路径,但它们必须是完整路径。

EDIT 2 : StartExplorer seems to have been upgraded. I no longer use eclipse, but if someone else is still looking for this, I'd look again at their stuff!

编辑 2:StartExplorer 似乎已升级。我不再使用 eclipse,但如果其他人还在寻找这个,我会再看看他们的东西!

采纳答案by u290629

"Window" -> "Open Perspectives" -> "Remote Systems", then a view with root 'Local' node will be displayed.

"Window" -> "Open Perspectives" -> "Remote Systems",然后将显示具有根“本地”节点的视图。

While in Project Explorer pane, to browse files of any node, right click and select Show in Remote Systems viewto get there.

在 Project Explorer 窗格中,要浏览任何节点的文件,请右键单击并选择Show in Remote Systems view到达那里。

enter image description here

在此处输入图片说明

回答by Mohamed El-Nakib

For eclipse Luna (4.4) and later, You can use: Right Click->Show In->System Explorer enter image description here

对于 eclipse Luna (4.4) 及更高版本,您可以使用:右键单击->显示在->系统资源管理器 在此处输入图片说明

回答by GoRoS

From StartExplorerwebsite:

StartExplorer网站:

This plug-in is inherently not platform-independent. Currently, the following operating systems/desktop environments are supported out of the box: Windows, Mac OS, Linux with Gnome, Linux with KDE, Linux with Xfce, Linux with LXDE.

这个插件本质上不是平台无关的。目前,开箱即用支持以下操作系统/桌面环境:Windows、Mac OS、Linux with Gnome、Linux with KDE、Linux with Xfce、Linux with LXDE。

回答by Csaba_H

As far as I know you have to create a linked folderfor your external includes to achieve your goal. After that you can use StartExplorer for you externals as well. If you do not like that plugin you could try another similar one called EasyShellwhich is a similar one but you can configure all of its commands.

据我所知,您必须为外部包含创建一个链接文件夹才能实现您的目标。之后,您也可以为您的外部设备使用 StartExplorer。如果你不喜欢那个插件,你可以尝试另一个类似的名为EasyShell 的插件,它是一个类似的插件,但你可以配置它的所有命令。

回答by Pantelis Natsiavas

EasyShellseems quite descent to me (used in Ubuntu). It gives you the choices to open the Nautilus, to open the shell, to run a fileand to copy the selected path. All of them appear with a right click on the package explorer of Eclipse. The installation was with no problems. Therefore, I would suggest it.

EasyShell对我来说似乎很血统(在 Ubuntu 中使用)。它使您可以选择打开 Nautilus打开外壳运行文件复制选定的路径。所有这些都在 Eclipse 的包浏览器上单击鼠标右键出现。安装没有问题。因此,我会建议它。

Hope I helped!

希望我有所帮助!

回答by culmat

You might want to try eExplorer, see my answer on https://stackoverflow.com/a/24149472/612123

您可能想尝试eExplorer,请参阅我在https://stackoverflow.com/a/24149472/612123 上的回答

回答by wisbucky

If you are using git, you can open Window > Show View > Other > Git Repositories. That will give you a Git Repositories explorer, which shows the Working Tree. The Working Tree will show all files in the filesystem, even temporary ones you created that are not added to git yet.

如果您使用的是 git,您可以打开 Window > Show View > Other > Git Repositories。这将为您提供一个 Git 存储库资源管理器,其中显示了工作树。工作树将显示文件系统中的所有文件,甚至是您创建的尚未添加到 git 的临时文件。

Another way is to open Window > Perspective > Other > Git.

另一种方法是打开 Window > Perspective > Other > Git。

回答by Ashish Sahdev

Shortcut key can also be created in Eclipse>Help>Preferences>General>Keys

也可以在Eclipse>Help>Preferences>General>Keys中创建快捷键