zoukankan      html  css  js  c++  java
  • Sublime Text 3 C++ 配置

    Sublime Text 3 C++ 配置

    先将MinGWin添加至环境变量中,然后打开Sublime Text,菜单Tools->Build System->New Build System...

    {
        // "shell_cmd": "make"
        "encoding": "utf-8",
        "working_dir": "$file_path",
        "shell_cmd": "g++ -Wall -std=c++0x "$file_name" -o "$file_base_name"",
        "file_regex": "^(..[^:]*):([0-9]+):?([0-9]+)?:? (.*)$",
        "selector": "source.cpp",
    
        "variants": 
        [
            {   
            "name": "Run",
                "shell_cmd": "g++ -Wall -std=c++0x  "$file" -o "$file_base_name" && "${file_path}/${file_base_name}""
            },
            {   
            "name": "RunInCmd",
                "shell_cmd": "g++ -Wall -std=c++0x  "$file" -o "$file_base_name" && start cmd /c ""${file_path}/${file_base_name}" & pause ""
            }
        ]
    }
    

    两种模式,Run直接在Sublime Text中输出;RunInCmd则弹出cmd窗口

    Ctrl+B Build,Ctrl+Shift+B切换模式

  • 相关阅读:
    使用基本的socket函数
    ODBC、ADO
    MFC开发ActiveX控件的简介
    MFC线程
    系统API函数实现多线程及线程同步
    IP地址控件
    加速键
    属性页对话框
    Tab控件
    树控件
  • 原文地址:https://www.cnblogs.com/santiego/p/11233722.html
Copyright © 2011-2022 走看看