Ope*_*way 6 textmate multiple-instances
你知道如何在 Textmate 中为同一个文件打开多个窗口吗?
所以我可以同时查看和比较同一个文件的不同部分。
快速 AppleScript 进行复制粘贴等操作。操作顺序:
tell application "TextMate"
activate
tell application "System Events"
keystroke "a" using command down
keystroke "c" using command down
keystroke "n" using command down
keystroke "v" using command down
keystroke "a" using command down
key code "55"
end tell
end tell
Run Code Online (Sandbox Code Playgroud)
基本上它执行全选、复制、新建、粘贴、全选、向上(最后两个命令将光标带到新复制的文件的顶部)。在您显式设置语言之前,新文件也不会进行语法高亮显示;这可能有助于区分原件和副本。
在更高级的版本中,您实际上可以获取文件名,将其复制到临时位置,然后打开它,但是您必须维护这两个版本,并且存在您在没有意识到的情况下修改重复项的风险。
希望能帮助到你。