diff --git a/i3-configuration/i3blocks/wifi_monitor.sh b/i3-configuration/i3blocks/wifi_monitor.sh index 045960d..a85bb88 100755 --- a/i3-configuration/i3blocks/wifi_monitor.sh +++ b/i3-configuration/i3blocks/wifi_monitor.sh @@ -16,9 +16,12 @@ wifi_info=$(iwconfig $wifi_interface 2>/dev/null) ssid=$(echo "$wifi_info" | awk -F '"' '/ESSID/ {print $2}') signal=$(echo "$wifi_info" | awk '/Signal level/ {print $4}' | tr -d 'level=') +# Get the IP address +ip_address=$(ip addr show $wifi_interface | awk '/inet / {print $2}' | cut -d/ -f1) + # Output the result if [ -z "$ssid" ]; then echo " down" else - echo " $ssid ($signal dBm)" + echo " $ssid ($signal dBm) $ip_address" fi \ No newline at end of file diff --git a/i3-configuration/install.sh b/i3-configuration/install.sh index 749249d..089f421 100755 --- a/i3-configuration/install.sh +++ b/i3-configuration/install.sh @@ -35,7 +35,7 @@ if is_ubuntu; then sudo apt-get update sudo apt-get install -y fonts-dejavu-core fonts-noto fonts-font-awesome bc jq iw else - yes | sudo pacman -S --needed ttf-dejavu noto-fonts ttf-font-awesome bc jq iw + yes | sudo pacman -S --needed ttf-dejavu noto-fonts ttf-font-awesome bc jq iw acpi fi # Set font size based on screen resolution @@ -44,4 +44,4 @@ font_size=$(set_font_size) cp -r i3blocks ~/.config/ cp -r i3 ~/.config/ sed -i "s/font pango:System San Francisco Display, FontAwesome [0-9]*/font pango:System San Francisco Display, FontAwesome $font_size/" ~/.config/i3/config -i3-msg reload \ No newline at end of file +i3-msg reload