1
0
Fork 0

defaut-open with better mime types

This commit is contained in:
Jeremy Kaplan 2017-12-18 08:38:38 -08:00
commit 6b65b871bf

View file

@ -2,7 +2,7 @@
mimetype=$1 mimetype=$1
original=$2 original=$2
ext=$(grep "$mimetype" /etc/mime.types | awk '{print $2}') ext=$(grep "$mimetype" /etc/mime.types | head -n 1 | awk '{print $2}')
destination=$(mktemp --suffix=".$ext") destination=$(mktemp --suffix=".$ext")
cp $original $destination cp $original $destination