Skip to content

Instantly share code, notes, and snippets.

@jeremyBanks
jeremyBanks / expanded.md
Created June 22, 2010 05:10
one-line self-executing c header and expanded explanation
//

Since we don't want this visible in C, we put it in a comment.

&>/dev/null

Unfortunately // is interpreted as an invalid shell command and produces an error message, so we need to redirect that to /dev/null to get rid of it.

;x="${0%.*}"