Skip to content

Instantly share code, notes, and snippets.

@thnikk
thnikk / volume.sh
Created June 2, 2020 23:20
Polybar volume script
#!/bin/bash
# Simple demo volume control script module for Polybar
# Get current volume
VOL="$(pamixer --get-volume)"
MUTE="$(pamixer --get-mute)"
# Desired width of module
WIDTH="10"
# Multiply volume by this value
SVM="$(( 100/$WIDTH ))"