SublimeText3 Build Systems

{
    /*  A string specifying the encoding of the build system output. 
        Uses Python codec names. 
        Defaults to "utf-8".*/
    "encoding": "utf-8",
    
    /*  A string specifying the directory to execute the cmd or shell_cmd within. 
        May use variables.
        Example: "$file_path" */
    "working_dir": "$file_path",
    
    /*  A string specifying a shell command to execute. 
        Unlike the cmd option, this does allow piping and redirection. 
        Will use bash on Mac and Linux machine, and cmd.exe on Windows. 
        May use variables.
        Example: "my_command \"$file\" | other_command" */
    "shell_cmd": "g++ -Wall -std=c++11 \"$file_name\" -o \"$file_base_name\"",

    /*  A string containing a regular expression to run on the build output to match file information. 
        The matched file information is used to enable result navigation. 
        The regex(正则表达式regular expression) should capture 2, 3 or 4 groups.
        The capture groups should be:
            filename
            line number
            column number
            message
        Example: "^\s*(\\S[^:]*)\\((\\d+):(\\d+)\\): ([^\\n]+)" */
    "file_regex": "^(..[^:]*):([0-9]+):?([0-9]+)?:? (.*)$",
    
    /*  The base scope name of the syntax that this build system should be enabled for.
        Example: "source.python".*/
    "selector": "source.c++",

    /*  A list of subsidiary build systems that will inherit the options from the top-level build system. 
        Each variant needs to specify a name key, and may override or add options to the top-level build system.*/
    "variants": 
    [
        {   
        "name": "Run",
            "shell_cmd": "g++ -Wall -std=c++11 \"$file\" -o \"$file_base_name\" && start cmd /c \"\"${file_path}/${file_base_name}\" & pause\""
        }
    ]
}

 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值