Skip to content

Instantly share code, notes, and snippets.

@rdrgox
Last active November 26, 2022 04:08
Show Gist options
  • Save rdrgox/3d5f186caa4c685871d2a4937945e7c9 to your computer and use it in GitHub Desktop.
Save rdrgox/3d5f186caa4c685871d2a4937945e7c9 to your computer and use it in GitHub Desktop.
Polybar themes custom scripts

Install polybar themes "eg colorblocks"

Install polybar theme

git clone --depth=1 https://github.com/adi1090x/polybar-themes.git
cd polybar-themes
chmod +x setup.sh
./setup.sh
[*] Installing Polybar Themes...

[*] Choose Style -
[1] Simple
[2] Bitmap

[?] Select Option : 1

[*] Installing fonts...
[*] Creating a backup of your polybar configs...
[*] Successfully Installed.

lauch bar

bash ~/.config/polybar/launch.sh

Usage : launch.sh --theme

Available Themes :
--blocks    --colorblocks    --cuts      --docky
--forest    --grayblocks     --hack      --material
--panels    --pwidgets       --shades    --shapes

load startup

vim ~/.config/bspwm/bspwmrc

bash /home/user/.config/polybar/launch.sh --colorblocks

feh --bg-fill /home/user/Desktop/Picture/bg.png &

conf picom

vim ~/.config/picom/picom.conf
#### OPACITY ####

 opacity-rule = []
 
opacity-rule = [ "98:class_g = 'polybar'" ]

add script

cd ~/.config/polybar/colorblocks/scripts
touch ethernet_status.sh
chmod +x ethernet_status.sh
#!/usr/bin/bash
echo "%{F#64b5f6}ICON %{F#fafafa}$(/usr/sbin/ifconfig enp1s0 | grep "inet " | awk '{print $2}')%{u-}"

add module

cd ~/.config/polybar/colorblocks
vim user_modules.ini
;;-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-

[module/ethernet_status]
type = custom/script

exec = ~/.config/polybar/colorblocks/scripts/ethernet_status.sh

interval = 2

format = <label>
format-prefix-font = 2
format-padding = 2

;;format-background = ${color.shadde4}
;;format-foreground = ${color.foreground}
format-background = #42434d

view bar

vim ~/.config/polybar/colorblocks/config.ini
;; Put the bar at the bottom of the screen
bottom = false

;; Modules are added to one of the available blocks
modules-left = launcher sep workspaces sep ethernet_status
modules-center = 
modules-right = updates alsa battery network date sysmenu

;; Enable pseudo-transparency for the bar
pseudo-transparency = true

;;_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-
@rdrgox
Copy link
Author

rdrgox commented Nov 24, 2022

Screenshot from 2022-11-24 19-55-56

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment