Created
December 5, 2013 17:35
-
-
Save mavit/7809777 to your computer and use it in GitHub Desktop.
Export Chromium bookmarks as CSV
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# This is a hack. In real life, never parse JSON with a regular expression. Never write SQL unencoded to a string. | |
perl -nE 'push @urls, $1 if m/^\s+"url":\s+"(.+?)"/; END { say q[select url, title, visit_count from urls where url in ("], join(q(","), @urls), q[") order by visit_count desc;] }' ~/.config/chromium/Default/Bookmarks | sqlite3 -csv ~/.config/chromium/Default/History |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment