Guest User

polybar-config

a guest
Jul 11th, 2019
182
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 13.22 KB | None | 0 0
  1. ;=====================================================
  2. ;
  3. ; To learn more about how to configure Polybar
  4. ; go to https://github.com/jaagr/polybar
  5. ;
  6. ; The README contains alot of information
  7. ;
  8. ;=====================================================
  9.  
  10. ; RGBA HEX COLOURS ARE DONE WITH THE ALPHA FIRST
  11. ; It goes: alpha - red - green - blue
  12. ; complete transparency looks like: #00xxxxxx
  13.  
  14. [colors]
  15. ;background = ${xrdb:color0:#222}
  16. #background = #ea010101
  17. #background = #99181512
  18. ;background = ${xrdb:background}
  19. background = #cc111111
  20. ; background = #8001060d
  21. background-alt = #99000000
  22. ;foreground = ${xrdb:color7:#222}
  23. foreground = ${xrdb:foreground}
  24. foreground-alt = #db555555
  25. primary = #dbffb52a
  26. secondary = #dbe60053
  27. alert = #dbbd2c40
  28.  
  29. [bar/example]
  30. ;monitor = ${env:MONITOR:HDMI-1}
  31. monitor = ${env:MONITOR:}
  32. ;bottom = false
  33. ;width = 98%
  34. height = 27
  35. ;offset-x = 1%
  36. ;offset-y = 2
  37. ;radius = 6.0
  38. fixed-center = false
  39. ;override-redirect = true
  40.  
  41. background = ${colors.background}
  42. foreground = ${colors.foreground}
  43.  
  44. line-size = 3
  45. line-color = #f00
  46.  
  47. border-size = 0
  48. border-color = #00000000
  49. ;border-color = ${colors.background}
  50. ;border-bottom-color = #565D60
  51.  
  52. padding-left = 0
  53. padding-right = 2
  54.  
  55. module-margin-left = 1
  56. module-margin-right = 2
  57.  
  58. ;font-0 = fixed:pixelsize=10;1
  59. ;font-1 = unifont:fontformat=truetype:size=8:antialias=false;0
  60. ;font-0 = DejaVuSans:pixelsize=10;0
  61. ;font-1 = FontAwesome:style=Regular:pixelsize=10;1
  62. ;font-2 = WunconSiji:pixelsize=10;2
  63.  
  64. ; font-0 = fixed:pixelsize=10;1
  65. ; font-1 = DejaVu Sans Mono:pixelsize=10:1
  66. ; font-1 = Inconsolata:pixelsize=13:1
  67. ; font-2 = Siji:pixelsize=12;1
  68. ; font-3 = unifont:size=12:antialias=true;1
  69. ; font-4 = FontAwesome:size=8;1
  70.  
  71.  
  72. font-0 = DejaVu:pixelsize=10;1
  73. font-1 = FontAwesome:size=9;1
  74. font-2 = unifont:size=12:antialias=true;1
  75. font-3 = fixed:pixelsize=10;1
  76. font-4 = Siji:pixelsize=12;1
  77.  
  78.  
  79. modules-left = i3
  80. modules-center = date
  81. modules-right = mpd powermenu
  82.  
  83. tray-position = right
  84. tray-padding = 2
  85. ;tray-transparent = true
  86. ;tray-background = ${colors.background}
  87.  
  88. ;wm-restack = bspwm
  89. wm-restack = i3
  90.  
  91. ;override-redirect = true
  92.  
  93. ;scroll-up = bspwm-desknext
  94. ;scroll-down = bspwm-deskprev
  95.  
  96. scroll-up = i3wm-wsnext
  97. scroll-down = i3wm-wsprev
  98.  
  99.  
  100. [module/alsa]
  101. type = internal/alsa
  102.  
  103. ; Soundcard to be used
  104. ; Usually in the format hw:# where # is the card number
  105. ; You can find the different card numbers in `/proc/asound/cards`
  106. master-soundcard = default
  107. speaker-soundcard = default
  108. headphone-soundcard = default
  109.  
  110. ; Name of the master, speaker and headphone mixers
  111. ; Use the following command to list available mixer controls:
  112. ; $ amixer scontrols | sed -nr "s/.*'([[:alnum:]]+)'.*/\1/p"
  113. ; If master, speaker or headphone-soundcard isn't the default,
  114. ; use `amixer -c # scontrols` instead where # is the number
  115. ; of the master, speaker or headphone soundcard respectively
  116. ;
  117. ; Default: Master
  118. master-mixer = Master
  119.  
  120. ; Optionally define speaker and headphone mixers
  121. ; Default: none
  122. speaker-mixer = Speaker
  123. ; Default: none
  124. headphone-mixer = Headphone
  125.  
  126. ; NOTE: This is required if headphone_mixer is defined
  127. ; Use the following command to list available device controls
  128. ; $ amixer controls | sed -r "/CARD/\!d; s/.*=([0-9]+).*name='([^']+)'.*/printf '%3.0f: %s\n' '\1' '\2'/e" | sort
  129. ; You may also need to use `amixer -c # controls` as above for the mixer names
  130. ; Default: none
  131. headphone-id = 9
  132.  
  133. ; Use volume mapping (similar to amixer -M and alsamixer), where the increase in volume is linear to the ear
  134. ; Default: false
  135. mapped = true
  136.  
  137. ; Interval for volume increase/decrease (in percent points)
  138. ; Default: 5
  139. interval = 5
  140.  
  141.  
  142. [module/cmus]
  143. type = custom/script
  144.  
  145. exec = ~/.config/polybar/cmus.sh
  146. exec-if = pgrep -x cmus
  147. interval = 1
  148.  
  149. click-left = cmus-remote --next
  150. click-right = cmus-remote --prev
  151. click-middle = cmus-remote --pause
  152. scroll-up = cmus-remote --volume +5%
  153. scroll-down = cmus-remote --volume -5%
  154.  
  155. label-font = 3
  156. format = <label>
  157. format-underline = ${colors.foreground-alt}
  158. label = %output%
  159. label-maxlen = 50
  160.  
  161. [module/pulseaudio]
  162. type = internal/pulseaudio
  163.  
  164. ; Sink to be used, if it exists (find using `pacmd list-sinks`, name field)
  165. ; If not, uses default sink
  166. sink = alsa_output.pci-0000_12_00.3.analog-stereo
  167.  
  168. ; Use PA_VOLUME_UI_MAX (~153%) if true, or PA_VOLUME_NORM (100%) if false
  169. ; Default: true
  170. use-ui-max = true
  171.  
  172. ; Interval for volume increase/decrease (in percent points)
  173. ; Default: 5
  174. interval = 5
  175.  
  176. ; Available tags:
  177. ; <label-volume> (default)
  178. ; <ramp-volume>
  179. ; <bar-volume>
  180. format-volume = <ramp-volume> <label-volume>
  181.  
  182. ; Available tags:
  183. ; <label-muted> (default)
  184. ; <ramp-volume>
  185. ; <bar-volume>
  186. ;format-muted = <label-muted>
  187.  
  188. ; Available tokens:
  189. ; %percentage% (default)
  190. ;label-volume = %percentage%%
  191.  
  192. ; Available tokens:
  193. ; %percentage% (default)
  194. label-muted = 🔇 muted
  195. label-muted-foreground = #666
  196.  
  197. ; Only applies if <ramp-volume> is used
  198. ramp-volume-0 = 🔈
  199. ramp-volume-1 = 🔉
  200. ramp-volume-2 = 🔊
  201.  
  202. [module/xwindow]
  203. type = internal/xwindow
  204. label = %title:0:200:...%
  205.  
  206. [module/xkeyboard]
  207. type = internal/xkeyboard
  208. blacklist-0 = num lock
  209.  
  210. format-prefix = " "
  211. format-prefix-foreground = ${colors.foreground-alt}
  212. format-prefix-underline = ${colors.secondary}
  213.  
  214. label-layout = %layout%
  215. label-layout-underline = ${colors.secondary}
  216.  
  217. label-indicator-padding = 2
  218. label-indicator-margin = 1
  219. label-indicator-background = ${colors.secondary}
  220. label-indicator-underline = ${colors.secondary}
  221.  
  222. [module/filesystem]
  223. type = internal/fs
  224. interval = 25
  225.  
  226. mount-0 = /
  227.  
  228. label-mounted = %{F#0a81f5}%mountpoint%%{F-}: %percentage_used%%
  229. label-unmounted = %mountpoint% not mounted
  230. label-unmounted-foreground = ${colors.foreground-alt}
  231.  
  232. [module/bspwm]
  233. type = internal/bspwm
  234.  
  235. label-focused = %index%
  236. label-focused-background = ${colors.background-alt}
  237. label-focused-underline= ${colors.primary}
  238. label-focused-padding = 2
  239.  
  240. label-occupied = %index%
  241. label-occupied-padding = 2
  242.  
  243. label-urgent = %index%!
  244. label-urgent-background = ${colors.alert}
  245. label-urgent-padding = 2
  246.  
  247. label-empty = %index%
  248. label-empty-foreground = ${colors.foreground-alt}
  249. label-empty-padding = 2
  250.  
  251. [module/i3]
  252. type = internal/i3
  253. format = <label-state> <label-mode>
  254. index-sort = true
  255. wrapping-scroll = false
  256. strip-wsnumbers = true
  257.  
  258.  
  259.  
  260. ws-icon-1 = "1;ᚠ"
  261. ws-icon-2 = "2;ᚢ"
  262. ws-icon-3 = "3;ᚦ"
  263. ws-icon-4 = "4;ᚨ"
  264. ws-icon-5 = "5;ᚱ"
  265. ws-icon-6 = "6;ᚲ"
  266. ws-icon-7 = "7;ᚷ"
  267. ws-icon-8 = "8;ᚹ"
  268. ws-icon-9 = "9;ᚻ"
  269. ws-icon-0 = "10;ᚾ"
  270.  
  271.  
  272.  
  273. ; Only show workspaces on the same output as the bar
  274. pin-workspaces = true
  275.  
  276. label-mode-padding = 2
  277. label-mode-foreground = #000
  278. label-mode-background = ${colors.primary}
  279.  
  280. ; focused = Active workspace on focused monitor
  281. label-focused = %icon%
  282. label-focused-foreground = ${xrdb:background}
  283. label-focused-background = ${xrdb:color5}
  284. ;label-focused-underline = ${module/bspwm.label-focused-underline}
  285. label-focused-padding = ${module/bspwm.label-focused-padding}
  286.  
  287. ; unfocused = Inactive workspace on any monitor
  288. label-unfocused = %icon%
  289. label-unfocused-padding = ${module/bspwm.label-occupied-padding}
  290.  
  291. ; visible = Active workspace on unfocused monitor
  292. label-visible = %name%
  293. label-visible-background = ${self.label-focused-background}
  294. ;label-visible-underline = ${self.label-focused-underline}
  295. label-visible-padding = ${self.label-focused-padding}
  296.  
  297. ; urgent = Workspace with urgency hint set
  298. label-urgent = %name%
  299. label-urgent-background = ${module/bspwm.label-urgent-background}
  300. label-urgent-padding = ${module/bspwm.label-urgent-padding}
  301.  
  302. [module/mpd]
  303. type = internal/mpd
  304. ; format-online = <label-song> <bar-progress> <icon-prev> <icon-stop> <toggle> <icon-next> <icon-random>
  305. ; format-online =  [<label-time>] <icon-prev><icon-stop><toggle><icon-next> <label-song>
  306. format-online =  <label-song> [<label-time>] <icon-prev><icon-stop><toggle><icon-next>
  307.  
  308. icon-prev = 
  309. icon-stop = 
  310. icon-play = 
  311. icon-pause = 
  312. icon-next = 
  313. icon-random = 
  314. label-song = %artist% - %title%
  315.  
  316. label-song-maxlen = 35
  317. label-song-ellipsis = true
  318. label-offline = 🎜 mpd is offline
  319.  
  320. format-stopped =  Stopped
  321.  
  322. bar-progress-width = 20
  323. bar-progress-indicator = |
  324. bar-progress-fill = ─
  325. bar-progress-empty = ─
  326.  
  327. ; label-padding-right = 5
  328.  
  329. [module/xbacklight]
  330. type = internal/xbacklight
  331.  
  332. format = <label> <bar>
  333. label = BL
  334.  
  335. bar-width = 10
  336. bar-indicator = |
  337. bar-indicator-foreground = #ff
  338. bar-indicator-font = 2
  339. bar-fill = ─
  340. bar-fill-font = 2
  341. bar-fill-foreground = #9f78e1
  342. bar-empty = ─
  343. bar-empty-font = 2
  344. bar-empty-foreground = ${colors.foreground-alt}
  345.  
  346. [module/backlight-acpi]
  347. inherit = module/xbacklight
  348. type = internal/backlight
  349. card = intel_backlight
  350.  
  351. [module/cpu]
  352. type = internal/cpu
  353. interval = 2
  354. format-prefix = " "
  355. format-prefix-foreground = ${colors.foreground-alt}
  356. format-underline = #f90000
  357. label = %percentage%%
  358.  
  359. [module/memory]
  360. type = internal/memory
  361. interval = 2
  362. format-prefix = " "
  363. format-prefix-foreground = ${colors.foreground-alt}
  364. format-underline = #4bffdc
  365. label = %percentage_used%%
  366.  
  367. [module/wlan]
  368. type = internal/network
  369. interface = wlp2s0
  370. interval = 3.0
  371.  
  372. format-connected = <ramp-signal> <label-connected>
  373. format-connected-underline = #9f78e1
  374. label-connected = %essid%
  375.  
  376. format-disconnected =
  377. ;format-disconnected = <label-disconnected>
  378. ;format-disconnected-underline = ${self.format-connected-underline}
  379. ;label-disconnected = %ifname% disconnected
  380. ;label-disconnected-foreground = ${colors.foreground-alt}
  381.  
  382. ramp-signal-0 = 
  383. ramp-signal-1 = 
  384. ramp-signal-2 = 
  385. ramp-signal-3 = 
  386. ramp-signal-4 = 
  387. ramp-signal-foreground = ${colors.foreground-alt}
  388.  
  389. [module/eth]
  390. type = internal/network
  391. interface = enp0s31f6
  392. interval = 3.0
  393.  
  394. format-connected-underline = #55aa55
  395. format-connected-prefix = " "
  396. format-connected-prefix-foreground = ${colors.foreground-alt}
  397. label-connected = " : %downspeed%  : %upspeed%"
  398.  
  399. format-disconnected =
  400. ;format-disconnected = <label-disconnected>
  401. ;format-disconnected-underline = ${self.format-connected-underline}
  402. ;label-disconnected = %ifname% disconnected
  403. ;label-disconnected-foreground = ${colors.foreground-alt}
  404.  
  405. [module/date]
  406. type = internal/date
  407. interval = 5
  408.  
  409. date =
  410. date-alt = " %A, %B %d, %Y"
  411.  
  412. time = %I:%M %p
  413. time-alt = %H:%M
  414.  
  415. format-prefix = 
  416. format-prefix-foreground = ${colors.foreground}
  417. ;format-underline = #0a6cf5
  418.  
  419. label = %date% %time%
  420. label-padding-right = 5
  421.  
  422. [module/volume]
  423. type = internal/volume
  424.  
  425. format-volume = <label-volume> <bar-volume>
  426. label-volume = VOL
  427. label-volume-foreground = ${root.foreground}
  428.  
  429. format-muted-prefix = " "
  430. format-muted-foreground = ${colors.foreground-alt}
  431. label-muted = sound muted
  432.  
  433. bar-volume-width = 10
  434. bar-volume-foreground-0 = #55aa55
  435. bar-volume-foreground-1 = #55aa55
  436. bar-volume-foreground-2 = #55aa55
  437. bar-volume-foreground-3 = #55aa55
  438. bar-volume-foreground-4 = #55aa55
  439. bar-volume-foreground-5 = #f5a70a
  440. bar-volume-foreground-6 = #ff5555
  441. bar-volume-gradient = false
  442. bar-volume-indicator = |
  443. bar-volume-indicator-font = 2
  444. bar-volume-fill = ─
  445. bar-volume-fill-font = 2
  446. bar-volume-empty = ─
  447. bar-volume-empty-font = 2
  448. bar-volume-empty-foreground = ${colors.foreground-alt}
  449.  
  450. [module/battery]
  451. type = internal/battery
  452. battery = BAT0
  453. ; adapter = AC0
  454. adapter = AC
  455. full-at = 100
  456.  
  457. label-discharging = %percentage%% %consumption%W
  458. label-charging = %percentage%% %consumption%W
  459.  
  460. format-charging = <animation-charging> <label-charging>
  461. format-charging-underline = #ffb52a
  462.  
  463. format-discharging = <ramp-capacity> <label-discharging>
  464. format-discharging-underline = ${self.format-charging-underline}
  465.  
  466. format-full-prefix = " "
  467. format-full-prefix-foreground = ${colors.foreground-alt}
  468. format-full-underline = ${self.format-charging-underline}
  469.  
  470. ramp-capacity-0 = 
  471. ramp-capacity-1 = 
  472. ramp-capacity-2 = 
  473. ramp-capacity-foreground = ${colors.foreground-alt}
  474.  
  475. animation-charging-0 = 
  476. animation-charging-1 = 
  477. animation-charging-2 = 
  478. animation-charging-foreground = ${colors.foreground-alt}
  479. animation-charging-framerate = 750
  480.  
  481. [module/temperature]
  482. type = internal/temperature
  483. thermal-zone = 0
  484. warn-temperature = 60
  485.  
  486. format = <ramp> <label>
  487. format-underline = #f50a4d
  488. format-warn = <ramp> <label-warn>
  489. format-warn-underline = ${self.format-underline}
  490.  
  491. label = %temperature%
  492. label-warn = %temperature%
  493. label-warn-foreground = ${colors.secondary}
  494.  
  495. ramp-0 = 
  496. ramp-1 = 
  497. ramp-2 = 
  498. ramp-foreground = ${colors.foreground-alt}
  499.  
  500. [module/powermenu]
  501. type = custom/menu
  502.  
  503. format-spacing = 1
  504.  
  505. label-open = 
  506. label-open-foreground = ${colors.secondary}
  507. label-close =  cancel
  508. label-close-foreground = ${colors.secondary}
  509. label-separator = |
  510. label-separator-foreground = ${colors.foreground-alt}
  511.  
  512. menu-0-0 = reboot
  513. menu-0-0-exec = menu-open-1
  514. menu-0-1 = power off
  515. menu-0-1-exec = menu-open-2
  516.  
  517. menu-1-0 = cancel
  518. menu-1-0-exec = menu-open-0
  519. menu-1-1 = reboot
  520. menu-1-1-exec = reboot
  521.  
  522. menu-2-0 = power off
  523. menu-2-0-exec = shutdown -P now
  524. menu-2-1 = cancel
  525. menu-2-1-exec = menu-open-0
  526.  
  527. [settings]
  528. screenchange-reload = true
  529. ;compositing-background = xor
  530. ;compositing-background = screen
  531. ;compositing-foreground = source
  532. ;compositing-border = over
  533.  
  534. [global/wm]
  535. margin-top = 5
  536. margin-bottom = 5
  537.  
  538. ; vim:ft=dosini
Advertisement
Add Comment
Please, Sign In to add comment