Skip to content

Instantly share code, notes, and snippets.

@zertrin
Created January 1, 2013 23:41
Show Gist options
  • Save zertrin/4431028 to your computer and use it in GitHub Desktop.
Save zertrin/4431028 to your computer and use it in GitHub Desktop.
One-liner to retrieve the list of all etherpad-lite's pad names in the database
#!/bin/sh
mysql -u etherpad-lite -p etherpad-lite -e 'select store.key from store' \
| grep -Eo '^pad:[^:]+' \
| sed -e 's/pad://' \
| sort \
| uniq -c \
| sort -rn \
| awk '{if ($1!="2") {print $2 }}'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment