Mercurial > repo
view bin/random-card @ 12531:e620802431cc draft default tip
<b_jonas> `` [[ 12529 == $(hg log --removed -l 1 -T "{rev}" /hackenv/wisdom/password) ]] && learn password \'The password of the month is consider us expert everything street.\'
author | HackEso <hackeso@esolangs.org> |
---|---|
date | Wed, 01 Oct 2025 09:42:50 +0100 |
parents | 9a693e54efb1 |
children |
line wrap: on
line source
#!/bin/sh exec perl -e'open$I,"<",($ENV{HACKENV}//"/hackenv")."/share/mtg/allsets.txt"or die$!;$/=""; @c=grep{/(?mi:$ARGV[0])/}<$I>; print($c[rand(@c)] || "No card found.");' -- "$1"