osx-ls-download-history 385 B

123456789101112131415161718
  1. #
  2. # Displays the macOS download history.
  3. #
  4. # Authors:
  5. # Sorin Ionescu <sorin.ionescu@gmail.com>
  6. #
  7. # function osx-ls-download-history {
  8. local db
  9. for db in ~/Library/Preferences/com.apple.LaunchServices.QuarantineEventsV*; do
  10. if grep -q 'LSQuarantineEvent' < <(sqlite3 "$db" .tables); then
  11. sqlite3 "$db" 'SELECT LSQuarantineDataURLString FROM LSQuarantineEvent'
  12. fi
  13. done
  14. # }