Skip to content

Commit

Permalink
New polybar config and mpv
Browse files Browse the repository at this point in the history
  • Loading branch information
joinemm committed Jan 25, 2024
1 parent 91ab592 commit ee00a4b
Show file tree
Hide file tree
Showing 4 changed files with 67 additions and 28 deletions.
1 change: 1 addition & 0 deletions home-modules/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,5 @@
gtk = import ./gtk.nix;
xmonad = import ./xmonad;
polybar = import ./polybar;
mpv = import ./mpv.nix;
}
12 changes: 12 additions & 0 deletions home-modules/mpv.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{pkgs, ...}: {
programs.mpv = {
enable = true;
scripts = with pkgs.mpvScripts; [
thumbfast
uosc
];
config = {
loop-file = "inf";
};
};
}
81 changes: 53 additions & 28 deletions home-modules/polybar/polybar.ini
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
[colors]
background = #000000
foreground = #ffffff
accent = #6272a4
alert = #a60000
disabled = #b4b4b4

background = #CC101116
background-alt = #373849
foreground = #f8f8f2
primary = #F0C674
secondary = #8ABEB7
alert = #A54242
disabled = #707880

[settings]
screenchange-reload = true
Expand All @@ -21,13 +22,16 @@ enable-struts = true
enable-ipc = true
wm-restack = generic
separator = |
line-size = 2
border-bottom-size = 2
border-bottom-color = #000000

font-0 = "monospace:size=13;3"
font-1 = "monospace:size=13;2"

modules-left = xworkspaces tray
modules-center = time
modules-right = wireless-network wired-network battery backlight pulseaudio cpu memory redshift date
modules-right = wlan eth battery backlight pulseaudio cpu memory redshift date


[module/tray]
Expand All @@ -37,7 +41,9 @@ tray-spacing = 10px

[module/redshift]
type = custom/script
format-prefix = ""
# format-prefix = " "
format-prefix = "TEMP "
format-prefix-foreground = ${colors.primary}
exec = ~/.config/polybar/redshift.sh temperature
click-left = ~/.config/polybar/redshift.sh toggle
interval=1.0
Expand All @@ -51,14 +57,15 @@ type = internal/xworkspaces
enable-scroll = false

label-active = %name%
label-active-background = ${colors.accent}
label-active-background = ${colors.background-alt}
label-active-underline= ${colors.primary}
label-active-padding = 14px

label-occupied = %name%
label-occupied-padding = 10px

label-urgent = %icon%
label-urgent-foreground = ${colors.alert}
label-urgent = %name%
label-urgent-background = ${colors.alert}
label-urgent-padding = 10px

label-empty = ""
Expand Down Expand Up @@ -121,12 +128,13 @@ animation-charging-4 = 
animation-charging-framerate = 750


[module/wireless-network]
[module/wlan]
type = internal/network
interface-type = wireless

format-connected = <ramp-signal> <label>
label-connected = %essid%
# format-connected = <ramp-signal> <label>
# label-connected = %essid%
label-connected = %{F#F0C674}%ifname%%{F-} %essid% %local_ip%
label-disconnected = ""
label-disconnected-foreground = ${colors.alert}

Expand All @@ -138,20 +146,26 @@ ramp-signal-4 = 󱚽
ramp-signal-5 = 󰸋


[module/wired-network]
[module/eth]
type = internal/network
interface-type = wired
label-connected =  %netspeed%
# label-connected =  %netspeed%
label-connected = %{F#F0C674}%ifname%%{F-} %local_ip%


[module/memory]
type = internal/memory
label = 󰆼 %used%

# label = 󰆼 %used%
format-prefix = "RAM "
format-prefix-foreground = ${colors.primary}
label = %percentage_used:2%%

[module/cpu]
type = internal/cpu
label =  %percentage%%
# label =  %percentage%%
format-prefix = "CPU "
format-prefix-foreground = ${colors.primary}
label = %percentage:2%%


[module/pulseaudio]
Expand All @@ -167,22 +181,33 @@ ramp-volume-6 = ━━━╾─
ramp-volume-7 = ━━━━─
ramp-volume-8 = ━━━━╾
ramp-volume-9 = ━━━━━

label-volume = 
label-volume-font = 2
label-muted =  muted

# label-volume = 
# label-volume-font = 2
# label-muted =  muted
# label-muted-foreground = ${colors.disabled}
# format-volume = <label-volume> <ramp-volume>

format-volume-prefix = "VOL "
format-volume-prefix-foreground = ${colors.primary}
format-volume = <label-volume>

label-volume = %percentage%%

label-muted = muted
label-muted-foreground = ${colors.disabled}
format-volume = <label-volume> <ramp-volume>


[module/date]
type = internal/date
date = %a %d/%m
date = %{F#F0C674}%a%{F-} %d/%m
date-alt = %Y-%m-%d
label = %date%
format = 󰃭 <label>
format-font = 2
label-font = 1
# format-prefix = "DATE "
# format-prefix-foreground = ${colors.primary}
# format = 󰃭 <label>
# format-font = 2
# label-font = 1


[module/time]
Expand Down
1 change: 1 addition & 0 deletions hosts/zeus/home.nix
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
gtk
xmonad
polybar
mpv
])
inputs.nixvim.homeManagerModules.nixvim
inputs.nix-index-database.hmModules.nix-index
Expand Down

0 comments on commit ee00a4b

Please sign in to comment.