commandlinefu.com is the place to record those command-line gems that you return to again and again.
You can sign-in using OpenID credentials, or register a traditional username and password.
Subscribe to the feed for:
This should work on any unix platform running bash. Just type the program into cat and give it a ^D when you're done, at which time it will compile, run, and remove the program. Obviously, you can run it without the "rm a.out" if you'd like to keep the binary. If you want to keep the source, well, you might as well just write it in vi or emacs first then.
There are 11 alternatives - vote for the best!
This is a quick hack to make a gcc caller. Since it runs with gcc instead of tcc, it's a bit more trustworthy as far as the final answers of things go.
If you can do better, submit your command here.
You must be signed in to comment.