Class: Renuo::Cli::Commands::FetchEmails
- Inherits:
-
Object
- Object
- Renuo::Cli::Commands::FetchEmails
- Defined in:
- lib/renuo/cli/commands/fetch_emails.rb
Constant Summary collapse
- EMAIL_LIST_URL =
"https://docs.google.com/spreadsheets/d/e/2PACX-1vSqPiedBeGk0N75cxZApEohj5LrIWlHWUxTjfhkmK9aOsUltcqCn24sD1haIasUjVfd8UT8VdUKUc4h/pub?gid=703649940&single=true&output=csv"
Instance Method Summary collapse
Instance Method Details
#fetch_emails ⇒ Object
18 19 20 21 22 |
# File 'lib/renuo/cli/commands/fetch_emails.rb', line 18 def fetch_emails response = get_emails(EMAIL_LIST_URL) response = handle_redirection(response) if response.is_a?(Net::HTTPRedirection) format_response(response) end |
#run ⇒ Object
13 14 15 16 |
# File 'lib/renuo/cli/commands/fetch_emails.rb', line 13 def run say "# Here is a complete list of Renuo email addresses".colorize :green say fetch_emails.join("\n") end |