view bin/sled @ 12040:a78307295ae5 draft

<wib_jonas> python3 -cn="bin/allquotes"; a=open(n,"rb").read(); a=a.replace(b\'quotes\',b\'"${HACKENV-/hackenv}/quotes"\'); open(n,"wb").write(a)
author HackEso <hackeso@esolangs.org>
date Fri, 15 Nov 2019 14:33:13 +0000
parents 1e6e3a07b5f4
children 77454e3e15f3
line wrap: on
line source

opts="${2--i}"
[[ "$1" == ?*//* ]] || { echo 'usage: sled file//script'; exit 1; }; key="${1%%//*}"; value="${1#*//}"; [[ -f "$key" ]] || { echo 'Rosebud!'; exit 1; }; sed $opts "$value" "$key" ;