view bin/quine2 @ 11918:a51467a3be09 draft

<wob_jonas> learn can\'t is the most frequent word whose pronunciation varies between /\xc9\x91\xcb\x90/ and /\xc3\xa6/ depending on dialect. A list is: advance, advantage, after, answer, ask, aunt, branch, can\'t, cast, chance, class, craft, command, contrast, dance, demand, disaster, draft, enhance, example, fast, glass, glance, grant, graph, grass, half, last, laugh, mask, maste
author HackEso <hackeso@esolangs.org>
date Thu, 29 Aug 2019 10:06:05 +0000
parents f2f65a1fa363
children
line wrap: on
line source

#!/bin/sh
a() { p=$(echo -n $(ps -p $1 -oppid | tail -1)); if ps -p $p -ocmd | tail -1 | egrep -q "^sh -c .* \| cat\$"; then ps -p $1 -ocmd | tail -1; else a $p; fi }
q=$(a $$); if echo "$q" | grep -q "^bash -c"; then echo "$q" | sed "s/^bash -c/\`run/"; elif echo "$q" | grep -q "^/bin/sh /hackenv/bin/"; then echo "$q" | sed "s,^/bin/sh /hackenv/bin/,\`,"; else echo \`"$q"; fi