是否有热键可以加快 Eclipse(或通用 Windows GUI 宏工具)中的重复提交速度?
我正在 Eclipse PDT 中对 .php 文件进行大量微小的更改,然后提交它们并在服务器上进行测试。
重复的六步提交过程变得乏味:
right-click
team
Commit...
click "choose previously selected comment"
select in list
click OK
有谁知道热键或其他过程来加速这一过程?
更新:有谁知道 Windows 应用程序的通用热键宏工具,它允许我编写一个宏来为我进行这 6 次点击?
I am making numerous, minute changes to .php files in Eclipse PDT then committing them and testing on the server.
The repetitive six-step commit process is getting tedious:
right-click
team
Commit...
click "choose previously selected comment"
select in list
click OK
Does anyone know of a hotkey or other process to expedite this?
UPDATE: does anyone know of a general hotkey macro tool for windows applications which would allow me to program a macro that would make these 6 clicks for me?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(4)
我能做的最好的事情就是为“提交”创建一个键绑定(在“首选项”...“常规”->“键”下)。 然后你只需要点击项目并点击组合键,这就省去了整个右键->团队->提交...的过程。
如果您只想签入正在编辑的文件,则不必单击任何位置,只需按组合键,就会弹出提交对话框以提交当前文件。
The best I've been able to do is create a key binding for 'Commit' (under Preferences... General->Keys). Then you just need to click on the project and hit a key combination, which saves the whole right-click->Team->Commit... process.
If you just want to check in the file you are editing, you don't have to click anywhere, just hit the key combination, and the commit dialog pops up to commit the current file.
在 Eclipse 中,您可以选择提交一个文件或整个项目。
要提交整个项目,请右键单击资源视图中的项目,然后选择“团队”->“提交”。
如果您想预览更改,请选择“团队”->“同步”,这将显示更改了哪些文件,并让您快速预览传入和传出模式下的差异。
In eclipse you can choose to either commit one file or the entire project.
To commit the entire project, right click on the project in your resource view, and choose Team->Commit.
If you want to preview the changes choose Team->Synchronize, which will show you what files are changed, and gives you a quick preview of the diffs in both incoming and outgoing mode.
在某些版本的 Eclipse(或者某些版本的 Subclipse——您使用 SVN 吗?)中,有一个可以单击的工具栏按钮。 它将消除提交过程的前 2 或 3 个步骤。 也许您可以在工具栏编辑器(或透视编辑器,或者无论他们如何称呼它)上找到该按钮......我已经有一段时间没有使用它了)。
另外,恕我直言,您不应该先提交然后再测试。 如果您在本地测试,然后提交(并在 QA 类型系统中再次测试......),您会发现事情运行得更顺利。 您可能已经知道这一点,所以我假设有一个奇怪的原因您无法在本地进行测试。
In some versions of Eclipse (or maybe some versions of Subclipse -- are you using SVN?) there was a toolbar button that you could click. It would eliminate the first 2 or 3 steps of your commit process. Maybe you can find that button on the toolbar editor (or perspective editor, or whatever they call it... it's been a while since I've used it).
Also, IMHO, you shouldn't be committing and THEN testing. You'll find things run a lot smoother if you test locally, then commit (and test again in a QA type system...). You probably already know that, so I'm going to assume there's a strange reason you can't test locally.
我发现在 Package Explorer 中右键单击项目或文件是这个重复过程中最耗时的部分。
大多数情况下,我在多个文件中进行相关更改,然后同步整个项目。 通过热键加速整个过程的第一步是将组合键绑定到“与存储库同步...”。 对于 OSX 上的 Eclipse 3.5,可以通过转到 Eclipse->Preferences->General->Keys 来绑定热键。 然后在文本过滤器中搜索“同步”。 我将 control-s 绑定为同步。
一旦热键绑定到 Synchro... ,点击热键将同步活动编辑器中的文件,或项目资源管理器中选定的文件(如果项目资源管理器处于活动状态)。
要快速将焦点置于项目资源管理器,请在 OSX 上按 Command-F6 以循环到项目资源管理器。 另一种方法是,如果焦点位于编辑器视图中,则点击 cmd-alt-W(显示在...),然后从弹出窗口中选择“Project Explorer”。 抱歉,OSX 快捷键。 如果您查看前面提到的“按键”区域,您应该能够找到骑行视图的相关热键。
因此,我们加快了部分流程,但如果能够快速选择整个项目,那就太好了。 最简单的方法是破解 - 只需在项目资源管理器中输入项目名称即可。 如果名称不够唯一,请在其前面添加“Z”或其他内容,这样只需按“z”键即可选择整个项目。 然后点击 Synchro... 热键来同步整个项目。
好吧,所以需要相当多的热键来同步整个项目,几乎就像弹奏一系列吉他和弦或在《铁拳》中进行甜蜜的组合,但老实说,热键序列都可以在比移动所需的时间短的时间内按下你的手到鼠标。 也许将宏绑定到整个序列会变得非常方便。
I find that right-clicking the project or file in the Package Explorer is the most time consuming part of this repetitive process.
Mostly I make related changes in multiple files, then synchronize the whole project. The first step to making the whole process accelerated via hotkeys is to bind a key combination to "Synchronize with repository...". For Eclipse 3.5 on OSX, the hotkey can be bound by going to Eclipse->Preferences->General->Keys. Then search for "Synchronize" in the text filter. I bind control-s as synchronize.
Once a hotkey is bound for Synchro... , hitting the hotkey will synchronize the file in your active editor, or the selected files in the project explorer, if the project explorer is active.
To rapidly put focus in to the project explorer, hit, on OSX, command-F6 to cycle to the project explorer. Another way, if focus is in an editor view, is to hit cmd-alt-W (Show In...) and then select "Project Explorer" from the popup. Sorry for the OSX shortcuts. If you look in the Keys area mentioned earlier, you should be able to find the relevant hotkey for cycling views.
So we've sped up part of the process, but it would still be nice to have a rapid way of selecting the whole project. The easiest way is a hack- just start typing the name of your project while in the project explorer. If the name isn't unique enough, prepend a 'Z' to it or something so that just they keystroke 'z' will select the whole project. Then hit your Synchro... hotkey to synch the whole project.
Okay, so it takes quite a few hotkeys to synch the whole project, almost like playing a progression of guitar chords or doing a sweet combo in Tekken, but honestly the sequence of hotkeys can all be pushed in less than the time it takes to move your hand to the mouse. Perhaps binding a macro to the entire sequence would make it uber convenient.