Sublime 利用 SideBarEnhancements 插件 实现用快捷键打开文件

这个神器上手好几天了,谁叫我是折腾党。下了SideBarEnhancements插件后,可以实现Chrome打开网页快捷键,今天要写VBS脚本,就想:为什么不能像VS一样按F5来执行呢?于是我编写了如下快捷方式

                       {
				"caption": "Run",
				"id": "side-bar-files-open-with-Run",

				"command": "side_bar_files_open_with",
				"args": {
									"paths": [],
									"application": "C:\\Windows\\System32\\cmd.exe",
									"extensions":".*", //any file with extension
									"args":[]
						},
				"open_automatically" : false // will close the view/tab and launch the application
			},

这不难题来了,cmd.exe竟然无效,我要一般打开文件都是右键选择打开,不知道要调用哪个程序啊。上网搜寻无果后,又继续折腾,换成了explorer.exe,竟然可以执行了!


接下来就把快捷键设置成F5就OK啦


首选项-案件绑定-用户 添加如下代码就可以了


    { "keys": ["f5"], "command": "side_bar_files_open_with",
            "args": {
                "paths": [],
                "application": "C:\\Windows\\System32\\explorer.exe",
                "extensions":".*" //any file with extension
            } 
     } 


现在按F5,就可以执行VBS程序啦,是不是很方便呢!

  • 1
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值