{
	"cmd": ["gcc", "${file}", "-o","${file_path}/${file_base_name}"],
	"file_regex": "^(..[^:]*):([0-9]+):?([0-9]+)?:?(.*)$",
	"working_dir": "${file_path}",
	"encoding":"cp936",
	"selector": "source.c",
	"variants":
	[
		{
			"name": "Run",
			"cmd": ["cmd","/C","start","cmd","/c", "${file_path}/${file_base_name}.exe &pause"]
		}
	]
}

  环境变量添加gcc路径

linux

{  
    "shell_cmd": "gcc \"${file}\" -o \"${file_path}/${file_base_name}\" -Wformat=2",  
    "file_regex": "^(..[^:]*):([0-9]+):?([0-9]+)?:? (.*)$",  
    "working_dir": "${file_path}",  
    "selector": "source.c",  
    "variants":  
    [  
        {     
            "name": "Run",  
            "shell_cmd": "gcc \"${file}\" -o \"${file_path}/${file_base_name}\" -Wformat=2 && \"${file_path}/${file_base_name}\""  
        }     
    ]  
}  

  

相关文章:

  • 2022-12-23
  • 2021-06-15
  • 2021-12-09
  • 2021-12-29
  • 2022-12-23
  • 2022-12-23
  • 2021-09-03
猜你喜欢
  • 2021-04-28
  • 2021-12-03
  • 2021-07-07
  • 2021-08-03
  • 2021-12-03
  • 2022-02-14
相关资源
相似解决方案