Skip to content

Instantly share code, notes, and snippets.

@motebaya
Created June 4, 2025 11:01
Show Gist options
  • Save motebaya/a2ee996fe6c8273cfcf73b2d4ed22b9e to your computer and use it in GitHub Desktop.
Save motebaya/a2ee996fe6c8273cfcf73b2d4ed22b9e to your computer and use it in GitHub Desktop.
parse backup file mobile app: net.fast_notepad_notes_app.fastnotepad
#!/usr/bin/python
# @github.com/motebaya - 6/4/2025
import json, re, datetime
FILE = "fastnote123.txt"
x = open(FILE).read()
t = re.findall(r'(?<=;)(\d{10,19})(?=;;)', x)
open("fastnote.json","w").write(
json.dumps([{
"index": i + 1,
"text": v,
"date": datetime.datetime.fromtimestamp(
int(t[i])).strftime('%Y-%m-%d %H:%M:%S'
)} for i, v in enumerate(v for k, v in json.loads(
"{" + x.split("{", -1)[-1]).items() if\
not k.lower().startswith('scroll')
)],
indent=2))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment