Post details: Simplest bash quine ?

2 August, 2005

Permalink 22:18 UTC, by Fernando J. Pereda, 50 words, 632 views   English (US)
Categories: Uncategorized

Simplest bash quine ?

Playing around with some of the new bash-3 features I accidentally found a really simple quine:

[ $ ~ ] cat quine.bash
echo ${BASH_COMMAND}
[ $ ~ ] bash quine.bash
echo ${BASH_COMMAND}
[ $ ~ ]

Of course it only works on bash-3. I don't know if that's 'cheating'... but oh well... it's still interesting heh :)

Cheers,
Ferdy

Fernando J. Pereda

Here you will find stories about Gentoo net-mail development from Fernando J. Pereda (ferdy).

November 2008
Mon Tue Wed Thu Fri Sat Sun
<< <     
          1 2
3 4 5 6 7 8 9
10 11 12 13 14 15 16
17 18 19 20 21 22 23
24 25 26 27 28 29 30

Search

Categories

Misc

XML Feeds

What is RSS?

Who's Online?

  • Thilo Bangert Email
  • Guest Users: 61

powered by
b2evolution