mac terminal how to remove directory code example Example: delete directory mac terminal rm -r dirname