Modernize i3 setup: alacritty, dunst, rofi, i3blocks, blurlock, picom updates
This commit is contained in:
@@ -14,7 +14,7 @@
|
||||
# <http://developer.gnome.org/pango/stable/PangoMarkupFormat.html>.
|
||||
# If markup is not allowed, those tags will be stripped out of the
|
||||
# message.
|
||||
markup = yes
|
||||
markup = full
|
||||
|
||||
# The format of the message. Possible variables are:
|
||||
# %a appname
|
||||
@@ -116,11 +116,10 @@
|
||||
# Align icons left/right/off
|
||||
icon_position = left
|
||||
|
||||
# Paths to default icons.
|
||||
icon_path = /usr/share/icons/Adwaita/16x16/status/:/usr/share/icons/Adwaita/16x16/devices/
|
||||
|
||||
# Limit icons size.
|
||||
max_icon_size = 64
|
||||
# Icon lookup
|
||||
enable_recursive_icon_lookup = true
|
||||
icon_theme = Adwaita
|
||||
icon_size = 64
|
||||
|
||||
# Note: [shortcuts] section was removed in dunst 1.7+
|
||||
# Use dunstctl for keyboard control instead:
|
||||
@@ -144,22 +143,4 @@
|
||||
foreground = "#F9FAF9"
|
||||
timeout = 8
|
||||
|
||||
[irc]
|
||||
appname = weechat
|
||||
timeout = 0
|
||||
background = "#0033bb"
|
||||
foreground = "#dddddd"
|
||||
|
||||
[weechat hl]
|
||||
appname = weechat
|
||||
category = weechat.HL
|
||||
background = "#FF5C47"
|
||||
foreground = "#FFFFFF"
|
||||
|
||||
[weechat pn]
|
||||
appname = weechat
|
||||
category = weechat.PM
|
||||
background = "#D53B84"
|
||||
foreground = "#FFFFFF"
|
||||
|
||||
# vim: ft=cfg
|
||||
|
||||
@@ -24,15 +24,21 @@ label=
|
||||
instance=0
|
||||
interval=10
|
||||
|
||||
[iface]
|
||||
[myi3volume]
|
||||
command=$HOME/opt/scripts/myi3blocks/myi3volume
|
||||
label=
|
||||
interval=5
|
||||
signal=1
|
||||
|
||||
[myi3iface]
|
||||
command=$HOME/opt/scripts/myi3blocks/myi3iface
|
||||
label=
|
||||
color=#33CCFF
|
||||
interval=30
|
||||
|
||||
[myi3weather-cam]
|
||||
[myi3weather]
|
||||
command=$HOME/opt/scripts/myi3blocks/myi3weather
|
||||
label=ℂ
|
||||
instance=2653941
|
||||
instance=2867543
|
||||
interval=600
|
||||
|
||||
[time]
|
||||
|
||||
@@ -37,12 +37,8 @@ invert-color-include = [ ];
|
||||
glx-copy-from-front = false;
|
||||
|
||||
opacity-rule = [
|
||||
"80:class_g = 'Gnome-terminal'",
|
||||
"80:class_g = 'Rofi'",
|
||||
"80:class_g = 'Mousepad'",
|
||||
"80:class_g = 'Evolution'",
|
||||
"80:class_g = 'Pcmanfm'",
|
||||
"80:class_g = 'Virt-manager'",
|
||||
"80:class_g = 'i3bar'"
|
||||
];
|
||||
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
configuration {
|
||||
theme: "android_notification";
|
||||
terminal: "gnome-terminal";
|
||||
ssh-client: "ssh";
|
||||
ssh-command: "{terminal} -- {ssh-client} {host}";
|
||||
theme: "gruvbox-dark-hard";
|
||||
terminal: "alacritty";
|
||||
font: "Noto Sans 12";
|
||||
show-icons: true;
|
||||
lines: 10;
|
||||
drun-display-format: "{name}";
|
||||
}
|
||||
|
||||
@@ -28,19 +28,24 @@ bindsym $mod+d layout toggle split
|
||||
# Enable touchpad natural scrolling
|
||||
exec_always --no-startup-id xinput set-prop "bcm5974" "libinput Natural Scrolling Enabled" 1
|
||||
|
||||
bindsym $mod+Shift+Return exec gnome-terminal
|
||||
bindsym $mod+Shift+Return exec alacritty
|
||||
bindsym $mod+Shift+w exec vivaldi-stable
|
||||
bindsym $mod+Shift+f exec gnome-terminal -- ranger
|
||||
bindsym $mod+Shift+f exec alacritty -e ranger
|
||||
bindsym $mod+Shift+e exec mousepad
|
||||
bindsym $mod+Shift+p exec keepassxc
|
||||
|
||||
bindsym $mod+space --release exec "rofi -combi-modi drun,window,ssh -show combi -modi combi"
|
||||
bindsym $mod+space --release exec "rofi -combi-modi drun,window -show combi -modi combi"
|
||||
bindsym $mod+q kill
|
||||
|
||||
bindsym $mod+Ctrl+p exec pavucontrol
|
||||
bindsym $mod+Ctrl+b exec gnome-terminal -- bmenu
|
||||
bindsym $mod+Ctrl+b exec alacritty -e bmenu
|
||||
bindsym $mod+Print --release exec --no-startup-id flameshot gui
|
||||
|
||||
# Dunst notification control
|
||||
bindsym $mod+n exec dunstctl close
|
||||
bindsym $mod+Shift+n exec dunstctl close-all
|
||||
bindsym $mod+grave exec dunstctl history-pop
|
||||
|
||||
# Autostart applications
|
||||
exec --no-startup-id /usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1
|
||||
exec --no-startup-id nitrogen --restore; sleep 1; picom -b
|
||||
|
||||
@@ -1,8 +1,3 @@
|
||||
#!/bin/bash
|
||||
|
||||
echo $(date '+%a, %b %d %I:%M %p')
|
||||
|
||||
case $BLOCK_BUTTON in
|
||||
1) gsimplecal ;;
|
||||
*) ;;
|
||||
esac
|
||||
|
||||
16
files/configs/i3/myi3blocks/myi3iface
Normal file
16
files/configs/i3/myi3blocks/myi3iface
Normal file
@@ -0,0 +1,16 @@
|
||||
#!/bin/bash
|
||||
|
||||
IFACE=$(ip route | grep default | awk '{print $5}' | head -1)
|
||||
|
||||
if [[ -z "${IFACE}" ]]; then
|
||||
echo "No connection"
|
||||
echo "No connection"
|
||||
echo "#FF6666"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
IP=$(ip addr show "${IFACE}" | grep 'inet ' | awk '{print $2}' | cut -d/ -f1)
|
||||
|
||||
echo "${IFACE}: ${IP}"
|
||||
echo "${IP}"
|
||||
echo "#33CCFF"
|
||||
@@ -17,6 +17,6 @@ else
|
||||
fi
|
||||
|
||||
case $BLOCK_BUTTON in
|
||||
1) gnome-terminal -- htop ;;
|
||||
1) alacritty -e htop ;;
|
||||
*) ;;
|
||||
esac
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
#!/bin/bash
|
||||
|
||||
MEM_STAT=$(free -m | grep Mem | awk '{print $2,$3}')
|
||||
MEM_TOTAL_MB=${MEM_STAT%% *}
|
||||
MEM_USED_MB=${MEM_STAT##* }
|
||||
MEM_USED_GB=$(echo "scale=2;$MEM_USED_MB/1024" | bc -l)
|
||||
echo "$MEM_USED_GB GB"
|
||||
MEM_TOTAL_GB=$(echo "scale=1;$MEM_TOTAL_MB/1024" | bc -l)
|
||||
MEM_USED_GB=$(echo "scale=1;$MEM_USED_MB/1024" | bc -l)
|
||||
echo "${MEM_USED_GB}/${MEM_TOTAL_GB} GB"
|
||||
|
||||
25
files/configs/i3/myi3blocks/myi3volume
Normal file
25
files/configs/i3/myi3blocks/myi3volume
Normal file
@@ -0,0 +1,25 @@
|
||||
#!/bin/bash
|
||||
|
||||
VOLUME=$(pactl get-sink-volume @DEFAULT_SINK@ | grep -o '[0-9]*%' | head -1)
|
||||
MUTE=$(pactl get-sink-mute @DEFAULT_SINK@ | awk '{print $2}')
|
||||
|
||||
if [[ "${MUTE}" == "yes" ]]; then
|
||||
echo " MUTE"
|
||||
echo " MUTE"
|
||||
echo "#FF6666"
|
||||
else
|
||||
VOL_NUM=${VOLUME%\%}
|
||||
echo " ${VOLUME}"
|
||||
echo " ${VOLUME}"
|
||||
if (( VOL_NUM > 80 )); then
|
||||
echo "#FFBF00"
|
||||
else
|
||||
echo "#33CC33"
|
||||
fi
|
||||
fi
|
||||
|
||||
case $BLOCK_BUTTON in
|
||||
3) pactl set-sink-mute @DEFAULT_SINK@ toggle ;;
|
||||
4) pactl set-sink-volume @DEFAULT_SINK@ +5% ;;
|
||||
5) pactl set-sink-volume @DEFAULT_SINK@ -5% ;;
|
||||
esac
|
||||
@@ -9,18 +9,18 @@ CITY_ID="${BLOCK_INSTANCE}"
|
||||
URGENT_LOWER=0
|
||||
URGENT_HIGHER=30
|
||||
|
||||
ICON_SUNNY=""
|
||||
ICON_CLOUDY=""
|
||||
ICON_RAINY=""
|
||||
ICON_STORM=""
|
||||
ICON_SNOW=""
|
||||
ICON_FOG=""
|
||||
ICON_SUNNY=""
|
||||
ICON_CLOUDY=""
|
||||
ICON_RAINY=""
|
||||
ICON_STORM=""
|
||||
ICON_SNOW=""
|
||||
ICON_FOG=""
|
||||
|
||||
SYMBOL_CELSIUS="℃"
|
||||
|
||||
WEATHER_URL="http://api.openweathermap.org/data/2.5/weather?id=${CITY_ID}&appid=${API_KEY}&units=metric"
|
||||
|
||||
WEATHER_INFO=$(wget -qO- "${WEATHER_URL}")
|
||||
WEATHER_INFO=$(curl -s "${WEATHER_URL}")
|
||||
WEATHER_MAIN=$(echo "${WEATHER_INFO}" | grep -o -e '\"main\":\"[a-Z]*\"' | awk -F ':' '{print $2}' | tr -d '"')
|
||||
WEATHER_TEMP=$(echo "${WEATHER_INFO}" | grep -o -e '\"temp\":\-\?[0-9]*' | awk -F ':' '{print $2}' | tr -d '"')
|
||||
|
||||
@@ -34,7 +34,7 @@ elif [[ "${WEATHER_MAIN}" = *Rain* ]] || [[ "${WEATHER_MAIN}" = *Drizzle* ]]; th
|
||||
echo ""
|
||||
elif [[ "${WEATHER_MAIN}" = *Thunderstorm* ]]; then
|
||||
echo "${ICON_STORM} ${WEATHER_TEMP}${SYMBOL_CELSIUS}"
|
||||
echo "${ICON_STORM} ${WEATHER_TEMP}${SYMBOL_CELSIUS}"
|
||||
echo "${ICON_STORM} ${WEATHER_TEMP}${SYMBOL_CELSIUS}"
|
||||
echo ""
|
||||
elif [[ "${WEATHER_MAIN}" = *Cloud* ]]; then
|
||||
echo "${ICON_CLOUDY} ${WEATHER_TEMP}${SYMBOL_CELSIUS}"
|
||||
|
||||
Reference in New Issue
Block a user