Sublime Forum

Sublime text does not support compiling *. cpp?

#1

I have made a new sublime-build to compile c++,and the “shell_cmd” is “cd ${file_path} && g++ *.cpp”,but when i compile in sublime text ,it report “g++: error: *.cpp: Invalid argument g++: fatal error: no input files compilation terminated.” while this command compile successfully in cmd.Please help me get it right.

0 Likes

#2

Hi there, maybe you can convert your code like to this:
"cmd": ["g++", "${file}", "-o","${file_path}/${file_base_name"],

0 Likes