-
-
Notifications
You must be signed in to change notification settings - Fork 9
/
www
executable file
·33 lines (28 loc) · 944 Bytes
/
www
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#!/bin/bash
# abstract: browser launcher
if [[ $(hostname) = "x1" ]]; then
# current screen number of the active monitor
active_monitor=$(sdorfehs -c sdump|sed -E 's/,/\n/g'|grep -P ' 1$'|awk '{print $2}')
if [[ $active_monitor = 1 ]]; then
# middle monitor, use vscreen profiles
fx_vscreen_profiles "$@"
else
fx_screen_profiles "$@"
fi
elif [[ $(hostname) = "fantomen" ]]; then
# current screen number of the active monitor
# 2 = middle
CURRENT_SCREEN=$(sdorfehs -c sdump|sed -E 's/,/\n/g'|grep -P ' 1$'|awk '{print $2}')
# if we are on the middle screen we want to use the vscreen profiles on the
# other monitors we can use the screen_profiles since vscreens are hardly
# used there
if [[ $CURRENT_SCREEN == 2 ]]; then
echo $CURRENT_SCREEN
fx_vscreen_profiles "$@"
else
fx_screen_profiles "$@"
fi
else
firefox
fi
# remember to execute add_userchrome_to_all_profiles.zsh once done