Skip to content

Instantly share code, notes, and snippets.

@Drunkar
Last active August 4, 2016 10:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save Drunkar/5875111 to your computer and use it in GitHub Desktop.
Save Drunkar/5875111 to your computer and use it in GitHub Desktop.
import csv
tsvFileName = "tsv.txt"
csvFileName = tsvFileName + ".csv"
tsvFile = csv.reader(file(tsvFileName, "r"), delimiter = "\t")
csvFile = csv.writer(file(csvFileName, "w"), lineterminator="\n")
for row in tsvFile:
csvFile.writerow(row)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment