{ "cmd": ["g++", "${file}", "-o", "${file_path}/${file_base_name}"], "file_regex": "^(..[^:]*):([0-9]+):?([0-9]+)?:? (.*)$", "working_dir": "${file_path}", "selector": "source.c, source.c++", "variants": [ { "name": "Run", "cmd": ["bash", "-c", "g++ '${file}' -o '${file_path}/${file_base_name}' && open -a Terminal.app '${file_path}/${file_base_name}'"] } ] }
mac下的terminal +Xcode 十分接近linux/unix下的編程環境,很適合編寫c/c++。不過最近發現了一個很好用的編程環境 sublime text,它很適合“健忘”的人,並且因為它有自動填寫功能,可以提升編程速度。唯一的缺點是,它無法讀取cin,scanf這種從stdin
加上這句
轉載於http://blog.csdn.net/cjy29088/article/details/40300361