Skip to content

Instantly share code, notes, and snippets.

View bbirkinbine's full-sized avatar

Brian Birkinbine bbirkinbine

View GitHub Profile
@bbirkinbine
bbirkinbine / xlsx2tsv.py
Created June 16, 2017 14:34 — forked from brendano/xlsx2tsv.py
xlsx2tsv: python command-line script to convert xlsx (Excel "OOXML") into tab-separated values
#!/usr/bin/env python
"""
xlsx2tsv filename.xlsx [sheet number or name]
Parse a .xlsx (Excel OOXML, which is not OpenOffice) into tab-separated values.
If it has multiple sheets, need to give a sheet number or name.
Outputs honest-to-goodness tsv, no quoting or embedded \\n\\r\\t.
One reason I wrote this is because Mac Excel 2008 export to csv or tsv messes
up encodings, converting everything to something that's not utf8 (macroman

Keybase proof

I hereby claim:

  • I am bbirkinbine on github.
  • I am brianbirkinbine (https://keybase.io/brianbirkinbine) on keybase.
  • I have a public key whose fingerprint is 43ED E556 9415 AB83 92C5 E747 009E A445 2532 6803

To claim this, I am signing this object: