Skip to content

Instantly share code, notes, and snippets.

@ninjs
Created April 13, 2015 22:11
Show Gist options
  • Save ninjs/d28fae0c0f1851480f26 to your computer and use it in GitHub Desktop.
Save ninjs/d28fae0c0f1851480f26 to your computer and use it in GitHub Desktop.
book = Spreadsheet.open( ARGV.join(' '))
sheet1 = book.worksheet 0
sheet1.each 1 do |row|
break if row[0] == nil
x = row[0].to_s
y = row[5].to_s
z = row[6].to_s
zz = row[7].to_s
end
# I need to put those variables somewhere so that I can put them in a new worksheet output file
newbook = Spreadsheet::Workbook.new
newsheet1 = newbook.create_worksheet
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment