blob: a812c6276721446cca7b4eadb0b432a404b4bfdf (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
#!/bin/bash -a
exec_bg () {
exec $1 "$2" &
exit 0
}
File="$1"
[[ $File =~ (file|http|https|ftp|sftp)"://"* ]] && exec w3m "$File"
Ext=${File##*.}
[[ $Ext == htm* ]] && exec w3m "$File"
[[ $Ext =~ (sc|tab|csv) ]] && exec sc-im "$File"
[[ $Ext == pdf ]] && exec_bg evince "$File"
exec_bg gvim "$File"
|