HI,

I don’t use bar and status, only WM and some apps, so I use PS1 for see clock and battery status, clock change each time I enter a new prompt line but status battery change only with new shell

example :

PS1="$(cat /sys/class/power_supply/BAT0/capacity)% \A"

thanks

  • rmc0OP
    link
    fedilink
    arrow-up
    1
    ·
    4 years ago

    I found this but not perfect (not on same line…)

    PROMPT_COMMAND If set, the value is executed as a command prior to issuing each primary prompt.

    PROMPT_COMMAND+="hey.sh;"

    source