Method: GithubCLI::Formatters::CSV#render_line
- Defined in:
- lib/github_cli/formatters/csv.rb
#render_line(index, item) ⇒ Object
40 41 42 43 44 45 46 47 48 49 50 |
# File 'lib/github_cli/formatters/csv.rb', line 40 def render_line(index, item) output = item if item.respond_to?(:to_hash) output = GithubCLI::Util.flatten_hash(item.to_hash) output = output.values.join(',') elsif item.respond_to?(:to_ary) output = item.join(',') end $stdout.printf "%d,%s", index, output end |