您的位置:首页 > 其它

sublime text 3 设置在不同浏览器中运行的快捷方式

2015-05-17 20:52 501 查看
自从遇到sublime text 后,一下子就喜欢上了这款软件,强大的插件支持功能,真的让人爱不释手!可是,不得不说,它有一个小缺点,就是只能在默认的浏览器中打开(貌似也没有插件可以解决这个问题(个人拙见))。。不知道别人怎么想,反正强迫症的我是有些容忍不了,,花了不少时间,终于解决了这个问题,下面就来看看怎么设置不同浏览器运行的快捷方式吧!

安装 SideBarEnhancements插件后,打开sublime text 3 ,Preferences->Key Bindings-User,在打开的窗口中输入如下代码(我的浏览器设置):

[
{ "keys": ["ctrl+shift+c"], "command": "copy_path" },
// { "keys": ["alt+f12"], "command": "open_in_browser" },//默认浏览器打开
{ "keys": ["ctrl+fn+f1"], "command": "side_bar_files_open_with",  // ctrl+fn+f1在firefox中打开
"args": {
"paths": [],
"application": "C:\\Program Files (x86)\\Mozilla Firefox\\firefox.exe",
"extensions":".*" //any file with extension
}
},
{ "keys": ["ctrl+fn+f2"], "command": "side_bar_files_open_with",  // ctrl+fn+f2在chrome中打开
"args": {
"paths": [],
"application": "C:\\Users\\lenovo\\AppData\\Local\\Google\\Chrome\\Application\\chrome.exe",
"extensions":".*" //any file with extension
}
},
{ "keys": ["ctrl+fn+f3"], "command": "side_bar_files_open_with",  // ctrl+fn+f3在ie中打开
"args": {
"paths": [],
"application": "C:\\Program Files\\Internet Explorer\\iexplore.exe",
"extensions":".*" //any file with extension
}
},
{ "keys": ["ctrl+fn+f4"], "command": "side_bar_files_open_with",  // ctrl+fn+f4在UC browser中打开
"args": {
"paths": [],
"application": "F:\\software\\UCBrowser\\Application\\UCBrowser.exe",
"extensions":".*" //any file with extension
}
}
]


保存后重启。现在你的html文件就可以用自己设置的快捷键在不同的浏览器中运行了!!
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: