Run the following command in the terminal:

dig +short myip.opendns.com @resolver1.opendns.com