You may have installed X11 on your Mac to get some obscure application working (I had done it while looking for a MUD Client) and may be looking for a way to uninstall it. Unfortunately, it’s not as intuitive as it should be, but I managed to find out just how on David Forster’s blog:
Be extremely careful when doing this, as a small typo could cause important files to be deleted and you may have to reinstall OS X! If you are at all unsure of what you are doing, back up all your important data first! I cannot accept responsibility for any loss caused by following these instructions – All I know is they worked for me.
The commands to delete everything are as follows:
sudo rm -rf /Applications/Utilities/X11.app
sudo rm -rf /private/etc/X11
sudo rm -rf /usr/X11R6
sudo rm -rf /usr/bin/open-x11
sudo rm -rf /usr/lib/X11
sudo rm -rf /Library/Receipts/X11User.pkg
These can be combined into one line as follows:
sudo rm -rf /Applications/Utilities/X11.app /private/etc/X11 /usr/X11R6 /usr/bin/open-x11 /usr/lib/X11 /Library/Receipts/X11User.pkg
Thanks Dave, you’re a godsend! Use with care!