Find file
Fetching contributors…
Cannot retrieve contributors at this time
49 lines (33 sloc) 1.13 KB

Calculate Most Common Domains From Email List

Build Status Code Climate

It's worth checking what email clients your subscribers are using so that you can make sure your emails look good when they view them.

This gem looks at your subscribers CSV and lists the domains in order of popularity*.

  • This obviously doesn't take desktop mail clients in to account, but it should give you an idea of what people are using.

How to Use


gem install ampersat


$ ampersat domains --file=~/test.csv 2 1 1

In irb

$ irb
> require 'ampersat'
    => true
=> [['', 2], ['', 1], ['', 1]]

In Your App

domains ='/Users/gareth/test.csv')

domains.each do |domain, count|
  puts "#{domain}: #{count}"

# 2
# 1
# 1