-
Notifications
You must be signed in to change notification settings - Fork 1
/
up
executable file
·96 lines (84 loc) · 2.88 KB
/
up
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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
#!/bin/bash
export SCRIPTPATH="$( cd "$(dirname "$0")" ; pwd -P )"
#this is your scriptpath
# echo $SCRIPTPATH
# Down the last running theme
if [ -f "/tmp/leftwm-theme-down" ]; then
/tmp/leftwm-theme-down
rm /tmp/leftwm-theme-down
fi
ln -s $SCRIPTPATH/down /tmp/leftwm-theme-down
########## This script makes the colors of your polybar and terminals#########
sh $SCRIPTPATH/scripts/wal.sh
##############################################################################
#change your keyboard if you need it - azerty or qwerty
#setxkbmap -layout be
keybLayout=$(setxkbmap -v | awk -F "+" '/symbols/ {print $2}')
if [ $keybLayout = "be" ]; then
cp ~/.config/leftwm/config-azerty.toml ~/.config/leftwm/config.toml
else
cp ~/.config/leftwm/config-qwerty.toml ~/.config/leftwm/config.toml
fi
leftwm-command "LoadTheme "$SCRIPTPATH"/config.toml"
# keybindings daemon
######### PUT YOUR PERSONAL KEYBINDS INSIDE YOUR THEME AND ADD THOSE THE THE STANDARD KEYBINDS ######
######### JUST BE AWARE : DOUBLE KEYBINDS WILL RESULT IN A CRASH!!!!!!!! ##########
if [ -f "$SCRIPTPATH/sxhkd/sxhkdrc-personal" ] ; then
# check if there is a keybinds-folder inside your personal theme and use it
sxhkd -c ~/.config/leftwm/sxhkd/sxhkdrc $SCRIPTPATH/sxhkd/sxhkdrc-personal &
else
# standard keybinds
sxhkd -c ~/.config/leftwm/sxhkd/sxhkdrc &
fi
function run {
if ! pgrep -x $(basename $1 | head -c 15) 1>/dev/null;
then
$@&
fi
}
# diversity of apps to start
nm-applet &
pamac-tray &
xfce4-power-manager &
numlockx on &
blueberry-tray &
/usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1 &
/usr/lib/xfce4/notifyd/xfce4-notifyd &
volumeicon &
run xfce4-clipman
#conky -c ~/.config/leftwm/system-overview &
#nitrogen --restore &
#caffeine &
#vivaldi-stable &
#firefox &
#thunar &
#dropbox &
#insync start &
#discord &
#spotify &
#atom &
# Boot picom or compton if it exists
if [ -x "$(command -v picom)" ]; then
picom --config "$SCRIPTPATH"/picom.conf &> /dev/null &
#picom --config $HOME/.config/leftwm/themes/current/picom.conf --experimental-backends &> /dev/null &
#picom &> /dev/null &
#picom --experimental-backends &> /dev/null &
elif [ -x "$(command -v compton)" ]; then
compton --config $HOME/.config/leftwm/themes/current/compton.conf &> /dev/null &
fi
# Set the theme.toml config
leftwm-command "LoadTheme $SCRIPTPATH/theme.toml"
# Set background
if [ -x "$(command -v feh)" ]; then
feh --randomize --bg-fill /usr/share/backgrounds/*
fi
#mainbar
index=0
monitors=($(polybar -m | sed s/:.*//))
leftwm-state -q -n -t "$SCRIPTPATH"/sizes.liquid | sed -r '/^\s*$/d' | while read -r width x y
do
barname="mainbar$index"
monitor=${monitors[index]} width=$(( width - 16 )) polybar -c "$SCRIPTPATH"/polybar/polybartop.config $barname &> /dev/null &
monitor=${monitors[index]} width=$(( width - 16 )) polybar -c "$SCRIPTPATH"/polybar/polybarbottom.config $barname &> /dev/null &
let index=index+1
done