Skip to content

Instantly share code, notes, and snippets.

@yancya
Created April 10, 2013 16:37
Show Gist options
  • Save yancya/5356272 to your computer and use it in GitHub Desktop.
Save yancya/5356272 to your computer and use it in GitHub Desktop.
C 言語の勉強するのに、いちいちコンパイルするのが面倒だったので、C のソース受け取って実行するスクリプト書いた。自動的に付与するヘッダの宣言は適宜増やす。
#!/bin/bash
echo '#include <stdio.h>' > source.c
cat $1 >> source.c
gcc source.c
rm source.c
./a.out
rm a.out
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment