Skip to content

Instantly share code, notes, and snippets.

@eighteyes
Created April 8, 2021 19:04
Show Gist options
  • Save eighteyes/882bc423e1eb9490210547d9cf98f086 to your computer and use it in GitHub Desktop.
Save eighteyes/882bc423e1eb9490210547d9cf98f086 to your computer and use it in GitHub Desktop.
TiddlyWiki CSV Export to txt/md in Python/Pandas
import pandas as pd
df = pd.read_csv('./tiddlers.csv')
for i, t in df.iterrows():
first = t.title[0]
# no tw junk
if ( first == '.' or first == '/'):
continue
# md
name = './out/'+t.title.replace('/','-') +'.md'
txt = t.text
try:
f = open(name, 'w')
f.write(txt);
f.close();
except:
print(name,txt)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment