Skip to content

Instantly share code, notes, and snippets.

@uplime
Created June 12, 2026 17:31
Show Gist options
  • Select an option

  • Save uplime/9692dceea722d0558da801a74eaafc65 to your computer and use it in GitHub Desktop.

Select an option

Save uplime/9692dceea722d0558da801a74eaafc65 to your computer and use it in GitHub Desktop.
Display a program's source as its output.
quine ()
{
type quine | {
read;
IFS= read -rd '' func;
printf %s "$func"
};
printf quine
}
quine
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment