blob: f080b31cda3b158be2de9e967690e4e370016e35 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
#!/bin/sh
# Deal with the fact that xdg-open likes to fork bomb under i3. Idea
# to bypass system xdg-open in this way from here:
# https://drewdevault.com/2019/12/30/dotfiles.html
case "${1%%:*}" in
http|https)
exec firefox --new-window "$1"
;;
*.pdf|*.PDF)
exec evince "$1"
;;
*.xlsx)
exec soffice "$1"
;;
mailto)
exec notmuch emacs-mua --client --create-frame "$1"
;;
*)
exec /usr/bin/xdg-open "$@"
;;
esac
|