Created
February 19, 2013 22:41
-
-
Save caugner/4990863 to your computer and use it in GitHub Desktop.
Get mail domain of a given domain
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
if [ -n "$1" ] | |
then | |
host -t mx $1 | awk '{print $7}' | sed 's/.$//' | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment