Sublime Forum

Run build system in a seperate command window

#1

I am on windows, and I created a build system to open a separate command window and run the file. However, currently, when the file finishes running, it just quits. Is there any ways to wait for keystroke and then quit? Thanks in advance.

{
    "cmd": "g++ -std=c++14 -Dray -O0 \"${file_name}\" -o \"${file_base_name}.exe\"",
    "file_regex": "^(..[^:]*):([0-9]+):?([0-9]+)?:? (.*)$",
    "working_dir": "${file_path}",
    "selector": "source.c, source.c++",

    "variants": [

        {   
            "cmd": ["start", "cmd", "/k", "${file_base_name}.exe"],
            //"cmd": ["start", "cmd", "sadfasdfasdfasdf"],
            "shell": true,
            "name": "Run"
        }
    ]
}
0 Likes

#2

No, build systems don’t take input. Use the Terminus package instead.

0 Likes