Created
December 11, 2013 10:11
-
-
Save tott/7908001 to your computer and use it in GitHub Desktop.
Get a space separated list of all hosts in an apache config so you can add them to your hosts file
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 | |
grep -E "Server(Name|Alias)" httpd.conf | sort | uniq | cut -d " " -f 6 | tr "\n" " " |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment