sublime text2 node.js 开发配置

应用Package Control

调出 Console(Ctrl + `),输入下列代码,并执行。

<!-- lang: python -->
import urllib2,os;pf='Package Control.sublime-package';ipp=sublime.installed_packages_path();os.makedirs(ipp) if not os.path.exists(ipp) else None;open(os.path.join(ipp,pf),'wb').write(urllib2.urlopen('http://sublime.wbond.net/'+pf.replace(' ','%20')).read())

.

安装Emmet

调出 Package Control Install (Ctrl+Shift+P),输入 emmet,回车安装。

.

CoffeeScript 高亮

打开 Prefrences > Browse Packages。

.

常用配置修改

个人习惯

  • 单行注释:Ctrl+'
  • 块注释:Ctrl+Shift+'
  • 自动补全:Ctrl+;

打开 Prefrences > Key Binds - User, 输入下列信息:

<!-- lang: js -->
[
    { "keys": ["ctrl+'"], "command": "toggle_comment", "args": { "block": false } },
    { "keys": ["ctrl+shift+'"], "command": "toggle_comment", "args": { "block": true } },

    { "keys": ["ctrl+;"], "command": "auto_complete" },
    { "keys": ["ctrl+;"], "command": "replace_completion_with_auto_complete", "context":
        [
            { "key": "last_command", "operator": "equal", "operand": "insert_best_completion" },
            { "key": "auto_complete_visible", "operator": "equal", "operand": false },
            { "key": "setting.tab_completion", "operator": "equal", "operand": true }
        ]
    },

    {
        "keys": [
            "ctrl+shift+backspace"
        ], 
        "args": {
            "action": "remove_tag"
        }, 
        "command": "run_emmet_action", 
        "context": [
            {
                "key": "emmet_action_enabled.remove_tag"
            }
        ]
    },

    {
        "keys": [
            "ctrl+alt+]"
        ], 
        "args": {
            "action": "matching_pair"
        }, 
        "command": "run_emmet_action", 
        "context": [
            {
                "key": "emmet_action_enabled.matching_pair"
            }
        ]
    }
]

转载于:https://my.oschina.net/u/857391/blog/131475

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值