如何配置 TortoiseHg 根据文件扩展名在正确的程序中打开文件?
我在 WindowsXP 中使用 TortoiseHg v2.2.1 和 Mercurial 1.9。如何配置 TortoiseHg 以根据 Windows 与其扩展名关联的应用程序查看文件?
例如,如果我在存储库中有一个 .docx 文件,并且正在查看其修订历史记录,我希望使用 View at revision...
在 MS Word 中打开选定的修订版本。对于 ppt 和 xls 等其他二进制文件类型也是如此,我无法使用默认文本编辑器或 kdiff3 查看它们。
我是否可以利用 Windows 已经知道使用什么程序来打开某些类型的文件,或者我是否必须在 Tortoise 配置文件中手动配置感兴趣的每种文件类型?
我在 TortoiseHg\diff-scripts
文件夹中发现了几个 SVN 脚本,它们看起来解决了比较二进制文件的类似问题,而不是简单地查看它们,但这些脚本似乎没有被激活,我不确定我是否需要在 MergePatterns.rc
或 Mercurial.ini
文件使这一切正常工作。
I'm using TortoiseHg v2.2.1 with Mercurial 1.9 in WindowsXP. How do I configure TortoiseHg to view a file based on the application Windows has associated with its extension?
For example, if I have a .docx file in the repository and I'm looking at its revision history, I'd like View at revision...
to open the selected revision in MS Word. Likewise for other binary file types like ppt and xls, which I can't view using the default text editor or kdiff3.
Can I leverage that Windows already knows what program to use to open certain types of files or will I have to manually configure each file type of interest within the Tortoise config files?
I've found several SVN scripts in the TortoiseHg\diff-scripts
folder that look like they solve a similar problem for diffing binaries rather than simply viewing them, but those don't seem to be activated and I'm not sure what if anything I need to mod in the MergePatterns.rc
or Mercurial.ini
files to make this all work.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
要使“查看修订版本”使用与文件扩展名关联的任何程序,请尝试以下技巧:在“TortoiseHg”部分的“全局设置”中,输入
start ""
作为“Visual Editor” 。请注意空的""
。这是必要的,这样start
就不会使用由 TortoiseHg 在引号中传递的文件名作为窗口标题。To make "View at Revision" use whatever program is associated with the file's extension, try this trick: In the "Global Settings" in the "TortoiseHg" section, enter
start ""
as "Visual Editor". Note the empty""
. This is necessary so thatstart
will not use the file name, which gets passed in quotes by TortoiseHg, as the window title.