subliem text 3编译C\C++

来源:互联网 发布:浪拍云的淘宝人生 编辑:程序博客网 时间:2024/06/05 04:56

首先在TOOLS下的Build System里边点击new Build System,编辑如下内容:

{"cmd": ["$packages\\tcc\\tcc.bat", "$file", "$packages\\tcc\\tcc.exe"],"file_regex": "^(..[^:]*):([0-9]+):?([0-9]+)?:? (.*)$","selector": "source.c"}

在刚才tcc的文件夹下我们添加一个文件,tcc.bat,内容如下:

if exist %~n1.exe (del %~n1.exe)%2 %1start cmd /c %~n1.exe

不要小看这三行,很精髓的。
至此呢,我们就完成了TCC关于ST的移动编译器的全部工作了。
新建一个文件a.c,内容如下:

#include <stdio.h>#include <stdlib.h>int main(){printf("Hello World\n");system("pause");return 0;}

生成ssh key:
http://git.mydoc.io/?t=154712

阅读全文
0 0
原创粉丝点击