aboutsummaryrefslogtreecommitdiff
path: root/misc
diff options
context:
space:
mode:
Diffstat (limited to 'misc')
-rwxr-xr-xmisc/bin/xdgdef5
1 files changed, 5 insertions, 0 deletions
diff --git a/misc/bin/xdgdef b/misc/bin/xdgdef
new file mode 100755
index 0000000..3d8791f
--- /dev/null
+++ b/misc/bin/xdgdef
@@ -0,0 +1,5 @@
+#!/bin/bash
+# Print xdg file type and the default opener for a file
+
+filetype=$(xdg-mime query filetype "$1")
+echo $filetype=`xdg-mime query default "$filetype"`