mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-01-31 03:27:39 +00:00
68ca49bfdd
See #350 thanks @tkchia
24 lines
513 B
Bash
Executable file
24 lines
513 B
Bash
Executable file
#!/bin/sh
|
|
|
|
if [ "$UID" = "0" ]; then
|
|
SUDO=
|
|
else
|
|
SUDO=sudo
|
|
fi
|
|
|
|
{
|
|
echo
|
|
echo "APE Uninstaller intends to run"
|
|
echo
|
|
echo " $SUDO sh -c 'echo -1 >/proc/sys/fs/binfmt_misc/APE'"
|
|
echo " $SUDO rm -f /usr/bin/ape ~/.ape o/tmp/.ape /tmp/.ape"
|
|
echo
|
|
echo "You may then use ape/apeinstall.sh to reinstall it"
|
|
echo
|
|
} >&2
|
|
|
|
set -ex
|
|
if [ -f /proc/sys/fs/binfmt_misc/APE ]; then
|
|
$SUDO sh -c 'echo -1 >/proc/sys/fs/binfmt_misc/APE' || exit
|
|
fi
|
|
$SUDO rm -f /usr/bin/ape ~/.ape o/tmp/.ape /tmp/.ape || exit
|