GoogleDocSeed
Pulls a Google Spreadsheet into a CSV string.
Installation
Add this line to your application's Gemfile:
gem 'google_doc_seed'
And then execute:
$ bundle
Or install it yourself as:
$ gem install google_doc_seed
Usage
Get a [Google OAuth2 token] with the spreadsheet scope.
Or check out examples/full.rb
for help generating one more easily.
Then do this:
require 'google_doc_seed'
seeder = GoogleDocSeed.new('your-oauth-token')
IO.write('doc.csv', seeder.to_csv_string('0Aut3k...', 'My Worksheet'))
To Do
- Token retrieval
- Token renewal
- Work with the CSV rather than just a string?
Contributing
- Fork it
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create new Pull Request