Mercurial > repo
view bin/whoops @ 12150:e82ba8366616 draft
<oerjan> slbd whoops//s,[(],HACKENV/$(,
author | HackEso <hackeso@esolangs.org> |
---|---|
date | Mon, 18 Nov 2019 02:34:19 +0000 |
parents | e87bf60ce012 |
children | 627b52c6b2cb |
line wrap: on
line source
OLD="$HACKENV/wisdom/$1"; [ -z "$1" ] && OLD="$HACKENV/$(lastfiles)"; NEW="${OLD}s"; if [ -f "$NEW" ]; then echo "«${NEW}» already exists"; exit 1; fi; mv "$OLD" "$NEW" && echo "«${OLD}» -> «${NEW}»"