aboutsummaryrefslogtreecommitdiffstats
path: root/scripts/preview
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/preview')
-rwxr-xr-xscripts/preview6
1 files changed, 6 insertions, 0 deletions
diff --git a/scripts/preview b/scripts/preview
index e3a0172..ff77782 100755
--- a/scripts/preview
+++ b/scripts/preview
@@ -16,6 +16,8 @@ elif grep -q "ISO" <<< "$filetype" ; then
filetype="iso"
elif grep -q "PDF" <<< "$filetype"; then
filetype="pdf"
+elif grep -q "SQLite 3" <<< "$filetype"; then
+ filetype="sqlite"
fi
case $filetype in
@@ -41,6 +43,10 @@ case $filetype in
pdftotext -nodiag -nopgbrk "$path" - | head -n "$remaining_lines"
fi
;;
+ "sqlite")
+ file -b "$path"
+ sqlite3 -readonly "$path" ".schema"
+ ;;
*)
file -b "$path"
;;