Skip to content

Instantly share code, notes, and snippets.

@joecks
Last active May 12, 2020 12:24
Show Gist options
  • Save joecks/af4f1839c82b8e1dd15785e3bf4f457c to your computer and use it in GitHub Desktop.
Save joecks/af4f1839c82b8e1dd15785e3bf4f457c to your computer and use it in GitHub Desktop.
Export ClipboardActions database to CSV

Preparation

  1. Install ADB (Android Debug Bridge, check tutorias online)
  2. Then install a linux subsystem (https://www.howtogeek.com/249966/how-to-install-and-use-the-linux-bash-shell-on-windows-10/) not neccessary on Linux or Mac OS
  3. Install Openssl and Python (check the internet for tutorials)

Steps:

  1. Connect your device with a cable to your computer and enable Developer option (please google how to do that)
  2. Allow access to your device once you connect the cable
  3. in the Terminal call: adb backup -noapk de.halfreal.clipboardactions (this will copy a backup from ClipboardActions on your device called backup.ab)
  4. on linux subsystem : dd if=backup.ab bs=24 skip=1|openssl zlib -d | tar  -xvf - or on Mac OS: dd if=backup.ab bs=1 skip=24 | python -c "import zlib,sys;sys.stdout.write(zlib.decompress(sys.stdin.read()))" | tar -xvf -
  5. sqlite3 -header -csv apps/de.halfreal.clipboardactions/db/ClipboardActions "select * from clips;"  (this creates a csv file that should be compatible with the ClipboardActions import function)
  6. Reinstall the latest version of ClipboardActions and use the import function to import that file.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment