Skip to content

Instantly share code, notes, and snippets.

@munen
Created December 14, 2014 13:50
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save munen/3e01337d1de80cbf3d83 to your computer and use it in GitHub Desktop.
Save munen/3e01337d1de80cbf3d83 to your computer and use it in GitHub Desktop.
Permutate a list of keywords and find free domains
lom-atelier
lom
malort
maltherapie
mal-therapie
kunsttherapie
kunst-therapie
begleitetes-malen
malatelier
mal-atelier
kunsttherapie-atelier
maltherapie-atelier
# encoding: utf-8
domains = File.open("clear_domains.txt")
for domain in domains.readlines()
domain = domain.strip
puts "#{domain}.info" if `whois #{domain}.info`.index("NOT FOUND")
puts "#{domain}.ch" if `whois #{domain}.ch` .index("We do not have")
puts "#{domain}.com" if `whois #{domain}.com` .index("No match for")
puts "#{domain}.net" if `whois #{domain}.net` .index("No match for")
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment